summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Maw <richard.maw@codethink.co.uk>2014-02-21 14:05:38 +0000
committerRichard Maw <richard.maw@codethink.co.uk>2014-02-27 15:56:12 +0000
commit1e200dfca196e462696c5e844a9c956b1e2b5111 (patch)
tree3bd703b1bb29545e62d28d84b94c592a50487466
parente51d56cdcf2d9a4372c89a1e88ab78bf7c329df7 (diff)
downloadeglibc2-1e200dfca196e462696c5e844a9c956b1e2b5111.tar.gz
-rw-r--r--armv7lhf-cross-eglibc.morph48
1 files changed, 48 insertions, 0 deletions
diff --git a/armv7lhf-cross-eglibc.morph b/armv7lhf-cross-eglibc.morph
new file mode 100644
index 000000000..3b5fbe696
--- /dev/null
+++ b/armv7lhf-cross-eglibc.morph
@@ -0,0 +1,48 @@
+name: armv7lhf-cross-eglibc
+kind: chunk
+
+configure-commands:
+ - mkdir o
+
+ # Necessary for ARM port
+ - cd libc && ln -s ../ports ports
+
+ # Configure flag notes:
+ # 1. Location of linux-api-headers, needed since eglibc doesn't
+ # support being given a sysroot.
+ # 2. Location of binutils, since we build binutils for the final
+ # target triplet, but our gcc of our stage 1 target triplet.
+ # 3. Normal flags. See eglibc.morph.
+ # 4. Force configuration values of certain things that can't be detected
+ # in a cross-compile.
+ - |
+ export MORPH_ARCH=armv7lhf
+ export TARGET=armv7lhf-baserock-linux-gnueabi
+ export TARGET_STAGE1=armv7lhf-none-linux-gnueabi
+ export CFLAGS="-O2 $CFLAGS"
+ # Try harder to ensure it uses the right compiler
+ # FIXME: Try removing and hope --build is sufficient, or set
+ # --build to $TARGET and remove --with-binutils
+ export CC="$TARGET_STAGE1-gcc"
+ export CPP="$TARGET_STAGE1-cpp"
+ cd o && ../libc/configure \
+ $(../morph-arch-config) \
+ --build=$TARGET_STAGE1 --host=$TARGET \
+ --prefix="$PREFIX" \
+ `# [1]` --with-headers="$PREFIX/$TARGET/sys-root/$PREFIX/include" \
+ `# [2]` --with-binutils="$PREFIX/$TARGET/bin" \
+ `# [3]` --disable-profile --enable-kernel=2.6.25 \
+ --enable-add-ons=nptl,ports --without-cvs --without-selinux \
+ `# [4]` libc_cv_c_cleanup=yes libc_cv_ctors_header=yes \
+ libc_cv_forced_unwind=yes libc_cv_ssp=no
+
+build-commands:
+ - cd o && make localtime=UTC
+
+install-commands:
+ - |
+ # eglibc doesn't help with sysroots, so we need to spell out the
+ # full path ourselves.
+ export TARGET=armv7lhf-baserock-linux-gnueabi
+ cd o && make install_root="$DESTDIR/$PREFIX/$TARGET/sys-root/" \
+ localtime=UTC install