From a21dec9a0db1f85c13782fe4cb0fd4f56165b8cb Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Wed, 10 Aug 2016 22:31:26 +0100 Subject: [PATCH] Add GNU gettext to stage3 chroot. This is required to build the 'iso-codes' RPM. --- .gitignore | 1 + Makefile | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/.gitignore b/.gitignore index 48aae81..0c49a18 100644 --- a/.gitignore +++ b/.gitignore @@ -25,6 +25,7 @@ stamp-* /diffutils-3.4/ /file-5.28/ /findutils-4.6.0/ +/gettext-0.19/ /gmp-6.1.1/ /grep-2.25/ /gzip-1.8/ diff --git a/Makefile b/Makefile index 1388e75..3f9c6dc 100644 --- a/Makefile +++ b/Makefile @@ -74,6 +74,7 @@ FINDUTILS_VERSION = 4.6.0 SED_VERSION = 4.2 PATCH_VERSION = 2.7.5 HOSTNAME_VERSION = 3.15 +GETTEXT_VERSION = 0.19 all: stage1 stage2 stage3 stage4 @@ -299,6 +300,7 @@ stage3: stage3-kernel/linux-$(KERNEL_VERSION)/vmlinux \ stage3-chroot/usr/bin/sed \ stage3-chroot/usr/bin/patch \ stage3-chroot/usr/bin/hostname \ + stage3-chroot/usr/bin/gettext \ stage3-chroot/usr/bin/rpm \ stage3-chroot/init \ stage3-disk.img @@ -851,6 +853,24 @@ hostname-$(HOSTNAME_VERSION).tar.gz: wget -O $@-t http://ftp.de.debian.org/debian/pool/main/h/hostname/hostname_$(HOSTNAME_VERSION).tar.gz mv $@-t $@ +# Cross-compile GNU gettext. +stage3-chroot/usr/bin/gettext: gettext-$(GETTEXT_VERSION).tar.gz + rm -rf gettext-$(GETTEXT_VERSION) + tar -zxf $^ + cd gettext-$(GETTEXT_VERSION) && \ + PATH=$(ROOT)/fixed-gcc:$$PATH \ + ./configure \ + --host=riscv64-unknown-linux-gnu \ + --prefix=/usr --libdir=/usr/lib64 + cd gettext-$(GETTEXT_VERSION) && PATH=$(ROOT)/fixed-gcc:$$PATH make + cd gettext-$(GETTEXT_VERSION) && PATH=$(ROOT)/fixed-gcc:$$PATH make install DESTDIR=$(ROOT)/stage3-chroot + rm -f stage3-chroot/usr/lib64/*.la + +gettext-$(GETTEXT_VERSION).tar.gz: + rm -f $@ $@-t + wget -O $@-t https://ftp.gnu.org/gnu/gettext/gettext-$(GETTEXT_VERSION).tar.gz + mv $@-t $@ + # Cross-compile RPM / rpmbuild. # We build this from a git commit, with a few hacks to the configure # script. -- 1.8.3.1