wok-current annotate gcc63/receipt @ rev 25695
Up linux 5.10.214, Patch xorg-server (CVE-2024-31080, CVE-2024-31081, CVE-2024-31082, CVE-2024-31083)
author | Stanislas Leduc <shann@slitaz.org> |
---|---|
date | Thu Apr 04 08:53:51 2024 +0000 (2 months ago) |
parents | 52649f27a0da |
children |
rev | line source |
---|---|
devl547@19623 | 1 # SliTaz package receipt. |
devl547@19623 | 2 |
devl547@19623 | 3 PACKAGE="gcc63" |
devl547@19623 | 4 SOURCE="gcc" |
devl547@19623 | 5 VERSION="6.3.0" |
devl547@19623 | 6 CATEGORY="development" |
devl547@19623 | 7 SHORT_DESC="The GNU Compiler Collection." |
devl547@19623 | 8 MAINTAINER="pankso@slitaz.org" |
devl547@19623 | 9 LICENSE="GPL2" |
devl547@19623 | 10 TARBALL="$SOURCE-$VERSION.tar.bz2" |
devl547@19623 | 11 WEB_SITE="http://gcc.gnu.org/" |
devl547@19623 | 12 WGET_URL="ftp://gcc.gnu.org/pub/gcc/releases/gcc-$VERSION/$TARBALL" |
devl547@19623 | 13 TAGS="compiler C C++" |
devl547@19623 | 14 |
devl547@19623 | 15 # We need gawk since busybox awk is not sufficient. We have BUILD_DEPENDS |
devl547@19623 | 16 # for cookutils that are not used by tazwok/cook-toolchain since it installs |
devl547@19623 | 17 # and uses its own copy. |
devl547@19623 | 18 DEPENDS="binutils libgomp libobjc gcc-lib-base mpc-library elfutils" |
devl547@19623 | 19 BUILD_DEPENDS="mpc-library mpfr-dev gmp-dev elfutils-dev" |
devl547@19623 | 20 |
pascal@24694 | 21 # What is the latest version available today? |
pascal@24694 | 22 current_version() |
pascal@24694 | 23 { |
pascal@24694 | 24 wget -O - $GNU_MIRROR/$SOURCE 2>/dev/null | \ |
pascal@24694 | 25 sed '/gcc-6\.3/!d;s|.*gcc-||;s|.t.*||;s|/.*||' | sort -Vr | sed q |
pascal@24694 | 26 } |
pascal@24694 | 27 |
devl547@19623 | 28 # Rules to configure and make the package. |
devl547@19623 | 29 compile_rules() |
devl547@19623 | 30 { |
devl547@19623 | 31 ARCH_ARGS="--with-tune=$ARCH" |
devl547@19623 | 32 pkgversion="SliTaz" |
devl547@19623 | 33 languages="c,c++" |
devl547@19623 | 34 |
devl547@19623 | 35 # Use libiberty.a from binutils. |
devl547@19623 | 36 sed -i 's/install_to_$(INSTALL_DEST) //' libiberty/Makefile.in || return 1 |
devl547@19623 | 37 |
devl547@19623 | 38 sed -i 's/^T_CFLAGS =$/& -fomit-frame-pointer/' gcc/Makefile.in |
devl547@19623 | 39 |
shann@25634 | 40 # Patch to build gcc 6.3.0 with gcc >= 8.x |
shann@25634 | 41 patch -p1 < $stuff/fix-build-with-gcc8-1.patch |
shann@25634 | 42 patch -p1 < $stuff/fix-build-with-gcc8-2.patch |
shann@25634 | 43 patch -p1 < $stuff/fix-build-with-gcc8-3.patch |
shann@25634 | 44 |
shann@25634 | 45 # Patch to build with glibc 2.28 |
shann@25634 | 46 patch -p1 < $stuff/fix-build-with-glibc-2.28.patch |
shann@25634 | 47 |
devl547@19623 | 48 mkdir -p ../gcc-build && cd ../gcc-build |
devl547@19623 | 49 |
devl547@19623 | 50 $src/configure \ |
devl547@19623 | 51 --libexecdir=/usr/lib \ |
devl547@19623 | 52 --enable-nls \ |
devl547@19623 | 53 --enable-languages=${languages} \ |
devl547@19623 | 54 --enable-shared \ |
devl547@19623 | 55 --with-system-zlib \ |
devl547@19623 | 56 --enable-clocale=gnu \ |
devl547@19623 | 57 --enable-objc-gc \ |
devl547@19623 | 58 --enable-__cxa_atexit \ |
devl547@19623 | 59 --enable-lto \ |
devl547@19623 | 60 --enable-threads=posix \ |
devl547@19623 | 61 --disable-bootstrap \ |
devl547@19623 | 62 --program-suffix=-63 \ |
devl547@19623 | 63 --libdir=/usr/libgcc63 \ |
devl547@19623 | 64 --with-pkgversion="$pkgversion" \ |
devl547@19623 | 65 ${CONFIGURE_ARGS} ${ARCH_ARGS} && |
devl547@19623 | 66 make && make install |
devl547@19623 | 67 } |
devl547@19623 | 68 |
devl547@19623 | 69 # Rules to gen a SliTaz package suitable for Tazpkg. |
devl547@19623 | 70 genpkg_rules() |
devl547@19623 | 71 { |
devl547@19623 | 72 mkdir -p $fs/usr/share |
devl547@19623 | 73 cp -a $install/usr/bin $fs/usr |
devl547@19623 | 74 |
devl547@19623 | 75 # Copy all libs. Do not hide gcc-lib-base. |
devl547@19623 | 76 cp -a $install/usr/lib* $fs/usr |
devl547@19623 | 77 |
devl547@19623 | 78 # Include files. |
devl547@19623 | 79 cp -a $install/usr/include $fs/usr |
devl547@19623 | 80 |
devl547@19623 | 81 # Remove build directory. |
devl547@19623 | 82 rm -rf $WOK/$PACKAGE/source/$PACKAGE-build |
devl547@19623 | 83 rm -rf $WOK/$PACKAGE/$PACKAGE-build |
devl547@19623 | 84 } |