Changeset View
Changeset View
Standalone View
Standalone View
head/Makefile.libcompat
Show First 20 Lines • Show All 64 Lines • ▼ Show 20 Lines | |||||
LIBSOFTWMAKEENV= CPUTYPE=soft MACHINE=arm MACHINE_ARCH=${TARGET_ARCH} | LIBSOFTWMAKEENV= CPUTYPE=soft MACHINE=arm MACHINE_ARCH=${TARGET_ARCH} | ||||
LIBSOFTWMAKEFLAGS= -DCOMPAT_SOFTFP | LIBSOFTWMAKEFLAGS= -DCOMPAT_SOFTFP | ||||
.endif | .endif | ||||
# ------------------------------------------------------------------- | # ------------------------------------------------------------------- | ||||
# Generic code for each type. | # Generic code for each type. | ||||
# Set defaults based on type. | # Set defaults based on type. | ||||
libcompat= ${LIBCOMPAT:tl} | libcompat= ${LIBCOMPAT:tl} | ||||
_LIBCOMPAT_MAKEVARS= _OBJTREE TMP CPUFLAGS CFLAGS CXXFLAGS WMAKEENV \ | _LIBCOMPAT_MAKEVARS= _OBJTOP TMP CPUFLAGS CFLAGS CXXFLAGS WMAKEENV \ | ||||
WMAKEFLAGS WMAKE | WMAKEFLAGS WMAKE | ||||
.for _var in ${_LIBCOMPAT_MAKEVARS} | .for _var in ${_LIBCOMPAT_MAKEVARS} | ||||
.if !empty(LIB${LIBCOMPAT}${_var}) | .if !empty(LIB${LIBCOMPAT}${_var}) | ||||
LIBCOMPAT${_var}?= ${LIB${LIBCOMPAT}${_var}} | LIBCOMPAT${_var}?= ${LIB${LIBCOMPAT}${_var}} | ||||
.endif | .endif | ||||
.endfor | .endfor | ||||
# Shared flags | # Shared flags | ||||
LIBCOMPAT_OBJTREE?= ${OBJTREE}${.CURDIR}/obj-lib${libcompat} | LIBCOMPAT_OBJTOP?= ${OBJTOP}/obj-lib${libcompat} | ||||
LIBCOMPATTMP?= ${LIBCOMPAT_OBJTREE}/tmp | LIBCOMPATTMP?= ${LIBCOMPAT_OBJTOP}/tmp | ||||
LIBCOMPATCFLAGS+= ${LIBCOMPATCPUFLAGS} \ | LIBCOMPATCFLAGS+= ${LIBCOMPATCPUFLAGS} \ | ||||
-L${LIBCOMPATTMP}/usr/lib${libcompat} \ | -L${LIBCOMPATTMP}/usr/lib${libcompat} \ | ||||
--sysroot=${LIBCOMPATTMP} \ | --sysroot=${LIBCOMPATTMP} \ | ||||
${BFLAGS} | ${BFLAGS} | ||||
# -B is needed to find /usr/lib32/crti.o for GCC and /usr/libsoft/crti.o for | # -B is needed to find /usr/lib32/crti.o for GCC and /usr/libsoft/crti.o for | ||||
# Clang/GCC. | # Clang/GCC. | ||||
Show All 10 Lines | |||||
.if ${X_COMPILER_TYPE} == gcc && ${X_COMPILER_VERSION} >= 40800 && \ | .if ${X_COMPILER_TYPE} == gcc && ${X_COMPILER_VERSION} >= 40800 && \ | ||||
(${MK_CLANG_BOOTSTRAP} == "no" && ${MK_GCC_BOOTSTRAP} == "no") | (${MK_CLANG_BOOTSTRAP} == "no" && ${MK_GCC_BOOTSTRAP} == "no") | ||||
LIBCOMPATCXXFLAGS+= -isystem ${LIBCOMPATTMP}/usr/include/c++/v1 -std=c++11 \ | LIBCOMPATCXXFLAGS+= -isystem ${LIBCOMPATTMP}/usr/include/c++/v1 -std=c++11 \ | ||||
-nostdinc++ | -nostdinc++ | ||||
.endif | .endif | ||||
.endif | .endif | ||||
# Yes, the flags are redundant. | # Yes, the flags are redundant. | ||||
LIBCOMPATWMAKEENV+= MAKEOBJDIRPREFIX=${LIBCOMPAT_OBJTREE} \ | LIBCOMPATWMAKEENV+= \ | ||||
MAKEOBJDIRPREFIX=${LIBCOMPAT_OBJTOP} \ | |||||
INSTALL="sh ${.CURDIR}/tools/install.sh" \ | INSTALL="sh ${.CURDIR}/tools/install.sh" \ | ||||
PATH=${TMPPATH} \ | PATH=${TMPPATH} \ | ||||
SYSROOT=${LIBCOMPATTMP} \ | SYSROOT=${LIBCOMPATTMP} \ | ||||
LIBDIR=/usr/lib${libcompat} \ | LIBDIR=/usr/lib${libcompat} \ | ||||
SHLIBDIR=/usr/lib${libcompat} \ | SHLIBDIR=/usr/lib${libcompat} \ | ||||
DTRACE="${LIB$COMPATDTRACE:U${DTRACE}}" | DTRACE="${LIB$COMPATDTRACE:U${DTRACE}}" | ||||
.if ${MK_META_MODE} != "no" | .if ${MK_META_MODE} != "no" | ||||
# Don't rebuild build-tools targets during normal build. | # Don't rebuild build-tools targets during normal build. | ||||
▲ Show 20 Lines • Show All 59 Lines • ▼ Show 20 Lines | .for _dir in ${_LC_INCDIRS} | ||||
${_+_}cd ${.CURDIR}/${_dir}; ${LIBCOMPATWMAKE} MK_INCLUDES=yes \ | ${_+_}cd ${.CURDIR}/${_dir}; ${LIBCOMPATWMAKE} MK_INCLUDES=yes \ | ||||
DIRPRFX=${_dir}/ ${_t} | DIRPRFX=${_dir}/ ${_t} | ||||
.endfor | .endfor | ||||
.endfor | .endfor | ||||
.for _dir in lib/ncurses/ncurses lib/ncurses/ncursesw lib/libmagic | .for _dir in lib/ncurses/ncurses lib/ncurses/ncursesw lib/libmagic | ||||
${_+_}cd ${.CURDIR}/${_dir}; \ | ${_+_}cd ${.CURDIR}/${_dir}; \ | ||||
WORLDTMP=${WORLDTMP} \ | WORLDTMP=${WORLDTMP} \ | ||||
MAKEFLAGS="-m ${.CURDIR}/tools/build/mk ${.MAKEFLAGS}" \ | MAKEFLAGS="-m ${.CURDIR}/tools/build/mk ${.MAKEFLAGS}" \ | ||||
MAKEOBJDIRPREFIX=${LIBCOMPAT_OBJTREE} ${MAKE} SSP_CFLAGS= DESTDIR= \ | MAKEOBJDIRPREFIX=${LIBCOMPAT_OBJTOP} \ | ||||
${MAKE} SSP_CFLAGS= DESTDIR= \ | |||||
DIRPRFX=${_dir}/ -DNO_LINT -DNO_CPU_CFLAGS MK_WARNS=no MK_CTF=no \ | DIRPRFX=${_dir}/ -DNO_LINT -DNO_CPU_CFLAGS MK_WARNS=no MK_CTF=no \ | ||||
build-tools | build-tools | ||||
.endfor | .endfor | ||||
${_+_}cd ${.CURDIR}; \ | ${_+_}cd ${.CURDIR}; \ | ||||
${LIBCOMPATWMAKE} -f Makefile.inc1 -DNO_FSCHG libraries | ${LIBCOMPATWMAKE} -f Makefile.inc1 -DNO_FSCHG libraries | ||||
.if ${libcompat} == "32" | .if ${libcompat} == "32" | ||||
.for _t in ${_obj} all | .for _t in ${_obj} all | ||||
.if !defined(NO_RTLD) | .if !defined(NO_RTLD) | ||||
Show All 22 Lines |