gcc-fortran: adopted port
This commit is contained in:
parent
4ad7ed5714
commit
dce3543fa5
@ -1,6 +1,6 @@
|
||||
untrusted comment: verify with /etc/ports/contrib.pub
|
||||
RWSagIOpLGJF31q8SHGRWfNhrMMMN/LOHiHlsf0eC+fhIMvfUnIHfCbna55fbgf20FqVeDsyZ5ddq0tF4cV3niXMDiJeq4F5agM=
|
||||
SHA256 (Pkgfile) = 295a26e76860a1638f8ad462d241ff3fd3f811d498199340435245ef3b2a72e1
|
||||
RWSagIOpLGJF30milQ+wI/+8Q8PQN76O5m+FbxmhuC2fjowUKehQudrKIiYXiAf+/MvPn8nqU8CFpoQL6YdjIsD2RuWdewV8dQQ=
|
||||
SHA256 (Pkgfile) = 69eed6b0ab65266b7e03de3eb59b1deeea026118fb82fae5e4fadc14a4c24683
|
||||
SHA256 (.footprint) = a37627fc4a244fbba97d00069f9c84427d769f17ab15d16aa16270c3ce9a392c
|
||||
SHA256 (gcc-12.3.0.tar.xz) = 949a5d4f99e786421a93b532b22ffab5578de7321369975b91aec97adfda8c3b
|
||||
SHA256 (gcc-nocheck-fixincludes.patch) = 850a71d2c64b9f2bec31821bd972bf89c2d57764faf64948100eaf474fd63bbb
|
||||
|
@ -1,76 +1,76 @@
|
||||
# URL: http://gcc.gnu.org/fortran
|
||||
# Description: Fortran (f95) add-on for GNU GCC compiler.
|
||||
# Maintainer: Danny Rawlins, crux at romster dot me
|
||||
# Maintainer: Tim Biermann, tbier at posteo dot de
|
||||
# Depends on: libmpfr
|
||||
|
||||
name=gcc-fortran
|
||||
version=12.3.0
|
||||
release=1
|
||||
source=(ftp://gcc.gnu.org/pub/gcc/releases/gcc-$version/gcc-$version.tar.xz
|
||||
gcc-nocheck-fixincludes.patch gcc-4.7.3-multilib-dirs.patch)
|
||||
gcc-nocheck-fixincludes.patch gcc-4.7.3-multilib-dirs.patch)
|
||||
|
||||
build() {
|
||||
patch -d gcc-$version -p 1 -i $SRC/gcc-nocheck-fixincludes.patch
|
||||
patch -d gcc-$version -p 1 -i $SRC/gcc-4.7.3-multilib-dirs.patch
|
||||
patch -d gcc-$version -p 1 -i $SRC/gcc-nocheck-fixincludes.patch
|
||||
patch -d gcc-$version -p 1 -i $SRC/gcc-4.7.3-multilib-dirs.patch
|
||||
|
||||
# Do not run fixincludes
|
||||
sed -i -e 's|\./fixinc\.sh|-c true|' gcc-$version/gcc/Makefile.in
|
||||
# Do not run fixincludes
|
||||
sed -i -e 's|\./fixinc\.sh|-c true|' gcc-$version/gcc/Makefile.in
|
||||
|
||||
install -d build
|
||||
cd build
|
||||
install -d build
|
||||
cd build
|
||||
|
||||
../gcc-$version/configure \
|
||||
--prefix=/usr \
|
||||
--libexecdir=/usr/lib \
|
||||
--enable-languages=fortran \
|
||||
--enable-threads=posix \
|
||||
--enable-__cxa_atexit \
|
||||
--enable-clocale=gnu \
|
||||
--enable-shared \
|
||||
--disable-nls \
|
||||
--with-x=no \
|
||||
--with-system-zlib \
|
||||
--enable-multilib \
|
||||
--disable-sjlj-exceptions \
|
||||
--with-pkgversion="CRUX-x86_64-multilib"
|
||||
../gcc-$version/configure \
|
||||
--prefix=/usr \
|
||||
--libexecdir=/usr/lib \
|
||||
--enable-languages=fortran \
|
||||
--enable-threads=posix \
|
||||
--enable-__cxa_atexit \
|
||||
--enable-clocale=gnu \
|
||||
--enable-shared \
|
||||
--disable-nls \
|
||||
--with-x=no \
|
||||
--with-system-zlib \
|
||||
--enable-multilib \
|
||||
--disable-sjlj-exceptions \
|
||||
--with-pkgversion="CRUX-x86_64-multilib"
|
||||
|
||||
if [ -n "$(pkginfo -i | grep '^ccache ')" ]; then
|
||||
make STAGE_CC_WRAPPER='/usr/bin/ccache' BOOT_CFLAGS="$CFLAGS" bootstrap
|
||||
else
|
||||
make BOOT_CFLAGS="$CFLAGS" bootstrap
|
||||
fi
|
||||
if [ -n "$(pkginfo -i | grep '^ccache ')" ]; then
|
||||
make STAGE_CC_WRAPPER='/usr/bin/ccache' BOOT_CFLAGS="$CFLAGS" bootstrap
|
||||
else
|
||||
make BOOT_CFLAGS="$CFLAGS" bootstrap
|
||||
fi
|
||||
|
||||
make -j 1 DESTDIR=$PKG install
|
||||
make -j 1 DESTDIR=$PKG install
|
||||
|
||||
ln -fs gfortran $PKG/usr/bin/f90
|
||||
ln -fs gfortran $PKG/usr/bin/f95
|
||||
ln -fs gfortran $PKG/usr/bin/g77
|
||||
ln -fs gfortran $PKG/usr/bin/f90
|
||||
ln -fs gfortran $PKG/usr/bin/f95
|
||||
ln -fs gfortran $PKG/usr/bin/g77
|
||||
|
||||
for D in lib{,32}; do
|
||||
install -d -m 0755 $PKG/usr/share/gdb/auto-load/usr/${D}
|
||||
mv $PKG/usr/${D}/libstdc++.so.*-gdb.py $PKG/usr/share/gdb/auto-load/usr/${D}
|
||||
done
|
||||
for D in lib{,32}; do
|
||||
install -d -m 0755 $PKG/usr/share/gdb/auto-load/usr/${D}
|
||||
mv $PKG/usr/${D}/libstdc++.so.*-gdb.py $PKG/usr/share/gdb/auto-load/usr/${D}
|
||||
done
|
||||
|
||||
# remove files already on the system out of the port
|
||||
for i in $(pkginfo -l gcc | sed -e "s|^|/|") $(pkginfo -l binutils | sed -e "s|^|/|"); do
|
||||
if [ -e "$i" ] && [ ! -d "$i" ]; then
|
||||
if [ -e "$PKG$i" ]; then
|
||||
rm "$PKG$i"
|
||||
fi
|
||||
# check for compressed manpages
|
||||
if [ -e "$PKG${i%%.gz}" ]; then
|
||||
rm "$PKG${i%%.gz}"
|
||||
fi
|
||||
fi
|
||||
done
|
||||
# remove files already on the system out of the port
|
||||
for i in $(pkginfo -l gcc | sed -e "s|^|/|") $(pkginfo -l binutils | sed -e "s|^|/|"); do
|
||||
if [ -e "$i" ] && [ ! -d "$i" ]; then
|
||||
if [ -e "$PKG$i" ]; then
|
||||
rm "$PKG$i"
|
||||
fi
|
||||
# check for compressed manpages
|
||||
if [ -e "$PKG${i%%.gz}" ]; then
|
||||
rm "$PKG${i%%.gz}"
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
rm $PKG/usr/bin/*-linux-gnu-*
|
||||
rm -r $PKG/usr/share/{info,gcc-$version}
|
||||
rm -r $PKG/usr/lib/gcc/*/$version/{install-tools,include-fixed}
|
||||
rm $PKG/usr/bin/*-linux-gnu-*
|
||||
rm -r $PKG/usr/share/{info,gcc-$version}
|
||||
rm -r $PKG/usr/lib/gcc/*/$version/{install-tools,include-fixed}
|
||||
|
||||
# Remove empty directories
|
||||
find $PKG -depth -empty -exec rm -r {} \;
|
||||
# Remove empty directories
|
||||
find $PKG -depth -empty -exec rm -r {} \;
|
||||
|
||||
# remove build paths from *.la files
|
||||
sed -i -e "s|-L$SRC[^ ]* ||g" $PKG/usr/lib{,32}/libgfortran.la
|
||||
# remove build paths from *.la files
|
||||
sed -i -e "s|-L$SRC[^ ]* ||g" $PKG/usr/lib{,32}/libgfortran.la
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user