summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/glibc/glibc-testing.inc
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2014-08-28 06:00:54 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-09-01 18:02:21 +0100
commit54a3375a1084f02ebd95886739e951228e945c57 (patch)
treefe139449256b0ed85504b896a9782bccd8a9d3a1 /meta/recipes-core/glibc/glibc-testing.inc
parent954e45bc7464573ed4776dbcd72eb76d4fca0b3d (diff)
downloadpoky-54a3375a1084f02ebd95886739e951228e945c57.tar.gz
glibc: Migrate eglibc 2.19 -> glibc 2.20
- This is a big swoop change where we switch to using glibc - option-groups are forward ported - cross-localedef is extracted out from eglibc and hosted at github.com/kraj/localedef, its used for cross-localedef recipe - Other non ported patches from eglibc are forward ported ppc8xx cache line workaround SH fpcr values dynamic resolver installing PIC archives is there but is not applied libc header bootstrap - Delete eglibc recipes we moved back to using glibc now - Fix ppc/e500 build - Fix crypt module build when options are used - Fix fnmatch build when options OPTION_EGLIBC_LOCALE_CODE is unset HAVE_MBSTATE_T and HAVE_MBSRTOWCS should be defined conditionally based upon OPTION_EGLIBC_LOCALE_CODE being set/unset - Move the ports/ patches to relevant files now that ports is gone (From OE-Core rev: 1027c535ea753e63d9ffe469a423e04467cf8940) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/glibc/glibc-testing.inc')
-rw-r--r--meta/recipes-core/glibc/glibc-testing.inc79
1 files changed, 79 insertions, 0 deletions
diff --git a/meta/recipes-core/glibc/glibc-testing.inc b/meta/recipes-core/glibc/glibc-testing.inc
new file mode 100644
index 0000000000..ec16fe1fde
--- /dev/null
+++ b/meta/recipes-core/glibc/glibc-testing.inc
@@ -0,0 +1,79 @@
1do_compile_append () {
2 # now generate script to drive testing
3 echo "#!/usr/bin/env sh" >${B}/${HOST_PREFIX}testglibc
4 set >> ${B}/${HOST_PREFIX}testglibc
5 # prune out the unneeded vars
6 sed -i -e "/^BASH/d" ${B}/${HOST_PREFIX}testglibc
7 sed -i -e "/^USER/d" ${B}/${HOST_PREFIX}testglibc
8 sed -i -e "/^OPT/d" ${B}/${HOST_PREFIX}testglibc
9 sed -i -e "/^DIRSTACK/d" ${B}/${HOST_PREFIX}testglibc
10 sed -i -e "/^EUID/d" ${B}/${HOST_PREFIX}testglibc
11 sed -i -e "/^FUNCNAME/d" ${B}/${HOST_PREFIX}testglibc
12 sed -i -e "/^GROUPS/d" ${B}/${HOST_PREFIX}testglibc
13 sed -i -e "/^HOST/d" ${B}/${HOST_PREFIX}testglibc
14 sed -i -e "/^HOME/d" ${B}/${HOST_PREFIX}testglibc
15 sed -i -e "/^IFS/d" ${B}/${HOST_PREFIX}testglibc
16 sed -i -e "/^LC_ALL/d" ${B}/${HOST_PREFIX}testglibc
17 sed -i -e "/^LOGNAME/d" ${B}/${HOST_PREFIX}testglibc
18 sed -i -e "/^MACHTYPE/d" ${B}/${HOST_PREFIX}testglibc
19 sed -i -e "/^OSTYPE/d" ${B}/${HOST_PREFIX}testglibc
20 sed -i -e "/^PIPE/d" ${B}/${HOST_PREFIX}testglibc
21 sed -i -e "/^SHELL/d" ${B}/${HOST_PREFIX}testglibc
22 sed -i -e "/^'/d" ${B}/${HOST_PREFIX}testglibc
23 sed -i -e "/^UID/d" ${B}/${HOST_PREFIX}testglibc
24 sed -i -e "/^TERM/d" ${B}/${HOST_PREFIX}testglibc
25 sed -i -e "/^PATCH_GET/d" ${B}/${HOST_PREFIX}testglibc
26 sed -i -e "/^PKG_/d" ${B}/${HOST_PREFIX}testglibc
27 sed -i -e "/^POSIXLY_/d" ${B}/${HOST_PREFIX}testglibc
28 sed -i -e "/^PPID/d" ${B}/${HOST_PREFIX}testglibc
29 sed -i -e "/^PS4/d" ${B}/${HOST_PREFIX}testglibc
30 sed -i -e "/^Q/d" ${B}/${HOST_PREFIX}testglibc
31 sed -i -e "/^SHLVL/d" ${B}/${HOST_PREFIX}testglibc
32 sed -i -e "/^STAGING/d" ${B}/${HOST_PREFIX}testglibc
33 sed -i -e "/^LD_LIBRARY_PATH/d" ${B}/${HOST_PREFIX}testglibc
34 sed -i -e "/^PSEUDO/d" ${B}/${HOST_PREFIX}testglibc
35
36 # point to real sysroot not the toolchain bootstrap sysroot
37 sed -i -e "s/\-tcbootstrap//g" ${B}/${HOST_PREFIX}testglibc
38
39 # use the final cross-gcc to test since some tests need libstdc++
40 sed -i -e "s/^PATH=.*\.gcc-cross-initial\:/PATH=/g" ${B}/${HOST_PREFIX}testglibc
41
42 # append execution part script
43cat >> ${B}/${HOST_PREFIX}testglibc << STOP
44target="\$1"
45if [ "x\$target" = "x" ]
46then
47 echo "Please specify the target machine and remote user in form of user@target"
48 exit 1;
49fi
50ssh \$target ls \$PWD\ 2>&1 > /dev/null
51if [ "x\$?" != "x0" ]
52then
53 echo "Failed connecting to \$target it could be because of:"
54 echo "1. You dont have passwordless ssh setup to access \$target"
55 echo "2. NFS share on \$target is not mounted or if mounted then not matching the build tree layout."
56 echo " The tree should be accessible at same location on build host and target"
57 echo " You can add nfs-server to IMAGE_FEATURES to get the nfs client on target"
58 echo "3. nfs server on build host is not running."
59 echo " Please make sure that you have 'no_root_squash' added in /etc/exports if you want"
60 echo " to test as root user on target (usually its recommended to create a non"
61 echo " root user."
62 echo " As a sanity check make sure that target can read/write to the glibc build tree"
63 echo " Please refer to ${S}/EGLIBC.cross-testing for further instructions on setup"
64 exit 1
65fi
66 echo "# we test using cross compiler from real sysroot therefore override the" > ${B}/configparms
67 echo "# definitions that come from ${B}/config.make" >> ${B}/configparms
68
69 fgrep tcbootstrap ${B}/config.make > ${B}/configparms
70 sed -i -e "s/\-tcbootstrap//g" ${B}/configparms
71wrapper="${S}/scripts/cross-test-ssh.sh \$target"
72localedef="${STAGING_BINDIR_NATIVE}/cross-localedef --little-endian --uint32-align=4"
73make tests-clean
74make cross-localedef="\$localedef" cross-test-wrapper="\$wrapper" -k check
75rm -rf ${B}/configparms
76STOP
77
78 chmod +x ${B}/${HOST_PREFIX}testglibc
79}