From aaf4e43b41cf664857ea9d15ea19a436aa5cef2e Mon Sep 17 00:00:00 2001 From: Juan RP Date: Sat, 15 May 2010 19:42:26 +0200 Subject: [PATCH] gcc-multilib: update to 4.5.0, fully working now. --- srcpkgs/gcc-c++-multilib | 1 + srcpkgs/gcc-multilib/depends | 2 + .../gcc-multilib/gcc-c++-multilib.template | 21 +++++ .../gcc-multilib/gcc-objc++-multilib.template | 17 ++++ .../gcc-multilib/gcc-objc-multilib.template | 22 +++++ srcpkgs/gcc-multilib/libgcc32.template | 12 +++ srcpkgs/gcc-multilib/libgomp32.template | 16 ++++ .../gcc-multilib/libmudflap32-devel.template | 18 ++++ srcpkgs/gcc-multilib/libmudflap32.template | 15 +++ srcpkgs/gcc-multilib/libobjc32.template | 16 ++++ srcpkgs/gcc-multilib/libssp32.template | 15 +++ srcpkgs/gcc-multilib/libstdc++32.template | 16 ++++ srcpkgs/gcc-multilib/template | 91 ++++++++++++++----- srcpkgs/gcc-objc++-multilib | 1 + srcpkgs/gcc-objc-multilib | 1 + srcpkgs/libgcc32 | 1 + srcpkgs/libgomp32 | 1 + srcpkgs/libmudflap32 | 1 + srcpkgs/libmudflap32-devel | 1 + srcpkgs/libobjc32 | 1 + srcpkgs/libssp32 | 1 + srcpkgs/libstdc++32 | 1 + 22 files changed, 248 insertions(+), 23 deletions(-) create mode 120000 srcpkgs/gcc-c++-multilib create mode 100644 srcpkgs/gcc-multilib/depends create mode 100644 srcpkgs/gcc-multilib/gcc-c++-multilib.template create mode 100644 srcpkgs/gcc-multilib/gcc-objc++-multilib.template create mode 100644 srcpkgs/gcc-multilib/gcc-objc-multilib.template create mode 100644 srcpkgs/gcc-multilib/libgcc32.template create mode 100644 srcpkgs/gcc-multilib/libgomp32.template create mode 100644 srcpkgs/gcc-multilib/libmudflap32-devel.template create mode 100644 srcpkgs/gcc-multilib/libmudflap32.template create mode 100644 srcpkgs/gcc-multilib/libobjc32.template create mode 100644 srcpkgs/gcc-multilib/libssp32.template create mode 100644 srcpkgs/gcc-multilib/libstdc++32.template create mode 120000 srcpkgs/gcc-objc++-multilib create mode 120000 srcpkgs/gcc-objc-multilib create mode 120000 srcpkgs/libgcc32 create mode 120000 srcpkgs/libgomp32 create mode 120000 srcpkgs/libmudflap32 create mode 120000 srcpkgs/libmudflap32-devel create mode 120000 srcpkgs/libobjc32 create mode 120000 srcpkgs/libssp32 create mode 120000 srcpkgs/libstdc++32 diff --git a/srcpkgs/gcc-c++-multilib b/srcpkgs/gcc-c++-multilib new file mode 120000 index 0000000000..9f2eca37b1 --- /dev/null +++ b/srcpkgs/gcc-c++-multilib @@ -0,0 +1 @@ +gcc-multilib \ No newline at end of file diff --git a/srcpkgs/gcc-multilib/depends b/srcpkgs/gcc-multilib/depends new file mode 100644 index 0000000000..fa93ce90fb --- /dev/null +++ b/srcpkgs/gcc-multilib/depends @@ -0,0 +1,2 @@ +abi_depends=">=4.5.0" +api_depends="${abi_depends}" diff --git a/srcpkgs/gcc-multilib/gcc-c++-multilib.template b/srcpkgs/gcc-multilib/gcc-c++-multilib.template new file mode 100644 index 0000000000..293ddd2007 --- /dev/null +++ b/srcpkgs/gcc-multilib/gcc-c++-multilib.template @@ -0,0 +1,21 @@ +# Template file for 'gcc-c++-multilib'. +# +short_desc="GCC C++ compiler (multilib files)" +long_desc=" + This is the GNU C++ compiler, a fairly portable optimizing compiler for C++. + + On architectures with multilib support, the package contains files and + dependencies for the non-default multilib architecture(s)." + +Add_dependency run gcc-c++ ">=${version}" +Add_dependency run gcc-multilib ">=${version}" +Add_dependency run libstdc++32 ">=${version}" + +do_install() +{ + local libmddir="/usr/lib/gcc/x86_64-unknown-linux-gnu/${version}" + + mkdir -p ${DESTDIR}/${libmddir}/32 + mv ${SRCPKGDESTDIR}/${libmddir}/32/lib{std,sup}c++.a \ + ${DESTDIR}/${libmddir}/32 +} diff --git a/srcpkgs/gcc-multilib/gcc-objc++-multilib.template b/srcpkgs/gcc-multilib/gcc-objc++-multilib.template new file mode 100644 index 0000000000..4e5ba1cb53 --- /dev/null +++ b/srcpkgs/gcc-multilib/gcc-objc++-multilib.template @@ -0,0 +1,17 @@ +# Template file for 'gcc-objc++-multilib'. +# +short_desc="The GNU Objective-C++ compiler (multilib files)" +long_desc=" + This is the GNU Objective-C++ compiler, which compiles Objective-C on + platforms supported by the GCC compiler. + + On architectures with multilib support, the package contains files and + dependencies for the non-default multilib architecture(s)." + +Add_dependency run gcc-c++-multilib ">=${version}" +Add_dependency run gcc-objc-multilib ">=${version}" + +do_install() +{ + mkdir -p ${DESTDIR}/usr/share/doc/${pkgname} +} diff --git a/srcpkgs/gcc-multilib/gcc-objc-multilib.template b/srcpkgs/gcc-multilib/gcc-objc-multilib.template new file mode 100644 index 0000000000..b1ed37b819 --- /dev/null +++ b/srcpkgs/gcc-multilib/gcc-objc-multilib.template @@ -0,0 +1,22 @@ +# Template file for 'gcc-objc-multilib'. +# +short_desc="The GNU Objective-C compiler (multilib files)" +long_desc=" + This is the GNU Objective-C compiler, which compiles Objective-C on + platforms supported by the GCC compiler. + + On architectures with multilib support, the package contains files and + dependencies for the non-default multilib architecture(s)." + +Add_dependency run gcc ">=${version}" +Add_dependency run gcc-multilib ">=${version}" +Add_dependency run gcc-objc ">=${version}" +Add_dependency run libobjc32 ">=${version}" + +do_install() +{ + local libmddir="/usr/lib/gcc/x86_64-unknown-linux-gnu/${version}" + + mkdir -p ${DESTDIR}/${libmddir}/32 + mv ${SRCPKGDESTDIR}/${libmddir}/32/libobjc*.a ${DESTDIR}/${libmddir}/32 +} diff --git a/srcpkgs/gcc-multilib/libgcc32.template b/srcpkgs/gcc-multilib/libgcc32.template new file mode 100644 index 0000000000..c205829e3f --- /dev/null +++ b/srcpkgs/gcc-multilib/libgcc32.template @@ -0,0 +1,12 @@ +# Template file for 'libgcc32'. +# +short_desc="GCC version ${version} shared library support (32bit)" +long_desc="${long_desc} + + This package contains the 32bit GCC shared library for x86_64 systems." + +do_install() +{ + mkdir -p ${DESTDIR}/usr/lib32 + mv ${SRCPKGDESTDIR}/usr/lib32/libgcc_s.so* ${DESTDIR}/usr/lib32 +} diff --git a/srcpkgs/gcc-multilib/libgomp32.template b/srcpkgs/gcc-multilib/libgomp32.template new file mode 100644 index 0000000000..7bf524dba3 --- /dev/null +++ b/srcpkgs/gcc-multilib/libgomp32.template @@ -0,0 +1,16 @@ +# Template file for 'libgomp32'. +# +short_desc="GCC OpenMP v3.0 shared support library (32bit)" +long_desc="${long_desc} + + This package contains the 32bit GCC shared support library which is needed + for OpenMP v3.0 support." + +Add_dependency run libgcc32 +Add_dependency run glibc32 + +do_install() +{ + mkdir -p ${DESTDIR}/usr/lib32 + mv ${SRCPKGDESTDIR}/usr/lib32/libgomp.* ${DESTDIR}/usr/lib32 +} diff --git a/srcpkgs/gcc-multilib/libmudflap32-devel.template b/srcpkgs/gcc-multilib/libmudflap32-devel.template new file mode 100644 index 0000000000..63be61fdbd --- /dev/null +++ b/srcpkgs/gcc-multilib/libmudflap32-devel.template @@ -0,0 +1,18 @@ +# Template file for 'libmudflap32-devel'. +# +short_desc="GCC 32bit mudflap support libraries (development files)" +long_desc=" + The libmudflap libraries are used by GCC for instrumenting pointer + and array dereferencing operations. + + This package contains the headers and the static libraries." + +Add_dependency run gcc-multilib +Add_dependency run glibc32-devel +Add_dependency run libmudflap32 + +do_install() +{ + mkdir -p ${DESTDIR}/usr/lib32 + mv ${SRCPKGDESTDIR}/usr/lib32/libmudflap*.a ${DESTDIR}/usr/lib32 +} diff --git a/srcpkgs/gcc-multilib/libmudflap32.template b/srcpkgs/gcc-multilib/libmudflap32.template new file mode 100644 index 0000000000..ed41ee3a18 --- /dev/null +++ b/srcpkgs/gcc-multilib/libmudflap32.template @@ -0,0 +1,15 @@ +# Template file for 'libmudflap32'. +# +short_desc="GCC mudflap shared support libraries (32bit)" +long_desc=" + The libmudflap libraries are used by GCC for instrumenting pointer + and array dereferencing operations." + +Add_dependency run gcc-multilib +Add_dependency run glibc32 + +do_install() +{ + mkdir -p ${DESTDIR}/usr/lib32 + mv ${SRCPKGDESTDIR}/usr/lib32/libmudflap*.so* ${DESTDIR}/usr/lib32 +} diff --git a/srcpkgs/gcc-multilib/libobjc32.template b/srcpkgs/gcc-multilib/libobjc32.template new file mode 100644 index 0000000000..114dd9f69c --- /dev/null +++ b/srcpkgs/gcc-multilib/libobjc32.template @@ -0,0 +1,16 @@ +# Template file for 'libobjc32'. +# +short_desc="GCC Objective-C shared library support (32bit)" +long_desc="${long_desc} + + This package contains the 32bit GCC Objective-C shared support library + which is needed to run Objective-C dynamically linked programs." + +Add_dependency run libgcc32 +Add_dependency run glibc32 + +do_install() +{ + mkdir -p ${DESTDIR}/usr/lib32 + mv ${SRCPKGDESTDIR}/usr/lib32/libobjc.so* ${DESTDIR}/usr/lib32 +} diff --git a/srcpkgs/gcc-multilib/libssp32.template b/srcpkgs/gcc-multilib/libssp32.template new file mode 100644 index 0000000000..2ae3af5b49 --- /dev/null +++ b/srcpkgs/gcc-multilib/libssp32.template @@ -0,0 +1,15 @@ +# Template file for 'libssp32'. +# +short_desc="GCC SSP shared library support (32bit)" +long_desc="${long_desc} + + This package contains the 32bit Stack Smashing Protection shared library + provided by GCC." + +Add_dependency run glibc32 + +do_install() +{ + mkdir -p ${DESTDIR}/usr/lib32 + mv ${SRCPKGDESTDIR}/usr/lib32/libssp.so* ${DESTDIR}/usr/lib32 +} diff --git a/srcpkgs/gcc-multilib/libstdc++32.template b/srcpkgs/gcc-multilib/libstdc++32.template new file mode 100644 index 0000000000..da01be247b --- /dev/null +++ b/srcpkgs/gcc-multilib/libstdc++32.template @@ -0,0 +1,16 @@ +# Template file for 'libstdc++32'. +# +short_desc="GCC Standard C++ Library (32bit)" +long_desc="${long_desc} + + This package contains a rewritten standard compliant GCC Standard + C++ library 32bit for x86_64 systems." + +Add_dependency run libgcc32 +Add_dependency run glibc32 + +do_install() +{ + mkdir -p ${DESTDIR}/usr/lib32 + mv ${SRCPKGDESTDIR}/usr/lib32/libstdc++.so* ${DESTDIR}/usr/lib32 +} diff --git a/srcpkgs/gcc-multilib/template b/srcpkgs/gcc-multilib/template index f9b1187dfb..29b1e8eed8 100644 --- a/srcpkgs/gcc-multilib/template +++ b/srcpkgs/gcc-multilib/template @@ -1,39 +1,84 @@ # Template build file for 'gcc-multilib' pkgname=gcc-multilib -version=4.3.2 -wrksrc="gcc-$version" -distfiles="http://ftp.gnu.org/pub/gnu/gcc/gcc-$version/gcc-$version.tar.bz2" +version=4.5.0 +_gmp_ver=5.0.1 +_mpfr_ver=2.4.2 +_mpc_ver=0.8.1 +wrksrc="gcc-${version}" +distfiles=" +http://ftp.gnu.org/pub/gnu/gcc/gcc-${version}/gcc-${version}.tar.bz2 +ftp://ftp.gmplib.org/pub/gmp-${_gmp_ver}/gmp-${_gmp_ver}.tar.bz2 +http://www.mpfr.org/mpfr-current/mpfr-${_mpfr_ver}.tar.bz2 +http://gcc-uk.internet.bs/infrastructure/mpc-${_mpc_ver}.tar.gz" build_style=gnu_configure -configure_args="--enable-clocale=gnu --disable-bootstrap - --enable-threads=posix --enable-__cxa_atexit --enable-multilib - --enable-languages=c,c++ --enable-tls --enable-shared --with-system-zlib - --with-local-prefix=$XBPS_DESTDIR/$pkgname-$version" +build_wrksrc=build +configure_script="../configure" +configure_args="--enable-clocale=gnu --enable-shared --disable-bootstrap +--enable-threads=posix --enable-__cxa_atexit --disable-gold --disable-lto +--enable-languages=c,c++,objc,obj-c++ --disable-nls --with-system-zlib +--enable-multilib" short_desc="The GNU C Compiler suite (multilib libraries)" maintainer="Juan RP " -checksum=bfbf487731ad5dca37efe480a837417de071bd67e685d5c1df6a290707575165 +checksum=" +8293e9efa68a8ec0fdd0dae9c9bd128a8e742566acd9c8fbcfe79d98ed3756c8 +a2a610f01fd3298dc08c87bf30498c2402590e1bcb227fc40b15ee6d280939fb +c7e75a08a8d49d2082e4caee1591a05d11b9d5627514e678f02d66a124bcf2ba +e664603757251fd8a352848276497a4c79b7f8b21fd8aedd5cc0598a38fee3e4" long_desc=" - The GNU C Compiler suite, with support for C, C++, Fortran, ObjC. + The GNU C Compiler suite, with support for C, C++, ObjC and ObjC++. This package installs the 32 bit libraries required to compile 32 bit code on x86_64 systems." -only_for_archs="x86_64" +subpackages="libgcc32 libssp32 libgomp32 libobjc32 libstdc++32 libmudflap32" +subpackages="${subpackages} libmudflap32-devel gcc-c++-multilib" +subpackages="${subpackages} gcc-objc-multilib gcc-objc++-multilib" -Add_dependency full glibc32 +disable_parallel_build=yes +nostrip=yes +noverifyrdeps=yes +only_for_archs=x86_64 + +Add_dependency run gcc +Add_dependency run libgcc32 ">=${version}" +Add_dependency run libgomp32 ">=${version}" +Add_dependency run zlib32 +Add_dependency run glibc32-devel + +Add_dependency build glibc32-devel +Add_dependency build zlib32-devel + +pre_configure() +{ + mkdir -p ${build_wrksrc} + { mv ${XBPS_BUILDDIR}/gmp-${_gmp_ver} ${wrksrc}/gmp; \ + mv ${XBPS_BUILDDIR}/mpfr-${_mpfr_ver} ${wrksrc}/mpfr; \ + mv ${XBPS_BUILDDIR}/mpc-${_mpc_ver} ${wrksrc}/mpc; } || return 1 +} + +pre_install() +{ + mkdir -p ${DESTDIR}/usr/lib + cd ${DESTDIR}/usr && ln -sf lib lib64 && cd ${wrksrc}/${build_wrksrc} +} post_install() { - local DESTDIR=$XBPS_DESTDIR/$pkgname-$version + local libmddir="/usr/lib/gcc/x86_64-unknown-linux-gnu/${version}" - # We are only interested in 32bit libs, remove anything else. - rm -r $DESTDIR/usr/lib64 - rm -r $DESTDIR/usr/libexec - rm -r $DESTDIR/usr/include - rm -r $DESTDIR/usr/bin - rm -r $DESTDIR/usr/share - rm $DESTDIR/usr/lib/libiberty* - rm -r $DESTDIR/usr/lib/gcc/x86_64-unknown-linux-gnu/$version/*include* - rm -r $DESTDIR/usr/lib/gcc/x86_64-unknown-linux-gnu/$version/install-tools - rm $DESTDIR/usr/lib/gcc/x86_64-unknown-linux-gnu/$version/crt* - rm $DESTDIR/usr/lib/gcc/x86_64-unknown-linux-gnu/$version/libgcov* + # We are only interested in 32bit stuff, remove anything else. + rm -rf ${DESTDIR}/usr/{lib64,include,libexec,bin,share} + rm -f ${DESTDIR}/usr/lib/*.{spec,a,so*} + rm -f ${DESTDIR}/usr/lib32/{libiberty*,*.py} + rm -rf ${DESTDIR}/${libmddir}/{include,include-fixed,install-tools,plugin} + rm -f ${DESTDIR}/${libmddir}/*.{a,o} + + # Move around some stuff for multilib. + mv ${DESTDIR}/usr/lib32/lib{std,sup}c++.a ${DESTDIR}/${libmddir}/32 + mv ${DESTDIR}/usr/lib32/lib{gomp,objc*}.a ${DESTDIR}/${libmddir}/32 + mv ${DESTDIR}/usr/lib32/libssp*.a ${DESTDIR}/${libmddir}/32 + + # Install specs file overriding native gcc with no multilib support. + install -m644 ${wrksrc}/build/gcc/specs \ + ${DESTDIR}/${libmddir} } diff --git a/srcpkgs/gcc-objc++-multilib b/srcpkgs/gcc-objc++-multilib new file mode 120000 index 0000000000..9f2eca37b1 --- /dev/null +++ b/srcpkgs/gcc-objc++-multilib @@ -0,0 +1 @@ +gcc-multilib \ No newline at end of file diff --git a/srcpkgs/gcc-objc-multilib b/srcpkgs/gcc-objc-multilib new file mode 120000 index 0000000000..9f2eca37b1 --- /dev/null +++ b/srcpkgs/gcc-objc-multilib @@ -0,0 +1 @@ +gcc-multilib \ No newline at end of file diff --git a/srcpkgs/libgcc32 b/srcpkgs/libgcc32 new file mode 120000 index 0000000000..9f2eca37b1 --- /dev/null +++ b/srcpkgs/libgcc32 @@ -0,0 +1 @@ +gcc-multilib \ No newline at end of file diff --git a/srcpkgs/libgomp32 b/srcpkgs/libgomp32 new file mode 120000 index 0000000000..9f2eca37b1 --- /dev/null +++ b/srcpkgs/libgomp32 @@ -0,0 +1 @@ +gcc-multilib \ No newline at end of file diff --git a/srcpkgs/libmudflap32 b/srcpkgs/libmudflap32 new file mode 120000 index 0000000000..9f2eca37b1 --- /dev/null +++ b/srcpkgs/libmudflap32 @@ -0,0 +1 @@ +gcc-multilib \ No newline at end of file diff --git a/srcpkgs/libmudflap32-devel b/srcpkgs/libmudflap32-devel new file mode 120000 index 0000000000..9f2eca37b1 --- /dev/null +++ b/srcpkgs/libmudflap32-devel @@ -0,0 +1 @@ +gcc-multilib \ No newline at end of file diff --git a/srcpkgs/libobjc32 b/srcpkgs/libobjc32 new file mode 120000 index 0000000000..9f2eca37b1 --- /dev/null +++ b/srcpkgs/libobjc32 @@ -0,0 +1 @@ +gcc-multilib \ No newline at end of file diff --git a/srcpkgs/libssp32 b/srcpkgs/libssp32 new file mode 120000 index 0000000000..9f2eca37b1 --- /dev/null +++ b/srcpkgs/libssp32 @@ -0,0 +1 @@ +gcc-multilib \ No newline at end of file diff --git a/srcpkgs/libstdc++32 b/srcpkgs/libstdc++32 new file mode 120000 index 0000000000..9f2eca37b1 --- /dev/null +++ b/srcpkgs/libstdc++32 @@ -0,0 +1 @@ +gcc-multilib \ No newline at end of file