Fix xdev. Clang and libc were not building correctly on older worlds, for
example, on 9.1. * To fix clang add an _xb-bootstrap-tools target that mirrors the existing bootstrap-tools target in the full world. * For libc have the compiler use the newly installed includes, and, while here, tell the compiler about the xdev library path as some other libraries will link against the installed libraries.
This commit is contained in:
parent
77d8fd9bb3
commit
45fab5d871
@ -1745,11 +1745,12 @@ CDBENV=MAKEOBJDIRPREFIX=${MAKEOBJDIRPREFIX}/${XDDIR} \
|
|||||||
CDENV= ${CDBENV} \
|
CDENV= ${CDBENV} \
|
||||||
_SHLIBDIRPREFIX=${XDTP} \
|
_SHLIBDIRPREFIX=${XDTP} \
|
||||||
TOOLS_PREFIX=${XDTP}
|
TOOLS_PREFIX=${XDTP}
|
||||||
CD2ENV=${CDENV} \
|
CD2CFLAGS=-isystem ${XDTP}/usr/include -L${XDTP}/usr/lib -B${XDTP}/usr/lib
|
||||||
|
CD2ENV=${CDENV} CC="${CC} ${CD2CFLAGS}" \
|
||||||
MACHINE=${XDEV} MACHINE_ARCH=${XDEV_ARCH}
|
MACHINE=${XDEV} MACHINE_ARCH=${XDEV_ARCH}
|
||||||
|
|
||||||
CDTMP= ${MAKEOBJDIRPREFIX}/${XDEV}/${.CURDIR}/tmp
|
CDTMP= ${MAKEOBJDIRPREFIX}/${XDDIR}/${.CURDIR}/tmp
|
||||||
CDMAKE=${CDENV} ${MAKE} ${NOFUN}
|
CDMAKE=${CDENV} PATH=${CDTMP}/usr/bin:${PATH} ${MAKE} ${NOFUN}
|
||||||
CD2MAKE=${CD2ENV} PATH=${CDTMP}/usr/bin:${XDTP}/usr/bin:${PATH} ${MAKE} ${NOFUN}
|
CD2MAKE=${CD2ENV} PATH=${CDTMP}/usr/bin:${XDTP}/usr/bin:${PATH} ${MAKE} ${NOFUN}
|
||||||
XDDESTDIR=${DESTDIR}${XDTP}
|
XDDESTDIR=${DESTDIR}${XDTP}
|
||||||
.if !defined(OSREL)
|
.if !defined(OSREL)
|
||||||
@ -1759,8 +1760,24 @@ OSREL!= uname -r | sed -e 's/[-(].*//'
|
|||||||
.ORDER: xdev-build xdev-install
|
.ORDER: xdev-build xdev-install
|
||||||
xdev: xdev-build xdev-install
|
xdev: xdev-build xdev-install
|
||||||
|
|
||||||
.ORDER: _xb-build-tools _xb-cross-tools
|
.ORDER: _xb-worldtmp _xb-bootstrap-tools _xb-build-tools _xb-cross-tools
|
||||||
xdev-build: _xb-build-tools _xb-cross-tools
|
xdev-build: _xb-worldtmp _xb-bootstrap-tools _xb-build-tools _xb-cross-tools
|
||||||
|
|
||||||
|
_xb-worldtmp:
|
||||||
|
mkdir -p ${CDTMP}/usr
|
||||||
|
mtree -deU -f ${.CURDIR}/etc/mtree/BSD.usr.dist \
|
||||||
|
-p ${CDTMP}/usr >/dev/null
|
||||||
|
|
||||||
|
_xb-bootstrap-tools:
|
||||||
|
.for _tool in \
|
||||||
|
${_clang_tblgen}
|
||||||
|
${_+_}@${ECHODIR} "===> ${_tool} (obj,depend,all,install)"; \
|
||||||
|
cd ${.CURDIR}/${_tool}; \
|
||||||
|
${CDMAKE} DIRPRFX=${_tool}/ obj; \
|
||||||
|
${CDMAKE} DIRPRFX=${_tool}/ depend; \
|
||||||
|
${CDMAKE} DIRPRFX=${_tool}/ all; \
|
||||||
|
${CDMAKE} DIRPRFX=${_tool}/ DESTDIR=${CDTMP} install
|
||||||
|
.endfor
|
||||||
|
|
||||||
_xb-build-tools:
|
_xb-build-tools:
|
||||||
${_+_}@cd ${.CURDIR}; \
|
${_+_}@cd ${.CURDIR}; \
|
||||||
@ -1770,7 +1787,9 @@ _xb-cross-tools:
|
|||||||
.for _tool in \
|
.for _tool in \
|
||||||
gnu/usr.bin/binutils \
|
gnu/usr.bin/binutils \
|
||||||
gnu/usr.bin/cc \
|
gnu/usr.bin/cc \
|
||||||
usr.bin/ar
|
usr.bin/ar \
|
||||||
|
${_clang_libs} \
|
||||||
|
${_clang}
|
||||||
${_+_}@${ECHODIR} "===> xdev ${_tool} (obj,depend,all)"; \
|
${_+_}@${ECHODIR} "===> xdev ${_tool} (obj,depend,all)"; \
|
||||||
cd ${.CURDIR}/${_tool}; \
|
cd ${.CURDIR}/${_tool}; \
|
||||||
${CDMAKE} DIRPRFX=${_tool}/ obj; \
|
${CDMAKE} DIRPRFX=${_tool}/ obj; \
|
||||||
@ -1796,7 +1815,8 @@ _xi-cross-tools:
|
|||||||
.for _tool in \
|
.for _tool in \
|
||||||
gnu/usr.bin/binutils \
|
gnu/usr.bin/binutils \
|
||||||
gnu/usr.bin/cc \
|
gnu/usr.bin/cc \
|
||||||
usr.bin/ar
|
usr.bin/ar \
|
||||||
|
${_clang}
|
||||||
${_+_}@${ECHODIR} "===> xdev ${_tool} (install)"; \
|
${_+_}@${ECHODIR} "===> xdev ${_tool} (install)"; \
|
||||||
cd ${.CURDIR}/${_tool}; \
|
cd ${.CURDIR}/${_tool}; \
|
||||||
${CDMAKE} DIRPRFX=${_tool}/ install DESTDIR=${XDDESTDIR}
|
${CDMAKE} DIRPRFX=${_tool}/ install DESTDIR=${XDDESTDIR}
|
||||||
|
Loading…
Reference in New Issue
Block a user