mirror of
https://github.com/ivabus/pantry
synced 2024-11-23 08:55:07 +03:00
update(gcc12)
This commit is contained in:
parent
98e4a91c8b
commit
857a6a6e2d
1 changed files with 33 additions and 25 deletions
|
@ -26,42 +26,50 @@ build:
|
||||||
gnu.org/patch: '*'
|
gnu.org/patch: '*'
|
||||||
curl.se: '*'
|
curl.se: '*'
|
||||||
working-directory: build
|
working-directory: build
|
||||||
script: |
|
script:
|
||||||
# Remove: cleanup bootstrap version
|
# If we have a patch, apply it
|
||||||
if test -d {{deps.gnu.org/gcc.prefix}}/lib64; then
|
- |
|
||||||
mv {{deps.gnu.org/gcc.prefix}}/lib64/* {{deps.gnu.org/gcc.prefix}}/lib/
|
if test -n "$PATCH{{version.major}}{{version.minor}}"; then
|
||||||
rmdir {{deps.gnu.org/gcc.prefix}}/lib64
|
curl "$PATCH{{version.major}}{{version.minor}}" | patch -p1 -d..
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test -n "$PATCH{{version.major}}"; then
|
# if there's no diff yet, unpack iains' source over ours
|
||||||
curl "$PATCH{{version.major}}" | patch -p1 -d..
|
- |
|
||||||
|
if test -n "$BRANCH{{version.major}}{{version.minor}}"; then
|
||||||
|
curl -L "$BRANCH{{version.major}}{{version.minor}}" | tar xz --strip-components=1 -C ..
|
||||||
fi
|
fi
|
||||||
|
|
||||||
ARGS=($ARGS --with-pkgversion="tea GCC {{version}}")
|
# The spaces mess things up in the env key
|
||||||
|
- ARGS=($ARGS --with-pkgversion="tea GCC {{version}}")
|
||||||
|
|
||||||
|
# On Linux, we need to statically link libstdc++ and libgcc
|
||||||
|
- |
|
||||||
if test {{hw.platform}} = "linux"; then
|
if test {{hw.platform}} = "linux"; then
|
||||||
export ARGS=("${ARGS[@]}" --with-boot-ldflags="-static-libstdc++ -static-libgcc $LDFLAGS")
|
export ARGS=("${ARGS[@]}" --with-boot-ldflags="-static-libstdc++ -static-libgcc $LDFLAGS")
|
||||||
fi
|
fi
|
||||||
|
|
||||||
../configure "${ARGS[@]}"
|
- ../configure "${ARGS[@]}"
|
||||||
make --jobs {{ hw.concurrency }}
|
- make --jobs {{ hw.concurrency }}
|
||||||
make install
|
- make install
|
||||||
|
|
||||||
cd {{prefix}}/bin
|
|
||||||
# Since we depend on ourselves, this symlink might already exist
|
# Since we depend on ourselves, this symlink might already exist
|
||||||
test -f gc++ || ln -sf c++ gc++
|
- run: test -f gc++ || ln -sf c++ gc++
|
||||||
|
working-directory: ${{prefix}}/bin
|
||||||
|
|
||||||
# On Linux, we need to move the libraries to the lib directory.
|
# On Linux, we need to move the libraries to the lib directory.
|
||||||
|
- run: |
|
||||||
if test {{hw.platform}} = "linux"; then
|
if test {{hw.platform}} = "linux"; then
|
||||||
cd {{prefix}}
|
|
||||||
mv lib64/* lib/
|
mv lib64/* lib/
|
||||||
rmdir lib64
|
rmdir lib64
|
||||||
fi
|
fi
|
||||||
|
working-directory: ${{prefix}}
|
||||||
env:
|
env:
|
||||||
# Branch from the Darwin maintainer of GCC, with a few generic fixes and
|
# Branch from the Darwin maintainer of GCC, with a few generic fixes and
|
||||||
# Apple Silicon support, located at https://github.com/iains/gcc-12-branch
|
# Apple Silicon support, located at https://github.com/iains/gcc-12-branch
|
||||||
PATCH12: https://raw.githubusercontent.com/Homebrew/formula-patches/1d184289/gcc/gcc-12.2.0-arm.diff
|
PATCH122: https://raw.githubusercontent.com/Homebrew/formula-patches/1d184289/gcc/gcc-12.2.0-arm.diff
|
||||||
# https://github.com/iains/gcc-darwin-arm64
|
# https://github.com/iains/gcc-darwin-arm64
|
||||||
PATCH13: https://raw.githubusercontent.com/Homebrew/formula-patches/master/gcc/gcc-13.1.0.diff
|
PATCH131: https://raw.githubusercontent.com/Homebrew/formula-patches/master/gcc/gcc-13.1.0.diff
|
||||||
|
BRANCH123: https://github.com/iains/gcc-12-branch/archive/refs/tags/gcc-12.3-darwin-r0.tar.gz
|
||||||
ARGS:
|
ARGS:
|
||||||
- --prefix={{ prefix }}
|
- --prefix={{ prefix }}
|
||||||
- --libdir={{ prefix }}/lib
|
- --libdir={{ prefix }}/lib
|
||||||
|
|
Loading…
Reference in a new issue