dmd-bootstrap: cleanup wordsize

This commit is contained in:
q66 2020-12-22 21:47:26 +01:00
parent 110f8b2d12
commit 7a21151669

View file

@ -37,39 +37,28 @@ pre_configure() {
}
do_build() {
local bits dmd
case "$XBPS_TARGET_MACHINE" in
x86_64*) bits=64;;
i686*) bits=32;;
esac
local dmd
cd dmd/src
make ${makejobs} -f posix.mak HOST_CXX=$CXX MODEL=$bits TARGET_CPU=X86 RELEASE=1 all
make ${makejobs} -f posix.mak HOST_CXX=$CXX MODEL=${XBPS_TARGET_WORDSIZE} \
TARGET_CPU=X86 RELEASE=1 all
dmd=${wrksrc}/dmd/src/dmd
cd ../../druntime
make ${makejobs} -f posix.mak MODEL=$bits DMD=$dmd RELEASE=1
make ${makejobs} -f posix.mak MODEL=${XBPS_TARGET_WORDSIZE} DMD=$dmd RELEASE=1
cd ../phobos
make ${makejobs} -f posix.mak MODEL=$bits DMD=$dmd RELEASE=1
make ${makejobs} -f posix.mak MODEL=${XBPS_TARGET_WORDSIZE} DMD=$dmd RELEASE=1
}
do_install() {
local bits
case "$XBPS_TARGET_MACHINE" in
x86_64*) bits=64;;
i686*) bits=32;;
esac
cd dmd/src
vbin dmd
vmkdir etc
cat > $DESTDIR/etc/dmd.conf <<EOF
[Environment]
DFLAGS=-I/usr/include/dlang/dmd -L-L/usr/lib -L-L/usr/lib32 -L--export-dynamic
DFLAGS=-I/usr/include/dlang/dmd -L-L/usr/lib${XBPS_TARGET_WRODSIZE} -L--export-dynamic
EOF
vlicense backendlicense.txt
@ -82,7 +71,7 @@ EOF
vcopy docs/man/man5/* usr/share/man/man5/
cd ..
vinstall phobos/generated/linux/release/$bits/libphobos2.a 0644 usr/lib
vinstall phobos/generated/linux/release/${XBPS_TARGET_WORDSIZE}/libphobos2.a 0644 usr/lib
vmkdir usr/include/dlang/dmd
vcopy phobos/*.d usr/include/dlang/dmd
vcopy phobos/etc usr/include/dlang/dmd