summaryrefslogtreecommitdiffstats
path: root/source/d/gcc
diff options
context:
space:
mode:
Diffstat (limited to 'source/d/gcc')
-rwxr-xr-xsource/d/gcc/fetch-from-svn-and-prep-tarball.sh83
-rw-r--r--source/d/gcc/gcc-no_fixincludes.diff10
-rwxr-xr-xsource/d/gcc/gcc.SlackBuild28
-rw-r--r--source/d/gcc/slack-desc.gcc2
-rw-r--r--source/d/gcc/slack-desc.gcc-g++2
-rw-r--r--source/d/gcc/slack-desc.gcc-gfortran2
-rw-r--r--source/d/gcc/slack-desc.gcc-gnat2
-rw-r--r--source/d/gcc/slack-desc.gcc-objc2
8 files changed, 111 insertions, 20 deletions
diff --git a/source/d/gcc/fetch-from-svn-and-prep-tarball.sh b/source/d/gcc/fetch-from-svn-and-prep-tarball.sh
new file mode 100755
index 000000000..b38c2fc0c
--- /dev/null
+++ b/source/d/gcc/fetch-from-svn-and-prep-tarball.sh
@@ -0,0 +1,83 @@
+#!/bin/sh
+# Copyright 2018 Patrick J. Volkerding, Sebeka, Minnesota, USA
+#
+# Parts of this script are based on the gcc_release script by
+# Jeffrey Law, Bernd Schmidt, Mark Mitchell.
+# Copyright (c) 2001-2015 Free Software Foundation.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+BRANCH=${BRANCH:-gcc-8-branch}
+
+rm -rf tmp-fetch
+mkdir tmp-fetch
+cd tmp-fetch
+# Not sure why, but this emits a different revision when the fetch is done than
+# what's returned by "svn log -r COMMITTED". We'll trust the latter.
+svn co svn://gcc.gnu.org/svn/gcc/branches/${BRANCH} gcc
+cd gcc
+echo "Generating LAST_UPDATED..."
+svn log -r COMMITTED > LAST_UPDATED.raw
+REVISION="$(cat LAST_UPDATED.raw | head -n 2 | tail -n 1 | cut -f 1 -d ' ' | cut -f 2 -d r)"
+DATE="$(date -d "$(cat LAST_UPDATED.raw | head -n 2 | tail -n 1 | cut -f 3 -d '|' | cut -f 1 -d '(')" "+%Y%m%d")"
+echo "Obtained from SVN: branches/${BRANCH} revision ${REVISION}" > LAST_UPDATED
+cat LAST_UPDATED.raw >> LAST_UPDATED
+rm LAST_UPDATED.raw
+# Remove the .svn data (not packaged):
+rm -r .svn
+# Get the version number:
+VERSION=$(cat gcc/BASE-VER)
+# Rename the directory:
+cd ..
+GCCDIR="gcc-${VERSION}_${DATE}_r${REVISION}"
+mv gcc $GCCDIR
+cd $GCCDIR
+# Now we need to generate some documentation files that would normally be
+# created during the GCC release process:
+echo "Generating INSTALL/ documentation..."
+SOURCEDIR=gcc/doc \
+DESTDIR=INSTALL \
+gcc/doc/install.texi2html 1> /dev/null 2> /dev/null
+echo "Generating NEWS..."
+contrib/gennews > NEWS
+# Create a "MD5SUMS" file to use for checking the validity of the release.
+echo "Generating MD5SUMS..."
+echo \
+"# This file contains the MD5 checksums of the files in the
+# "${GCCDIR}".tar.lz tarball.
+#
+# Besides verifying that all files in the tarball were correctly expanded,
+# it also can be used to determine if any files have changed since the
+# tarball was expanded or to verify that a patchfile was correctly applied.
+#
+# Suggested usage:
+# md5sum -c MD5SUMS | grep -v \"OK$\"
+#" > MD5SUMS
+find . -type f |
+sed -e 's:^\./::' -e '/MD5SUMS/d' |
+sort |
+xargs md5sum >>MD5SUMS
+cd ..
+# Tar it up:
+echo "Creating ${GCCDIR}.tar..."
+tar cf ${GCCDIR}.tar ${GCCDIR}
+# Compress with (p)lzip:
+echo "Compressing ${GCCDIR}.tar.lz..."
+plzip -9 ${GCCDIR}.tar
+# Move the new archive up a directory:
+mv ${GCCDIR}.tar.lz ..
+# Move up a directory and then delete the cruft:
+cd ..
+rm -r tmp-fetch
+echo "Done."
diff --git a/source/d/gcc/gcc-no_fixincludes.diff b/source/d/gcc/gcc-no_fixincludes.diff
index 52b661613..e152e0821 100644
--- a/source/d/gcc/gcc-no_fixincludes.diff
+++ b/source/d/gcc/gcc-no_fixincludes.diff
@@ -1,6 +1,6 @@
---- ./gcc/Makefile.in.orig 2010-04-02 02:49:06.000000000 -0500
-+++ ./gcc/Makefile.in 2010-08-01 16:55:30.088318841 -0500
-@@ -3864,9 +3864,9 @@
+--- ./gcc/Makefile.in.orig 2018-03-09 09:24:44.000000000 -0600
++++ ./gcc/Makefile.in 2018-05-02 12:25:43.958002771 -0500
+@@ -3004,9 +3004,9 @@
chmod a+r $${fix_dir}/limits.h; \
done
# Install the README
@@ -13,14 +13,14 @@
$(STAMP) $@
.PHONY: install-gcc-tooldir
-@@ -3947,10 +3947,7 @@
+@@ -3087,10 +3087,7 @@
(TARGET_MACHINE='$(target)'; srcdir=`cd $(srcdir); ${PWD_COMMAND}`; \
SHELL='$(SHELL)'; MACRO_LIST=`${PWD_COMMAND}`/macro_list ; \
gcc_dir=`${PWD_COMMAND}` ; \
- export TARGET_MACHINE srcdir SHELL MACRO_LIST && \
- cd $(build_objdir)/fixincludes && \
- $(SHELL) ./fixinc.sh "$${gcc_dir}/$${fix_dir}" \
-- $(SYSTEM_HEADER_DIR) $(OTHER_FIXINCLUDES_DIRS) ); \
+- $(BUILD_SYSTEM_HEADER_DIR) $(OTHER_FIXINCLUDES_DIRS) ); \
+ export TARGET_MACHINE srcdir SHELL MACRO_LIST ); \
rm -f $${fix_dir}/syslimits.h; \
if [ -f $${fix_dir}/limits.h ]; then \
diff --git a/source/d/gcc/gcc.SlackBuild b/source/d/gcc/gcc.SlackBuild
index f16f923cd..2981291e2 100755
--- a/source/d/gcc/gcc.SlackBuild
+++ b/source/d/gcc/gcc.SlackBuild
@@ -55,8 +55,9 @@
cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=gcc
-VERSION=${VERSION:-$(echo $PKGNAM-*.tar.xz | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
-BUILD=${BUILD:-3}
+SRCVER=${VERSION:-$(echo $PKGNAM-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
+VERSION=$(echo $SRCVER | cut -f 1 -d _)
+BUILD=${BUILD:-1}
# How many jobs to run in parallel:
NUMJOBS=" -j 7 "
@@ -128,6 +129,11 @@ esac
# Temporary build location:
TMP=${TMP:-/tmp}
+# Extract the source code:
+cd $TMP
+rm -rf gcc-$SRCVER
+tar xvf $CWD/gcc-$SRCVER.tar.?z || exit 1
+
# This is the main DESTDIR target:
PKG1=$TMP/package-gcc
# These are the directories to build other packages in:
@@ -155,11 +161,7 @@ cat $CWD/slack-desc.gcc-objc > $PKG6/install/slack-desc
cat $CWD/slack-desc.gcc-go > $PKG8/install/slack-desc
cat $CWD/slack-desc.gcc-brig > $PKG9/install/slack-desc
-cd $TMP
-rm -rf gcc-$VERSION
-tar xvf $CWD/gcc-$VERSION.tar.xz || exit 1
-
-( cd gcc-$VERSION || exit 1
+( cd gcc-$SRCVER || exit 1
# Smite the fixincludes:
zcat $CWD/gcc-no_fixincludes.diff.gz | patch -p1 --verbose --backup --suffix=.orig || exit 1
@@ -187,7 +189,7 @@ tar xvf $CWD/gcc-$VERSION.tar.xz || exit 1
fi
if [ -r NEWS ]; then
DOCSDIR=$(echo $PKG1/usr/doc/gcc-$VERSION)
- cat NEWS | head -n 1000 > $DOCSDIR/NEWS
+ cat NEWS | head -n 1500 > $DOCSDIR/NEWS
touch -r NEWS $DOCSDIR/NEWS
fi
@@ -317,7 +319,7 @@ tar xvf $CWD/gcc-$VERSION.tar.xz || exit 1
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
- ../gcc-$VERSION/configure --prefix=/usr \
+ ../gcc-$SRCVER/configure --prefix=/usr \
--libdir=/usr/lib$LIBDIRSUFFIX \
--mandir=/usr/man \
--infodir=/usr/info \
@@ -330,11 +332,15 @@ tar xvf $CWD/gcc-$VERSION.tar.xz || exit 1
--with-system-zlib \
--enable-libstdcxx-dual-abi \
--with-default-libstdcxx-abi=new \
+ --disable-libstdcxx-pch \
--disable-libunwind-exceptions \
--enable-__cxa_atexit \
- --enable-libssp \
+ --disable-libssp \
+ --enable-gnu-unique-object \
+ --enable-plugin \
--enable-lto \
--disable-install-libiberty \
+ --disable-werror \
--with-gnu-ld \
--verbose \
--with-arch-directory=$LIB_ARCH \
@@ -570,6 +576,8 @@ rm -f $PKG1/{,usr/}lib${LIBDIRSUFFIX}/*.la
mv $PKG1/usr/lib${LIBDIRSUFFIX}/libhsail* usr/lib${LIBDIRSUFFIX}
mkdir -p usr/libexec/gcc/$TARGET/$VERSION
mv $PKG1/usr/libexec/gcc/$TARGET/$VERSION/brig1 usr/libexec/gcc/$TARGET/$VERSION
+ mkdir -p usr/man/man1
+ mv $PKG1/usr/man/man1/gccbrig.1.gz usr/man/man1
)
# Generate packages:
diff --git a/source/d/gcc/slack-desc.gcc b/source/d/gcc/slack-desc.gcc
index 1c00df83a..ebe1b8422 100644
--- a/source/d/gcc/slack-desc.gcc
+++ b/source/d/gcc/slack-desc.gcc
@@ -12,7 +12,7 @@ gcc: GCC is the GNU Compiler Collection.
gcc:
gcc: This package contains those parts of the compiler collection needed to
gcc: compile C code. Other packages add Ada, C++, Fortran, Go,
-gcc: Objective-C, and Java support to the compiler core.
+gcc: Objective-C, and BRIG support to the compiler core.
gcc:
gcc:
gcc:
diff --git a/source/d/gcc/slack-desc.gcc-g++ b/source/d/gcc/slack-desc.gcc-g++
index fa9b4f1ca..6beaf21b1 100644
--- a/source/d/gcc/slack-desc.gcc-g++
+++ b/source/d/gcc/slack-desc.gcc-g++
@@ -11,7 +11,7 @@ gcc-g++:
gcc-g++: C++ support for the GNU Compiler Collection.
gcc-g++:
gcc-g++: This package contains those parts of the compiler collection needed to
-gcc-g++: compile C++ code. The base gcc package is also required.
+gcc-g++: compile C++ code.
gcc-g++:
gcc-g++:
gcc-g++:
diff --git a/source/d/gcc/slack-desc.gcc-gfortran b/source/d/gcc/slack-desc.gcc-gfortran
index 111dcb1f7..6d08f0125 100644
--- a/source/d/gcc/slack-desc.gcc-gfortran
+++ b/source/d/gcc/slack-desc.gcc-gfortran
@@ -15,5 +15,5 @@ gcc-gfortran: GNU Fortran also contains many standard and extensions and can be
gcc-gfortran: used to run real-world programs.
gcc-gfortran:
gcc-gfortran: This package contains those parts of the compiler collection
-gcc-gfortran: needed to compile Fortran code. The gcc package is also required.
+gcc-gfortran: needed to compile Fortran code.
gcc-gfortran:
diff --git a/source/d/gcc/slack-desc.gcc-gnat b/source/d/gcc/slack-desc.gcc-gnat
index 8ffa7ac04..9c1eb7714 100644
--- a/source/d/gcc/slack-desc.gcc-gnat
+++ b/source/d/gcc/slack-desc.gcc-gnat
@@ -13,7 +13,7 @@ gcc-gnat:
gcc-gnat: This package contains those parts of the compiler collection needed to
gcc-gnat: compile Ada code. GNAT implements Ada 95, Ada 2005 and Ada 2012, and
gcc-gnat: it may also be invoked in Ada 83 compatibility mode. By default, GNAT
-gcc-gnat: assumes Ada 2012. The base gcc package is also required.
+gcc-gnat: assumes Ada 2012.
gcc-gnat:
gcc-gnat:
gcc-gnat:
diff --git a/source/d/gcc/slack-desc.gcc-objc b/source/d/gcc/slack-desc.gcc-objc
index 174418434..6cf5a3170 100644
--- a/source/d/gcc/slack-desc.gcc-objc
+++ b/source/d/gcc/slack-desc.gcc-objc
@@ -15,5 +15,5 @@ gcc-objc: compile code written in Objective-C. Objective-C was originally
gcc-objc: developed to add object-oriented extensions to the C language, and is
gcc-objc: best known as the native language of the NeXT computer.
gcc-objc:
-gcc-objc: The base gcc package is also required.
+gcc-objc:
gcc-objc: