summaryrefslogtreecommitdiffstats
path: root/main/gcc
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2013-07-03 07:17:55 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2013-07-03 07:30:15 +0000
commitfd641092f593d069b998a466b54b882d9c8d7910 (patch)
tree624ddf4b96adabe59dfb17e509981575b190cd31 /main/gcc
parent1ffa83ee5db171b8e38ce7b3ef187565c8e11b54 (diff)
downloadaports-fd641092f593d069b998a466b54b882d9c8d7910.tar.bz2
aports-fd641092f593d069b998a466b54b882d9c8d7910.tar.xz
main/gcc: install gcc specs in proper location
and unify gcclibdir and gcclibexec variables the specs fix should make the vanilla.specs work again. fixes #2129
Diffstat (limited to 'main/gcc')
-rw-r--r--main/gcc/APKBUILD43
1 files changed, 20 insertions, 23 deletions
diff --git a/main/gcc/APKBUILD b/main/gcc/APKBUILD
index c52887682..7d480f752 100644
--- a/main/gcc/APKBUILD
+++ b/main/gcc/APKBUILD
@@ -7,7 +7,7 @@ _specs_gcc_ver=4.4.3
_uclibc_abiver=0.9.32
-pkgrel=6
+pkgrel=7
pkgdesc="The GNU Compiler Collection"
url="http://gcc.gnu.org"
arch="all"
@@ -73,6 +73,8 @@ source="ftp://gcc.gnu.org/pub/gcc/releases/gcc-$pkgver/gcc-$pkgver.tar.bz2
# we build out-of-tree
_gccdir="$srcdir"/gcc-$pkgver
_builddir="$srcdir/build"
+_gcclibdir=/usr/lib/gcc/${CHOST:-$_chost}/$pkgver
+_gcclibexec=/usr/libexec/gcc/${CHOST:-$_chost}/$pkgver
prepare() {
cd "$_gccdir"
@@ -211,9 +213,9 @@ package() {
# install the specs
cd "$srcdir"/specs
- install -d "$pkgdir"/usr/share/gcc
+ install -d "$pkgdir"/$_gcclibdir
for i in *.specs; do
- install -m644 $i "$pkgdir"/usr/share/gcc/$i || return 1
+ install -m644 $i "$pkgdir"/$_gcclibdir/$i || return 1
done
# we dont support gcj -static
@@ -246,7 +248,7 @@ package() {
mv "$pkgdir"/usr/lib/*-gdb.py \
"$pkgdir"/usr/share/gdb/python/auto-load/usr/lib/
- paxctl -c -pmrs "$pkgdir"/usr/libexec/gcc/*/*/cc1 || return 1
+ paxctl -c -pmrs "$pkgdir"/$_gcclibexec/cc1 || return 1
}
libcxx() {
@@ -259,14 +261,13 @@ libcxx() {
gpp() {
pkgdesc="GNU C++ standard library and compiler"
depends="libstdc++=$_gccrel gcc=$_gccrel libc-dev"
- local libexec=usr/libexec/gcc/${CHOST:-$_chost}/$pkgver
- mkdir -p "$subpkgdir/$libexec" \
+ mkdir -p "$subpkgdir/$_gcclibexec" \
"$subpkgdir"/usr/bin \
"$subpkgdir"/usr/include \
"$subpkgdir"/usr/lib \
- mv "$pkgdir/$libexec/cc1plus" "$subpkgdir/$libexec/"
- paxctl -c -pmrs "$subpkgdir/$libexec/cc1plus" || return 1
+ mv "$pkgdir/$_gcclibexec/cc1plus" "$subpkgdir/$_gcclibexec/"
+ paxctl -c -pmrs "$subpkgdir/$_gcclibexec/cc1plus" || return 1
mv "$pkgdir"/usr/lib/*++* "$subpkgdir"/usr/lib/
mv "$pkgdir"/usr/include/c++ "$subpkgdir"/usr/include/
@@ -285,11 +286,10 @@ objc() {
pkgdesc="GNU Objective-C"
replaces="gcc"
depends="libc-dev gcc=$_gccrel libobjc=$_gccrel"
- local gcclibdir=usr/lib/gcc/${CHOST:-$_chost}/$pkgver
- mkdir -p "$subpkgdir"/$gcclibdir/include \
+ mkdir -p "$subpkgdir"/$_gcclibdir/include \
"$subpkgdir"/usr/lib \
|| return 1
- mv "$pkgdir"/$gcclibdir/include/objc "$subpkgdir"/$gcclibdir/include/ \
+ mv "$pkgdir"/$_gcclibdir/include/objc "$subpkgdir"/$_gcclibdir/include/ \
|| return 1
mv "$pkgdir"/usr/lib/libobjc.so "$pkgdir"/usr/lib/libobjc.a \
"$subpkgdir"/usr/lib/ || return 1
@@ -313,7 +313,7 @@ libgomp() {
java() {
pkgdesc="Java support for GCC"
depends="zlib-dev gcc=$_gccrel libgcj=$_gccrel"
- paxctl -c -pm "$pkgdir"/usr/libexec/gcc/*/*/ecj1 || return 1
+ paxctl -c -pm "$pkgdir"/$_gcclibexec/ecj1 || return 1
mkdir -p "$subpkgdir"/usr/bin "$subpkgdir"/usr/lib
cd "$pkgdir"/usr/bin
mv gcj gcj-dbtool gjavah gcjh jcf-dump "$subpkgdir"/usr/bin/
@@ -375,13 +375,12 @@ libgo() {
go() {
pkgdesc="Go support for GCC"
depends="gcc=$_gccrel libgo=$_gccrel"
- local libexec=usr/libexec/gcc/${CHOST:-$_chost}/$pkgver
- mkdir -p "$subpkgdir"/$libexec \
+ mkdir -p "$subpkgdir"/$_gcclibexec \
"$subpkgdir"/usr/lib \
"$subpkgdir"/usr/bin || return 1
mv "$pkgdir"/usr/lib/go "$subpkgdir"/usr/lib/ || return 1
mv "$pkgdir"/usr/bin/*gccgo "$subpkgdir"/usr/bin/ || return 1
- mv "$pkgdir"/$libexec/go1 "$subpkgdir"/$libexec/ || return 1
+ mv "$pkgdir"/$_gcclibexec/go1 "$subpkgdir"/$_gcclibexec/ || return 1
mv "$pkgdir"/usr/lib/libgo.a \
"$pkgdir"/usr/lib/libgo.so \
"$pkgdir"/usr/lib/libgobegin.a \
@@ -407,10 +406,8 @@ gfortran() {
pkgdesc="GNU Fortran Compiler"
depends="gcc=$_gccrel libgfortran=$_gccrel libquadmath=$_gccrel"
replaces="gcc"
- local libexec=usr/libexec/gcc/${CHOST:-$_chost}/$pkgver
- local gcclibs=usr/lib/gcc/${CHOST:-$_chost}/$pkgver
- mkdir -p "$subpkgdir"/$libexec \
- "$subpkgdir"/$gcclibs \
+ mkdir -p "$subpkgdir"/$_gcclibexec \
+ "$subpkgdir"/$_gcclibdir \
"$subpkgdir"/usr/lib \
"$subpkgdir"/usr/bin || return 1
mv "$pkgdir"/usr/bin/*gfortran "$subpkgdir"/usr/bin/ || return 1
@@ -419,10 +416,10 @@ gfortran() {
"$pkgdir"/usr/lib/libquadmath.a \
"$pkgdir"/usr/lib/libquadmath.so \
"$subpkgdir"/usr/lib/ || return 1
- mv "$pkgdir"/$libexec/f951 \
- "$subpkgdir"/$libexec
- mv "$pkgdir"/$gcclibs/libgfortranbegin.a \
- "$subpkgdir"/$gcclibs
+ mv "$pkgdir"/$_gcclibexec/f951 \
+ "$subpkgdir"/$_gcclibexec
+ mv "$pkgdir"/$_gcclibdir/libgfortranbegin.a \
+ "$subpkgdir"/$_gcclibdir
}
md5sums="86f428a30379bdee0224e353ee2f999e gcc-4.7.3.tar.bz2