Files
axe-os/build/libstdc++/build.bash

53 lines
795 B
Bash

. "$PROJECTDIR/build/gcc/package.env"
fetch $GCC_URL
cd "$SOURCES" && tar xf gcc-$GCC_VERSION.tar.xz && cd gcc-$GCC_VERSION
bootstrap() {
mkdir -p build && cd build
../libstdc++-v3/configure \
--host=$TARGET \
--build=$(../config.guess) \
--prefix=/usr \
--disable-multilib \
--disable-nls \
--disable-libstdcxx-pch \
--with-gxx-include-dir=/cross/$TARGET/include/c++/$GCC_VERSION > /dev/null
make > /dev/null && make DESTDIR="$SYSROOT" install > /dev/null
rm "$SYSROOT/usr/lib/lib{stdc++{,exp,fs},supc++}.la"
}
toolchain() {
echo toolchain
}
setup() {
echo setup
}
final() {
echo final
}
case $1 in
bootstrap)
bootstrap
;;
toolchain)
toolchain
;;
setup)
setup
;;
final)
final
;;
esac
cd "$SOURCES" && rm -rf "$SOURCES/gcc-$GCC_VERSION"