2009-05-20 00:27:50 +04:00
|
|
|
# $NetBSD: Makefile.compat,v 1.5 2009/05/19 20:27:50 christos Exp $
|
2008-10-26 10:38:27 +03:00
|
|
|
|
|
|
|
COPTS+= -m32
|
|
|
|
CPUFLAGS+= -m32
|
|
|
|
LDADD+= -m32
|
2008-10-29 01:58:23 +03:00
|
|
|
MKDEPFLAGS+= -m32
|
2008-10-26 10:38:27 +03:00
|
|
|
|
|
|
|
# XXX ugly
|
2009-03-12 20:16:58 +03:00
|
|
|
.if ${MACHINE_ARCH} == "sparc64"
|
2008-10-26 10:38:27 +03:00
|
|
|
LD+= -m elf32_sparc
|
|
|
|
LD32DIR= sparc
|
2009-03-12 20:16:58 +03:00
|
|
|
.elif ${MACHINE_ARCH} == "x86_64"
|
2008-10-26 10:38:27 +03:00
|
|
|
LD+= -m elf_i386
|
|
|
|
LD32DIR= i386
|
|
|
|
.endif
|
|
|
|
|
|
|
|
LIBDIR= /usr/lib/${LD32DIR}
|
|
|
|
SHLIBDIR= /usr/lib/${LD32DIR}
|
|
|
|
SHLIBINSTALLDIR= /usr/lib/${LD32DIR}
|
|
|
|
|
|
|
|
COMMON_MACHINE_ARCH= ${LD32DIR}
|
|
|
|
LIBC_MACHINE_ARCH= ${LD32DIR}
|
|
|
|
BFD_MACHINE_ARCH= ${LD32DIR}
|
|
|
|
CRYPTO_MACHINE_CPU= ${LD32DIR}
|
|
|
|
KVM_MACHINE_ARCH= ${LD32DIR}
|
|
|
|
PTHREAD_MACHINE_ARCH= ${LD32DIR}
|
|
|
|
LDELFSO_MACHINE_CPU= ${LD32DIR}
|
|
|
|
|
|
|
|
_GCC_CRTBEGIN?= ${DESTDIR}/usr/lib/${LD32DIR}/crtbegin.o
|
|
|
|
_GCC_CRTBEGINS?= ${DESTDIR}/usr/lib/${LD32DIR}/crtbeginS.o
|
|
|
|
_GCC_CRTEND?= ${DESTDIR}/usr/lib/${LD32DIR}/crtend.o
|
|
|
|
_GCC_CRTENDS?= ${DESTDIR}/usr/lib/${LD32DIR}/crtendS.o
|
|
|
|
_GCC_CRTDIR?= ${DESTDIR}/usr/lib/${LD32DIR}
|
|
|
|
_GCC_LIBGCCDIR?= ${DESTDIR}/usr/lib/${LD32DIR}
|
|
|
|
|
|
|
|
NOSHARE= # defined
|
|
|
|
NONLS= # defined
|
|
|
|
NOCHECKVER= # defined
|
|
|
|
|
|
|
|
LIBC_DIR= ${NETBSDSRCDIR}/compat/lib/libc
|
|
|
|
|
|
|
|
# ld.elf_so
|
2009-05-20 00:27:50 +04:00
|
|
|
SHLINKINSTALLDIR= /libexec
|
2008-10-26 10:38:27 +03:00
|
|
|
|
|
|
|
# XXX
|
2008-10-27 10:58:42 +03:00
|
|
|
EXTRALIBDIRS= ${DESTDIR}${LIBDIR} ${DESTDIR}${LIBDIR}/i18n ${DESTDIR}${LIBDIR}/security
|
2008-10-26 10:38:27 +03:00
|
|
|
.PRECIOUS: ${EXTRALIBDIRS}
|
|
|
|
install: ${EXTRALIBDIRS} .WAIT
|
|
|
|
${EXTRALIBDIRS}: .EXEC
|
|
|
|
@if [ ! -d ${.TARGET} ] ; then \
|
|
|
|
${_MKSHMSG_CREATE} ${.TARGET}; \
|
|
|
|
${_MKSHECHO} ${INSTALL_DIR} -o ${BINOWN} -g ${BINGRP} -m 755 \
|
|
|
|
${.TARGET}; \
|
|
|
|
${INSTALL_DIR} -o ${BINOWN} -g ${BINGRP} -m 755 \
|
|
|
|
${.TARGET}; \
|
|
|
|
fi
|
|
|
|
# Make sure the base dir is created first.
|
2008-10-27 10:58:42 +03:00
|
|
|
${DESTDIR}${LIBDIR}/i18n ${DESTDIR}${LIBDIR}/security: ${DESTDIR}${LIBDIR}
|