summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO31
-rw-r--r--PKGBUILD166
-rw-r--r--gcc.texi.49.patch44
3 files changed, 241 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..ffd8e093dbdf
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,31 @@
+# Generated by mksrcinfo v8
+# Sun Jul 30 19:15:37 UTC 2017
+pkgbase = gcc47-multilib
+ pkgdesc = The GNU Compiler Collection for multilib (4.7.x)
+ pkgver = 4.7.4
+ pkgrel = 1
+ url = http://gcc.gnu.org
+ arch = x86_64
+ license = GPL
+ license = LGPL
+ license = FDL
+ license = custom
+ checkdepends = dejagnu
+ makedepends = flex
+ makedepends = bison
+ makedepends = setconf
+ depends = glibc>=2.17
+ depends = binutils>=2.23
+ depends = libmpc
+ depends = cloog
+ depends = ppl
+ options = staticlibs
+ options = !libtool
+ options = !emptydirs
+ source = ftp://gcc.gnu.org/pub/gcc/releases/gcc-4.7.4/gcc-4.7.4.tar.bz2
+ source = gcc.texi.49.patch
+ sha256sums = 92e61c6dc3a0a449e62d72a38185fda550168a86702dea07125ebd3ec3996282
+ sha256sums = 93b8865cb61f455df807de90f852dc488753d4309d7a1d8f7e7f1a4efe37ffa4
+
+pkgname = gcc47-multilib
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..7940375ee437
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,166 @@
+# Maintainer: Chris Severance aur.severach aATt spamgourmet dott com
+# Contributor: Allan McRae <allan@archlinux.org>
+# Contributor: mosra <mosra@centrum.cz>
+
+# toolchain build order: linux-api-headers->glibc->binutils->gcc->binutils->glibc
+# NOTE: libtool requires rebuilt with each new gcc version
+
+set -u
+_pkgver='4.7'
+pkgname="gcc${_pkgver//\./}-multilib"
+pkgver="${_pkgver}.4"
+pkgrel='1'
+pkgdesc="The GNU Compiler Collection for multilib (${_pkgver}.x)"
+arch=('x86_64')
+url='http://gcc.gnu.org'
+license=('GPL' 'LGPL' 'FDL' 'custom')
+#groups=('base-devel')
+depends=('glibc>=2.17' 'binutils>=2.23' 'libmpc' 'cloog' 'ppl')
+makedepends=('flex' 'bison' 'setconf')
+#makedepends+=('gcc49')
+checkdepends=('dejagnu')
+options=('staticlibs' '!libtool' '!emptydirs')
+source=(
+ "ftp://gcc.gnu.org/pub/gcc/releases/gcc-${pkgver}/gcc-${pkgver}.tar.bz2"
+ #ftp://gcc.gnu.org/pub/gcc/snapshots/${_snapshot}/gcc-${_snapshot}.tar.bz2
+ 'gcc.texi.49.patch'
+)
+sha256sums=('92e61c6dc3a0a449e62d72a38185fda550168a86702dea07125ebd3ec3996282'
+ '93b8865cb61f455df807de90f852dc488753d4309d7a1d8f7e7f1a4efe37ffa4')
+PKGEXT='.pkg.tar.gz'
+
+#if [ -n "${_snapshot}" ]; then
+# _basedir="gcc-${_snapshot}"
+#else
+ _basedir="gcc-${pkgver}"
+#fi
+
+prepare() {
+ set -u
+ cd "${_basedir}"
+
+ # Do not install libiberty
+ sed -e 's/install_to_$(INSTALL_DEST) //' -i 'libiberty/Makefile.in'
+
+ # Do not run fixincludes
+ sed -e 's@\./fixinc\.sh@-c true@' -i 'gcc/Makefile.in'
+
+ # Update gcc.texi to gcc49 version, needed as of texinfo>=6.3 and possibly texinfo=6.2
+ patch -p0 -c < "${srcdir}/gcc.texi.49.patch"
+
+ # Arch Linux installs x86_64 libraries /lib
+ case "${CARCH}" in
+ 'x86_64') sed -e '/m64=/ s/lib64/lib/' -i 'gcc/config/i386/t-linux64' ;;
+ esac
+
+ echo "${pkgver}" > 'gcc/BASE-VER'
+
+ rm -rf 'gcc-build'
+ mkdir 'gcc-build'
+
+ set +u
+}
+
+build() {
+ set -u
+ cd "${_basedir}/gcc-build"
+
+ if [ ! -s 'Makefile' ]; then
+ # Doesn't like FORTIFY_SOURCE
+ CPPFLAGS="${CPPFLAGS//-D_FORTIFY_SOURCE=?/}"
+
+ # Doesn't like -fstack-protector-strong
+ CFLAGS="${CFLAGS//-fstack-protector-strong/-fstack-protector}"
+ CXXFLAGS="${CXXFLAGS//-fstack-protector-strong/-fstack-protector}"
+
+ # using -pipe causes spurious test-suite failures
+ # http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48565
+ CFLAGS="${CFLAGS/-pipe/}"
+ CXXFLAGS="${CXXFLAGS/-pipe/}"
+
+ # Flags from new compilers that old compilers don't recognize
+ CFLAGS="${CFLAGS/-fno-plt/}"
+ CXXFLAGS="${CXXFLAGS/-fno-plt/}"
+
+ CFLAGS="${CFLAGS/-Wformat-overflow=[0-9]/}"
+ CXXFLAGS="${CXXFLAGS/-Wformat-overflow=[0-9]/}"
+
+ # The following options are one per line, mostly sorted so they are easy to diff compare to other gcc packages.
+ ../configure \
+ --build="${CHOST}" \
+ --disable-build-poststage1-with-cxx \
+ --disable-build-with-cxx \
+ --disable-cloog-version-check \
+ --disable-libssp \
+ --disable-libstdcxx-pch \
+ --disable-libunwind-exceptions \
+ --enable-multilib \
+ --disable-ppl-version-check \
+ --enable-__cxa_atexit \
+ --enable-checking='release' \
+ --enable-clocale='gnu' \
+ --enable-cloog-backend='isl' \
+ --enable-gnu-unique-object \
+ --enable-gold \
+ --enable-languages='c,c++,fortran' \
+ --enable-ld='default' \
+ --enable-libstdcxx-time \
+ --enable-linker-build-id \
+ --enable-lto \
+ --enable-plugin \
+ --enable-shared \
+ --enable-threads='posix' \
+ --enable-version-specific-runtime-libs \
+ --infodir='/usr/share/info' \
+ --libdir='/usr/lib' \
+ --libexecdir='/usr/lib' \
+ --mandir='/usr/share/man' \
+ --program-suffix="-${_pkgver}" \
+ --with-bugurl='https://bugs.archlinux.org/' \
+ --with-linker-hash-style='gnu' \
+ --with-plugin-ld='ld.gold' \
+ --with-ppl \
+ --with-system-zlib \
+ --prefix='/usr'
+# CXX='g++-4.9' CC='gcc-4.9'
+ fi
+
+ local _nproc="$(nproc)"; _nproc=$((_nproc>8?8:_nproc))
+ LD_PRELOAD='/usr/lib/libstdc++.so' \
+ nice make -j "${_nproc}"
+
+ set +u
+}
+
+_fn_check() {
+ set -u
+ cd "${_basedir}/gcc-build"
+
+ # increase stack size to prevent test failures
+ # http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31827
+ ulimit -s 32768
+
+ # do not abort on error as some are "expected"
+ make -k check || :
+ "${srcdir}/${_basedir}/contrib/test_summary"
+ set +u
+}
+
+package() {
+ set -u
+ cd "${_basedir}/gcc-build"
+
+ make -j1 DESTDIR="${pkgdir}" install
+
+ ## Lazy way of dealing with conflicting man and info pages and locales...
+ rm -rf "${pkgdir}/usr/share/"
+
+ # Move potentially conflicting stuff to version specific subdirectory
+ mv "${pkgdir}/usr/lib/gcc/${CHOST}"/lib* "${pkgdir}/usr/lib/gcc/${CHOST}/${pkgver}/" || true
+
+ # Install Runtime Library Exception
+ install -Dpm644 '../COPYING.RUNTIME' \
+ "${pkgdir}/usr/share/licenses/${pkgname}/RUNTIME.LIBRARY.EXCEPTION" || :
+ set +u
+}
+set +u
diff --git a/gcc.texi.49.patch b/gcc.texi.49.patch
new file mode 100644
index 000000000000..056853ddb101
--- /dev/null
+++ b/gcc.texi.49.patch
@@ -0,0 +1,44 @@
+*** gcc/doc/gcc.texi Tue Jun 23 03:35:08 2015
+--- gcc/doc/gcc.texi.49 Fri Jun 26 13:47:23 2015
+***************
+*** 83,93 ****
+ Published by:
+ @multitable @columnfractions 0.5 0.5
+ @item GNU Press
+! @tab Website: www.gnupress.org
+ @item a division of the
+! @tab General: @tex press@@gnu.org @end tex
+ @item Free Software Foundation
+! @tab Orders: @tex sales@@gnu.org @end tex
+ @item 51 Franklin Street, Fifth Floor
+ @tab Tel 617-542-5942
+ @item Boston, MA 02110-1301 USA
+--- 83,93 ----
+ Published by:
+ @multitable @columnfractions 0.5 0.5
+ @item GNU Press
+! @tab Website: @uref{http://www.gnupress.org}
+ @item a division of the
+! @tab General: @email{press@@gnu.org}
+ @item Free Software Foundation
+! @tab Orders: @email{sales@@gnu.org}
+ @item 51 Franklin Street, Fifth Floor
+ @tab Tel 617-542-5942
+ @item Boston, MA 02110-1301 USA
+***************
+*** 140,146 ****
+ * Gcov:: @command{gcov}---a test coverage program.
+ * Trouble:: If you have trouble using GCC.
+ * Bugs:: How, why and where to report bugs.
+! * Service:: How to find suppliers of support for GCC.
+ * Contributing:: How to contribute to testing and developing GCC.
+
+ * Funding:: How to help assure funding for free software.
+--- 140,146 ----
+ * Gcov:: @command{gcov}---a test coverage program.
+ * Trouble:: If you have trouble using GCC.
+ * Bugs:: How, why and where to report bugs.
+! * Service:: How To Get Help with GCC
+ * Contributing:: How to contribute to testing and developing GCC.
+
+ * Funding:: How to help assure funding for free software.