boost: set abi and architecture for all target machines properly.
This commit is contained in:
parent
dc18d57ae0
commit
3c0e0d29d8
|
@ -1,7 +1,7 @@
|
|||
# Template file for 'boost'
|
||||
pkgname=boost
|
||||
version=1.58.0
|
||||
revision=1
|
||||
revision=2
|
||||
wrksrc="${pkgname}_${version//\./_}"
|
||||
hostmakedepends="bzip2-devel"
|
||||
makedepends="zlib-devel bzip2-devel icu-devel"
|
||||
|
@ -20,23 +20,25 @@ if [ -z "$CROSS_BUILD" ]; then
|
|||
subpackages+=" boost-jam boost-python"
|
||||
fi
|
||||
|
||||
_abi=sysv
|
||||
_toolset=gcc
|
||||
case "$XBPS_TARGET_MACHINE" in
|
||||
arm*) _arch=arm; _toolset="gcc-arm"; _abi=aapcs;;
|
||||
aarch64*) _arch=aarch64; _toolset="gcc-aarch64"; _abi=aapcs;;
|
||||
mips*) _arch=mips; _toolset="gcc-mips"; _abi=o32;;
|
||||
i686*) _arch=i386; _toolset="gcc-i386"; _abi=sysv ;;
|
||||
x86_64*) _arch=x86_64; _toolset="gcc-x86_64"; _abi=sysv ;;
|
||||
arm*) _arch=arm; _toolset="gcc-arm"; _abi=aapcs ;;
|
||||
aarch64*) _arch=arm; _toolset="gcc-aarch64"; _abi=aapcs ;;
|
||||
mips*) _arch=mips; _toolset="gcc-mips"; _abi=o32 ;;
|
||||
esac
|
||||
|
||||
do_build() {
|
||||
if [ "$CROSS_BUILD" ]; then
|
||||
echo "using gcc : ${_arch} : ${XBPS_CROSS_TRIPLET}-g++ ${CXXFLAGS} ;" > user-config.jam
|
||||
echo "using gcc : ${_toolset#gcc-} : ${XBPS_CROSS_TRIPLET}-g++ ${CXXFLAGS} ;" \
|
||||
> user-config.jam
|
||||
else
|
||||
echo "using gcc : : g++ ${CXXFLAGS} ;" > user-config.jam
|
||||
echo "using gcc : ${_toolset#gcc-} : g++ ${CXXFLAGS} ;" \
|
||||
> user-config.jam
|
||||
fi
|
||||
./bootstrap.sh -prefix=${DESTDIR}/usr
|
||||
./bjam --toolset=${_toolset} ${makejobs} abi=$_abi \
|
||||
--user-config=${wrksrc}/user-config.jam
|
||||
./bjam --toolset=${_toolset} ${makejobs} abi=$_abi architecture=$_arch \
|
||||
--user-config=${wrksrc}/user-config.jam --debug-building
|
||||
}
|
||||
|
||||
do_install() {
|
||||
|
@ -46,7 +48,7 @@ do_install() {
|
|||
fi
|
||||
|
||||
# Install headers/libs
|
||||
./bjam --prefix=${DESTDIR}/usr abi=$_abi \
|
||||
./bjam --prefix=${DESTDIR}/usr abi=$_abi architecture=$_arch \
|
||||
--user-config=${wrksrc}/user-config.jam install
|
||||
|
||||
# Install Boost.Build stuff.
|
||||
|
|
Loading…
Reference in New Issue
Block a user