On Thu, 2012-12-27 at 19:18 -0700, Al Stone wrote:
For those following along at home...
The nss-utils and nss-softokn packages now build properly for stage2.
They needed to have 64-bit builds enabled and nss-softokn has an
infinite loop that is fortunately only used in code needed for FIPS140
certification -- we can safely ignore this, for now at least.
In progress now are the nss and elfutils packages. Mark Slater is
working on elfutils.
And elfutils built with no changes but there were a few problems along
the way. stage2/local.conf has a problem which caused a build failure.
I ended up with this patch which comments out the distcc stuff I'm not
using and the problematic J=1 (should be J=-j1):
diff --git a/stage2/local.conf b/stage2/local.conf
index 6ab4645..2e848c7 100644
--- a/stage2/local.conf
+++ b/stage2/local.conf
@@ -1,11 +1,11 @@
-J=1
-DISTCC_HOSTS=localhost
-DISTCC_BACKOFF_PERIOD=0
-PATH=/stage2/distcc-bin:$PATH
+# J=1
+# DISTCC_HOSTS=localhost
+# DISTCC_BACKOFF_PERIOD=0
+# PATH=/stage2/distcc-bin:$PATH
PATH=/stage2/ccache-bin:$PATH
TARGET=aarch64-redhat-linux-gnu
RPMTARGET=aarch64-redhat-linux-gnu
TCONFIGARGS="--prefix=/usr --libdir=/usr/lib64 --enable-werror=no --enable-cxx
--enable-languages=c,c++ --enable-threads=posix "
SUFFIX=64
-export J DISTCC_HOSTS DISTCC_BACKOFF_PERIOD PATH
-export TARGET RPMTARGET TCONFIGARGS SUFFIX
+# export J DISTCC_HOSTS DISTCC_BACKOFF_PERIOD
+export PATH TARGET RPMTARGET TCONFIGARGS SUFFIX
Also, there was a link error with my first attempt to build elfutils. A
failing configure test showed this problem:
--- test.c ---
char lzma_auto_decoder ();
int main()
{
return lzma_auto_decoder ();
}
---
# gcc test.c -llzma
/usr/lib64/gcc/aarch64-redhat-linux-gnu/4.7.2/../../../../aarch64-redhat-linux-gnu/bin/ld:
warning: librt.so.1, needed by
/usr/lib64/gcc/aarch64-redhat-linux-gnu/4.7.2/../../../liblzma.so, not found (try using
-rpath or -rpath-link)
/usr/lib64/gcc/aarch64-redhat-linux-gnu/4.7.2/../../../../aarch64-redhat-linux-gnu/bin/ld:
warning: libpthread.so.0, needed by
/usr/lib64/gcc/aarch64-redhat-linux-gnu/4.7.2/../../../liblzma.so, not found (try using
-rpath or -rpath-link)
/usr/lib64/gcc/aarch64-redhat-linux-gnu/4.7.2/../../../liblzma.so: undefined reference to
`pthread_join(a)GLIBC_2.16'
/usr/lib64/gcc/aarch64-redhat-linux-gnu/4.7.2/../../../liblzma.so: undefined reference to
`pthread_condattr_setclock(a)GLIBC_2.16'
/usr/lib64/gcc/aarch64-redhat-linux-gnu/4.7.2/../../../liblzma.so: undefined reference to
`clock_gettime(a)GLIBC_2.16'
/usr/lib64/gcc/aarch64-redhat-linux-gnu/4.7.2/../../../liblzma.so: undefined reference to
`pthread_create(a)GLIBC_2.16'
/usr/lib64/gcc/aarch64-redhat-linux-gnu/4.7.2/../../../liblzma.so: undefined reference to
`pthread_sigmask(a)GLIBC_2.16'
So this looks like something wrong in the static linker or maybe the
collect2 wrapper. I was able to work around it with:
diff --git a/etc/ld.so.conf b/etc/ld.so.conf
new file mode 100644
index 0000000..4d778f0
--- /dev/null
+++ b/etc/ld.so.conf
@@ -0,0 +1,2 @@
+/lib64
+/usr/lib64
The linker should look in those directories anyway, but for some reason
it isn't.
So, now how do I get the build into the upstream rootfs.git?
--Mark