glibc: add -dbg pkgs and cross building support.
This commit is contained in:
parent
fa00c95960
commit
8281de30e7
1 changed files with 30 additions and 13 deletions
|
@ -1,47 +1,64 @@
|
||||||
# Template file for 'glibc'
|
# Template file for 'glibc'
|
||||||
pkgname=glibc
|
pkgname=glibc
|
||||||
_majorver=2.17
|
version=2.17
|
||||||
version=${_majorver}
|
revision=2
|
||||||
revision=1
|
|
||||||
short_desc="The GNU C library"
|
short_desc="The GNU C library"
|
||||||
maintainer="Juan RP <xtraeme@gmail.com>"
|
maintainer="Juan RP <xtraeme@gmail.com>"
|
||||||
homepage="http://www.gnu.org/software/libc"
|
homepage="http://www.gnu.org/software/libc"
|
||||||
license="GPL-2, LGPL-2.1, BSD"
|
license="GPL-2, LGPL-2.1, BSD"
|
||||||
distfiles="http://ftp.gnu.org/gnu/glibc/glibc-${_majorver}.tar.xz"
|
distfiles="http://ftp.gnu.org/gnu/glibc/glibc-${version}.tar.xz"
|
||||||
checksum=6914e337401e0e0ade23694e1b2c52a5f09e4eda3270c67e7c3ba93a89b5b23e
|
checksum=6914e337401e0e0ade23694e1b2c52a5f09e4eda3270c67e7c3ba93a89b5b23e
|
||||||
|
|
||||||
|
# Do not strip these files objcopy errors out.
|
||||||
nostrip_files="
|
nostrip_files="
|
||||||
ld-${_majorver}.so
|
XBS5_ILP32_OFFBIG
|
||||||
libc-${_majorver}.so
|
XBS5_ILP32_OFF32
|
||||||
libpthread-${_majorver}.so
|
POSIX_V6_ILP32_OFF32
|
||||||
libthread_db-1.0.so"
|
POSIX_V6_ILP32_OFFBIG
|
||||||
disable_debug=yes
|
POSIX_V7_ILP32_OFF32
|
||||||
|
POSIX_V7_ILP32_OFFBIG"
|
||||||
|
|
||||||
conf_files="/etc/rpc /etc/ld.so.conf"
|
conf_files="/etc/rpc /etc/ld.so.conf"
|
||||||
subpackages="glibc-devel glibc-locales nscd"
|
subpackages="glibc-devel glibc-locales nscd"
|
||||||
depends="base-files glibc-locales"
|
depends="base-files glibc-locales"
|
||||||
makedepends="bison perl kernel-libc-headers>=3.7<3.8"
|
makedepends="bison perl kernel-libc-headers>=3.7<3.8"
|
||||||
|
|
||||||
|
if [ -n "$XBPS_CROSS_TRIPLET" ]; then
|
||||||
|
makedepends="bison perl"
|
||||||
|
fi
|
||||||
|
|
||||||
do_configure() {
|
do_configure() {
|
||||||
|
local _headers _floatabi
|
||||||
|
|
||||||
mkdir build && cd build
|
mkdir build && cd build
|
||||||
|
|
||||||
echo "slibdir=/usr/lib" > configparms
|
echo "slibdir=/usr/lib" > configparms
|
||||||
echo "bindir=/usr/bin" >> configparms
|
echo "bindir=/usr/bin" >> configparms
|
||||||
echo "sbindir=/usr/sbin" >> configparms
|
echo "sbindir=/usr/sbin" >> configparms
|
||||||
|
|
||||||
# Build with -mno-tls-direct-seg-refs to avoid performance problems
|
|
||||||
# with Xen on x86 32bit.
|
|
||||||
if [ "${XBPS_MACHINE}" = "i686" ]; then
|
if [ "${XBPS_MACHINE}" = "i686" ]; then
|
||||||
|
# Build with -mno-tls-direct-seg-refs to avoid performance
|
||||||
|
# problems with Xen on x86 32bit.
|
||||||
export CFLAGS="${CFLAGS} -mno-tls-direct-seg-refs"
|
export CFLAGS="${CFLAGS} -mno-tls-direct-seg-refs"
|
||||||
|
elif [ "$XBPS_MACHINE" = "armv6l" ]; then
|
||||||
|
# Force hard float ABI.
|
||||||
|
_floatabi="--with-float=hard"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -n "$XBPS_CROSS_TRIPLET" ]; then
|
||||||
|
_headers="--with-headers=/usr/$XBPS_CROSS_TRIPLET/include"
|
||||||
|
else
|
||||||
|
_headers="--with-headers=/usr/include"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
../configure ${CONFIGURE_SHARED_ARGS} \
|
../configure ${CONFIGURE_SHARED_ARGS} \
|
||||||
--bindir=/usr/bin --sbindir=/usr/sbin \
|
--bindir=/usr/bin --sbindir=/usr/sbin \
|
||||||
--enable-add-ons=nptl,libidn --enable-obsolete-rpc \
|
--enable-add-ons=ports,nptl,libidn --enable-obsolete-rpc \
|
||||||
--enable-multi-arch --enable-bind-now \
|
--enable-multi-arch --enable-bind-now \
|
||||||
--disable-profile --enable-kernel=2.6.27 \
|
--disable-profile --enable-kernel=2.6.27 \
|
||||||
--enable-stack-guard-randomization \
|
--enable-stack-guard-randomization \
|
||||||
--without-cvs --without-gd --libexecdir=/usr/lib \
|
--without-cvs --without-gd --libexecdir=/usr/lib \
|
||||||
--libdir=/usr/lib --with-headers=/usr/include
|
--libdir=/usr/lib ${_floatabi} ${_headers}
|
||||||
}
|
}
|
||||||
|
|
||||||
do_build() {
|
do_build() {
|
||||||
|
|
Loading…
Reference in a new issue