Releases: isuruf/gcc
Releases · isuruf/gcc
gfortran 11.3.0
ver=${1:-11.3.0}
arch=${2:-x86_64}
build=${3:-${arch}}
if [[ "$arch" == "x86_64" ]]; then
export CONDA_HOST_SUBDIR="osx-64"
kern_ver=13.4.0
else
export CONDA_HOST_SUBDIR="osx-arm64"
kern_ver=20.0.0
fi
if [[ "$build" == "x86_64" ]]; then
export CONDA_BUILD_SUBDIR="osx-64"
else
export CONDA_BUILD_SUBDIR="osx-arm64"
fi
if [[ "$arch" == "${build}" ]]; then
type="native"
else
type="cross"
fi
CONDA_SUBDIR=$CONDA_BUILD_SUBDIR mamba create -n gfortran-darwin-${arch}-${type} gfortran_impl_${CONDA_SUBDIR}=${ver} libgfortran-devel_$CONDA_SUBDIR=${ver} --yes
CODNA_SUBDIR=$CONDA_HOST_SUBDIR mamba install -n gfortran-darwin-${arch}-${type} libgfortran5=${ver} --yes
conda activate gfortran-darwin-${arch}-${type}
rm -rf $CONDA_PREFIX/lib/{libc++*,*.a,pkgconfig,clang}
rm -rf $CONDA_PREFIX/{include,conda-meta,bin/iconv}
for f in $CONDA_PREFIX/lib/{libgmp.dylib,libgmpxx.dylib,libisl.dylib,libiconv.dylib,libmpfr.dylib,libz.dylib,libcharset.dylib,libmpc.dylib}; do
install_name_tool -delete_rpath $CONDA_PREFIX/lib $f || true;
install_name_tool -delete_rpath $CONDA_PREFIX/lib $f || true;
rm $f;
done
rm $CONDA_PREFIX/lib/libiomp5.dylib
if [[ "$type" == "cross" ]]; then
mv $CONDA_PREFIX/lib/{libgfortran*,libgomp*,libomp*,libgcc_s*} $CONDA_PREFIX/lib/gcc/${arch}-apple-darwin${kern_ver}/${ver}
fi
ln -sf /usr/bin/ld $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/ld
sed -i '' "s#-rpath $CONDA_PREFIX/lib##g" $CONDA_PREFIX/lib/gcc/${arch}-apple-darwin${kern_ver}/${ver}/libgfortran.spec
rm $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/cc1
mv $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/cc1.bin $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/cc1
pushd $CONDA_PREFIX/../
grep -ir "isuruf" gfortran-darwin-${arch}-${type}/
tar -czf gfortran-darwin-${arch}-${type}.tar.gz gfortran-darwin-${arch}-${type}
popd
mv $CONDA_PREFIX/../gfortran-darwin-${arch}-${type}.tar.gz .
gfortran 11.3.0
ver=${1:-11.3.0}
arch=${2:-x86_64}
build=${3:-${arch}}
if [[ "$arch" == "x86_64" ]]; then
export CONDA_HOST_SUBDIR="osx-64"
kern_ver=13.4.0
else
export CONDA_HOST_SUBDIR="osx-arm64"
kern_ver=20.0.0
fi
if [[ "$build" == "x86_64" ]]; then
export CONDA_BUILD_SUBDIR="osx-64"
else
export CONDA_BUILD_SUBDIR="osx-arm64"
fi
if [[ "$arch" == "${build}" ]]; then
type="native"
else
type="cross"
fi
CONDA_SUBDIR=$CONDA_BUILD_SUBDIR mamba create -n gfortran-darwin-${arch}-${type} gfortran_impl_${CONDA_HOST_SUBDIR}=${ver} libgfortran-devel_${CONDA_HOST_SUBDIR}=${ver} --yes
CONDA_SUBDIR=$CONDA_HOST_SUBDIR mamba install -n gfortran-darwin-${arch}-${type} libgfortran5=${ver} --yes
conda activate gfortran-darwin-${arch}-${type}
rm -rf $CONDA_PREFIX/lib/{libc++*,*.a,pkgconfig,clang}
rm -rf $CONDA_PREFIX/{include,conda-meta,bin/iconv}
for f in $CONDA_PREFIX/lib/{libgmp.dylib,libgmpxx.dylib,libisl.dylib,libiconv.dylib,libmpfr.dylib,libz.dylib,libcharset.dylib,libmpc.dylib}; do
#install_name_tool -delete_rpath $CONDA_PREFIX/lib $f || true;
rm $f;
done
rm $CONDA_PREFIX/lib/libiomp5.dylib
install_name_tool -change $CONDA_PREFIX/lib/libgcc_s.1.1.dylib '@rpath/libgcc_s.1.1.dylib' $CONDA_PREFIX/lib/libgcc_s.1.dylib
if [[ "$type" == "cross" ]]; then
mv $CONDA_PREFIX/lib/{libgfortran*,libgomp*,libomp*,libgcc_s*,libquadmath*} $CONDA_PREFIX/lib/gcc/${arch}-apple-darwin${kern_ver}/${ver}
fi
ln -sf /usr/bin/ld $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/ld
sed -i '' "s#-rpath $CONDA_PREFIX/lib##g" $CONDA_PREFIX/lib/gcc/${arch}-apple-darwin${kern_ver}/${ver}/libgfortran.spec
rm $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/cc1
mv $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/cc1.bin $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/cc1
pushd $CONDA_PREFIX/../
grep -ir "isuruf" gfortran-darwin-${arch}-${type}/
tar -czf gfortran-darwin-${arch}-${type}.tar.gz gfortran-darwin-${arch}-${type}
popd
mv $CONDA_PREFIX/../gfortran-darwin-${arch}-${type}.tar.gz .
gfortran 11.3.0
ver=${1:-11.3.0}
arch=${2:-x86_64}
build=${3:-${arch}}
if [[ "$arch" == "x86_64" ]]; then
export CONDA_HOST_SUBDIR="osx-64"
kern_ver=13.4.0
else
export CONDA_HOST_SUBDIR="osx-arm64"
kern_ver=20.0.0
fi
if [[ "$build" == "x86_64" ]]; then
export CONDA_BUILD_SUBDIR="osx-64"
else
export CONDA_BUILD_SUBDIR="osx-arm64"
fi
if [[ "$arch" == "${build}" ]]; then
type="native"
else
type="cross"
fi
CONDA_SUBDIR=$CONDA_BUILD_SUBDIR mamba create -n gfortran-darwin-${arch}-${type} gfortran_impl_${CONDA_HOST_SUBDIR}=${ver} libgfortran-devel_$CONDA_HOST_SUBDIR=${ver} --yes
CONDA_SUBDIR=$CONDA_HOST_SUBDIR mamba install -n gfortran-darwin-${arch}-${type} libgfortran5=${ver} --yes
conda activate gfortran-darwin-${arch}-${type}
rm -rf $CONDA_PREFIX/lib/{libc++*,*.a,pkgconfig,clang}
rm -rf $CONDA_PREFIX/{include,conda-meta,bin/iconv}
for f in $CONDA_PREFIX/lib/{libgmp.dylib,libgmpxx.dylib,libisl.dylib,libiconv.dylib,libmpfr.dylib,libz.dylib,libcharset.dylib,libmpc.dylib}; do
install_name_tool -delete_rpath $CONDA_PREFIX/lib $f || true;
rm $f;
done
rm $CONDA_PREFIX/lib/libiomp5.dylib
install_name_tool -change $CONDA_PREFIX/lib/libgcc_s.1.1.dylib '@rpath/libgcc_s.1.1.dylib' $CONDA_PREFIX/lib/libgcc_s.1.dylib
if [[ "$type" == "cross" ]]; then
mv $CONDA_PREFIX/lib/{libgfortran*,libgomp*,libomp*,libgcc_s*} $CONDA_PREFIX/lib/gcc/${arch}-apple-darwin${kern_ver}/${ver}
fi
ln -sf /usr/bin/ld $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/ld
sed -i '' "s#-rpath $CONDA_PREFIX/lib##g" $CONDA_PREFIX/lib/gcc/${arch}-apple-darwin${kern_ver}/${ver}/libgfortran.spec
rm $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/cc1
mv $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/cc1.bin $CONDA_PREFIX/libexec/gcc/${arch}-apple-darwin${kern_ver}/${ver}/cc1
pushd $CONDA_PREFIX/../
grep -ir "isuruf" gfortran-darwin-${arch}-${type}/
tar -czf gfortran-darwin-${arch}-${type}.tar.gz gfortran-darwin-${arch}-${type}
popd
mv $CONDA_PREFIX/../gfortran-darwin-${arch}-${type}.tar.gz .
Small fix for cc1
ver=10.2.1
mamba create -n gfortran-darwin-arm64 gfortran_impl_osx-arm64=${ver} libgfortran-devel_osx-arm64=${ver} --yes
CONDA_SUBDIR=osx-arm64 mamba install -n gfortran-darwin-arm64 libgfortran5=${ver} --yes
conda activate gfortran-darwin-arm64
rm -rf $CONDA_PREFIX/lib/{libc++*,*.a,pkgconfig,clang}
rm -rf $CONDA_PREFIX/{include,conda-meta,bin/iconv}
for f in $CONDA_PREFIX/lib/{libgmp.dylib,libgmpxx.dylib,libisl.dylib,libiconv.dylib,libmpfr.dylib,libz.dylib,libcharset.dylib,libmpc.dylib}; do
install_name_tool -delete_rpath $CONDA_PREFIX/lib $f || true;
install_name_tool -delete_rpath $CONDA_PREFIX/lib $f || true;
rm $f;
done
rm $CONDA_PREFIX/lib/libiomp5.dylib
mv $CONDA_PREFIX/lib/{libgfortran*,libgomp*,libomp*,libgcc_s*} $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}
for f in libgfortran.dylib libgfortran.5.dylib libgcc_s.2.dylib; do
install_name_tool -delete_rpath $CONDA_PREFIX/lib $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}/$f || true;
install_name_tool -delete_rpath $CONDA_PREFIX/lib $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}/$f || true;
done
ln -sf /usr/bin/ld $CONDA_PREFIX/libexec/gcc/arm64-apple-darwin20.0.0/${ver}/ld
sed -i '' "s#-rpath $CONDA_PREFIX/lib##g" $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}/libgfortran.spec
rm $CONDA_PREFIX/libexec/gcc/arm64-apple-darwin20.0.0/${ver}/cc1
mv $CONDA_PREFIX/libexec/gcc/arm64-apple-darwin20.0.0/${ver}/cc1.bin $CONDA_PREFIX/libexec/gcc/arm64-apple-darwin20.0.0/${ver}/cc1
cd $CONDA_PREFIX/../
grep -ir "isuruf" gfortran-darwin-arm64/
tar -czf ../../gfortran-darwin-arm64.tar.gz gfortran-darwin-arm64
gcc-10-arm-20210228
ver=10.2.1
conda create -n gfortran-darwin-arm64 gfortran_impl_osx-arm64=${ver} libgfortran-devel_osx-arm64=${ver} --yes
CONDA_SUBDIR=osx-arm64 conda install -n gfortran-darwin-arm64 libgfortran5=${ver} --yes
conda activate gfortran-darwin-arm64
rm -rf $CONDA_PREFIX/lib/{libc++*,*.a,pkgconfig,clang}
rm -rf $CONDA_PREFIX/{include,conda-meta,bin/iconv}
for f in $CONDA_PREFIX/lib/{libgmp.dylib,libgmpxx.dylib,libisl.dylib,libiconv.dylib,libmpfr.dylib,libz.dylib,libcharset.dylib,libmpc.dylib}; do
install_name_tool -delete_rpath $CONDA_PREFIX/lib $f || true;
install_name_tool -delete_rpath $CONDA_PREFIX/lib $f || true;
rm $f;
done
rm $CONDA_PREFIX/lib/libiomp5.dylib
mv $CONDA_PREFIX/lib/{libgfortran*,libgomp*,libomp*,libgcc_s*} $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}
for f in libgfortran.dylib libgfortran.5.dylib libgcc_s.2.dylib; do
install_name_tool -delete_rpath $CONDA_PREFIX/lib $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}/$f || true;
install_name_tool -delete_rpath $CONDA_PREFIX/lib $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}/$f || true;
done
ln -sf /usr/bin/ld $CONDA_PREFIX/libexec/gcc/arm64-apple-darwin20.0.0/${ver}/ld
sed -i '' "s#-rpath $CONDA_PREFIX/lib##g" $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}/libgfortran.spec
cd $CONDA_PREFIX/../
grep -ir "isuruf" gfortran-darwin-arm64/
tar -czf ../../gfortran-darwin-arm64.tar.gz gfortran-darwin-arm64
gcc-10-arm-20210122
Built from conda package
ver=10.2.1
conda create -n gfortran-darwin-arm64 gfortran_impl_osx-arm64=${ver} libgfortran-devel_osx-arm64=${ver} --yes
CONDA_SUBDIR=osx-arm64 conda install -n gfortran-darwin-arm64 libgfortran5=${ver} --yes
conda activate gfortran-darwin-arm64
rm -rf $CONDA_PREFIX/lib/{libc++*,*.a,libgmp.dylib,libgmpxx.dylib,libisl.dylib,libmpfr.dylib,libz.dylib,pkgconfig,libcharset.dylib,clang,libmpc.dylib}
rm -rf $CONDA_PREFIX/{include,conda-meta,bin/iconv}
mv $CONDA_PREFIX/lib/{libgfortran*,libgomp*,libomp*,libgcc_s*} $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}
ln -sf /usr/bin/ld $CONDA_PREFIX/libexec/gcc/arm64-apple-darwin20.0.0/${ver}/ld
sed -i '' "s#-rpath $CONDA_PREFIX/lib##g" $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}/libgfortran.spec
cd $CONDA_PREFIX/../
tar -czf ../../gfortran-darwin-arm64.tar.gz gfortran-darwin-arm64
gcc-10-arm-20210112
Built from conda package
ver=10.2.1
conda create -n gfortran-darwin-arm64 gfortran_impl_osx-arm64=${ver} libgfortran-devel_osx-arm64=${ver} --yes
CONDA_SUBDIR=osx-arm64 conda install -n gfortran-darwin-arm64 libgfortran5=${ver} --yes
conda activate gfortran-darwin-arm64
rm -rf $CONDA_PREFIX/lib/{libc++*,*.a,libgmp.dylib,libgmpxx.dylib,libisl.dylib,libmpfr.dylib,libz.dylib,pkgconfig,libcharset.dylib,clang,libmpc.dylib}
rm -rf $CONDA_PREFIX/{include,conda-meta,bin/iconv}
mv $CONDA_PREFIX/lib/{libgfortran*,libgomp*,libomp*,libgcc_s*} $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}
ln -sf /usr/bin/ld $CONDA_PREFIX/libexec/gcc/arm64-apple-darwin20.0.0/${ver}/ld
sed -i '' "s#-rpath $CONDA_PREFIX/lib##g" $CONDA_PREFIX/lib/gcc/arm64-apple-darwin20.0.0/${ver}/libgfortran.spec
cd $CONDA_PREFIX/../
tar -czf ../../gfortran-darwin-arm64.tar.gz gfortran-darwin-arm64