milis/talimatname/temel/glibc/talimat

107 lines
2.0 KiB
Plaintext
Raw Normal View History

2017-10-27 21:56:50 +02:00
# Tanım: The Glibc package contains the main C library.
2016-02-24 01:27:23 +01:00
# URL: https://www.gnu.org/software/libc/
2017-10-27 21:56:50 +02:00
# Paketçi: milisarge
# Gerekler:
2017-10-28 14:15:02 +02:00
kernelsurum=4.4
isim=glibc
surum=2.23
devir=1
kaynak=(http://www.kernel.org/pub/linux/kernel/v4.x/linux-$kernelversion.tar.xz
http://www.linuxfromscratch.org/patches/downloads/$isim/glibc-$surum-fhs-1.patch
http://ftp.gnu.org/gnu/glibc/glibc-$surum.tar.xz glibc.locales.supported )
2017-10-27 21:56:50 +02:00
2017-10-27 23:59:41 +02:00
derle() {
2016-02-24 01:27:23 +01:00
# Headers
cd linux-$kernelversion
make mrproper
make headers_check
make INSTALL_HDR_PATH=dest headers_install
find dest/include \( -name .install -o -name ..install.cmd \) -delete
mkdir -p $PKG/usr/include
cp -rv dest/include/* $PKG/usr/include
2017-10-28 14:15:02 +02:00
cd ../glibc-$surum
2016-02-24 01:27:23 +01:00
2017-10-28 14:15:02 +02:00
patch -Np1 -i ../glibc-$surum-fhs-1.patch
2016-02-24 01:27:23 +01:00
mkdir -v ../glibc-build
cd ../glibc-build
2017-10-28 14:15:02 +02:00
../glibc-$surum/configure --prefix=/usr \
2016-02-24 01:27:23 +01:00
--disable-profile \
--enable-kernel=2.6.32 \
--enable-obsolete-rpc
make || make -j1
# make -k check 2>&1 | tee glibc-check-log
# grep Error glibc-check-log
make install_root=$PKG install
rm -rf $PKG/usr/share/info/dir
mkdir -p $PKG/etc
2017-10-28 14:15:02 +02:00
cp -v ../glibc-$surum/nscd/nscd.conf $PKG/etc/nscd.conf
2016-02-24 01:27:23 +01:00
mkdir -pv $PKG/var/cache/nscd
touch $PKG/etc/ld.so.conf
mkdir -pv $PKG/usr/lib/locale
cp $SRC/glibc.locales.supported \
2017-10-28 14:15:02 +02:00
../glibc-$surum/localedata/SUPPORTED
2016-02-24 01:27:23 +01:00
make install_root=$PKG localedata/install-locales
cat > $PKG/etc/nsswitch.conf << "EOF"
# Begin /etc/nsswitch.conf
passwd: files
group: files
shadow: files
hosts: files dns
networks: files
protocols: files
services: files
ethers: files
rpc: files
# End /etc/nsswitch.conf
EOF
cat > $PKG/etc/ld.so.conf << "EOF"
# Begin /etc/ld.so.conf
/lib
/lib64
/usr/lib
/usr/lib64
/usr/local/lib
/usr/local/lib64
# Add an include directory
include /etc/ld.so.conf.d/*.conf
# End of /etc/ld.so.conf
EOF
if [ "`uname -m`" == "i686" ];then
cat > $PKG/etc/ld.so.conf << "EOF"
# Begin /etc/ld.so.conf
/lib
/usr/lib
/usr/local/lib
# Add an include directory
include /etc/ld.so.conf.d/*.conf
# End of /etc/ld.so.conf
EOF
fi
mkdir $PKG/etc/ld.so.conf.d
}