summaryrefslogtreecommitdiff
path: root/multilib/lib32-glibc
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2011-08-21 23:14:35 +0000
committerroot <root@rshg054.dnsready.net>2011-08-21 23:14:35 +0000
commite9a5c646563c984f362db1777f8c6bc7da63a4ab (patch)
tree709694a1605c0b60dc9c0c57718e7fd661924646 /multilib/lib32-glibc
parent839141249778baa4dba0f0511c52b5eded3cd934 (diff)
Sun Aug 21 23:14:34 UTC 2011
Diffstat (limited to 'multilib/lib32-glibc')
-rw-r--r--multilib/lib32-glibc/PKGBUILD25
1 files changed, 20 insertions, 5 deletions
diff --git a/multilib/lib32-glibc/PKGBUILD b/multilib/lib32-glibc/PKGBUILD
index 276d465cd..c4b759ef9 100644
--- a/multilib/lib32-glibc/PKGBUILD
+++ b/multilib/lib32-glibc/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 50168 2011-06-25 17:22:07Z heftig $
+# $Id: PKGBUILD 54541 2011-08-20 07:14:05Z allan $
# Maintainer: Jan "heftig" Steffens <jan.steffens@gmail.com>
# Contributor: Jan de Groot <jgc@archlinux.org>
# Contributor: Allan McRae <allan@archlinux.org>
@@ -9,14 +9,14 @@
_pkgbasename=glibc
pkgname=lib32-$_pkgbasename
pkgver=2.14
-pkgrel=4
+pkgrel=5
_glibcdate=20110617
pkgdesc="GNU C Library for multilib"
arch=('x86_64')
url="http://www.gnu.org/software/libc"
license=('GPL' 'LGPL')
depends=("glibc>=$pkgver")
-makedepends=('gcc-multilib>=4.4')
+makedepends=('gcc-multilib>=4.6')
options=('!strip' '!emptydirs')
source=(http://mirrors.kernel.org/archlinux/other/glibc/${_pkgbasename}-${pkgver}_${_glibcdate}.tar.xz
glibc-2.10-dont-build-timezone.patch
@@ -88,12 +88,16 @@ build() {
mkdir glibc-build
cd glibc-build
+ export CC="gcc -m32"
+
# Hack to fix NPTL issues with Xen, only required on 32bit platforms
export CFLAGS="${CFLAGS} -mno-tls-direct-seg-refs"
echo "slibdir=/usr/lib32" >> configparms
- export CC="gcc -m32"
+ # remove hardening options from CFLAGS for building libraries
+ CFLAGS=${CFLAGS/-fstack-protector/}
+ CFLAGS=${CFLAGS/-D_FORTIFY_SOURCE=2/}
${srcdir}/glibc/configure --prefix=/usr \
--libdir=/usr/lib32 --libexecdir=/usr/lib32 \
@@ -104,8 +108,19 @@ build() {
--enable-bind-now --without-gd \
--without-cvs --disable-profile \
--disable-multi-arch i686-unknown-linux-gnu
-
+
+ # build libraries with hardening disabled
+ echo "build-programs=no" >> configparms
+ make
+
+ # re-enable hardening for programs
+ sed -i "s#=no#=yes#" configparms
+ echo "CC += -fstack-protector -D_FORTIFY_SOURCE=2" >> configparms
+ echo "CXX += -fstack-protector -D_FORTIFY_SOURCE=2" >> configparms
make
+
+ # remove harding in preparation to run test-suite
+ sed -i '2,4d' configparms
}
check() {