diff options
author | Juro Bystricky <juro.bystricky@intel.com> | 2015-05-22 09:52:37 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-05-24 07:19:21 +0100 |
commit | 55fe5a06d9079639852dab804a7198313ea8cc09 (patch) | |
tree | b6a108f800d4b7d4996277123e33000e79a6cfab | |
parent | 7a7c6b021f114c6bedfbdc9afd2bf2925b238d19 (diff) | |
download | poky-55fe5a06d9079639852dab804a7198313ea8cc09.tar.gz |
eglibc-use-option-groups: Conditionally exclude c++ tests
Some test programs written in c++ are still included in spite of
"libc-cxx-tests" being omitted from DISTRO_FEATURES_LIBC.
All .cc programs are compiled with g++.
g++ automatically specifies linking against the C++ library.
This patch conditionally excludes the following tests as well:
bug-atexit3-lib.cc
tst-cancel24.cc
tst-cancel24-static.cc
tst-unique3lib.cc
tst-unique3lib2.cc
tst-unique4lib.cc
tst-unique3.cc
tst-unique4.cc
Tested with DISTRO_FEATURES_LIBC_remove = " libc-cxx-tests"
[YOCTO #7003]
(From OE-Core rev: cef29abf0c699b8bd5c5b52ba15ee63bce5fc258)
Signed-off-by: Juro Bystricky <juro.bystricky@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/recipes-core/glibc/glibc/eglibc-use-option-groups.patch | 82 |
1 files changed, 78 insertions, 4 deletions
diff --git a/meta/recipes-core/glibc/glibc/eglibc-use-option-groups.patch b/meta/recipes-core/glibc/glibc/eglibc-use-option-groups.patch index 439b4a95f6..da92203ca7 100644 --- a/meta/recipes-core/glibc/glibc/eglibc-use-option-groups.patch +++ b/meta/recipes-core/glibc/glibc/eglibc-use-option-groups.patch | |||
@@ -491,19 +491,72 @@ Index: git/dlfcn/Makefile | |||
491 | subdir := dlfcn | 491 | subdir := dlfcn |
492 | 492 | ||
493 | include ../Makeconfig | 493 | include ../Makeconfig |
494 | @@ -36,8 +38,11 @@ endif | 494 | @@ -36,14 +38,18 @@ endif |
495 | ifeq (yes,$(build-shared)) | 495 | ifeq (yes,$(build-shared)) |
496 | tests = glrefmain failtest tst-dladdr default errmsg1 tstcxaatexit \ | 496 | tests = glrefmain failtest tst-dladdr default errmsg1 tstcxaatexit \ |
497 | bug-dlopen1 bug-dlsym1 tst-dlinfo bug-atexit1 bug-atexit2 \ | 497 | bug-dlopen1 bug-dlsym1 tst-dlinfo bug-atexit1 bug-atexit2 \ |
498 | - bug-atexit3 tstatexit bug-dl-leaf tst-rec-dlopen | 498 | - bug-atexit3 tstatexit bug-dl-leaf tst-rec-dlopen |
499 | + tstatexit bug-dl-leaf tst-rec-dlopen | 499 | + tstatexit bug-dl-leaf tst-rec-dlopen |
500 | endif | ||
501 | + | ||
502 | +tests-$(OPTION_EGLIBC_CXX_TESTS) += bug-atexit3 | 500 | +tests-$(OPTION_EGLIBC_CXX_TESTS) += bug-atexit3 |
503 | + | 501 | endif |
504 | modules-names = glreflib1 glreflib2 glreflib3 failtestmod defaultmod1 \ | 502 | modules-names = glreflib1 glreflib2 glreflib3 failtestmod defaultmod1 \ |
505 | defaultmod2 errmsg1mod modatexit modcxaatexit \ | 503 | defaultmod2 errmsg1mod modatexit modcxaatexit \ |
506 | bug-dlsym1-lib1 bug-dlsym1-lib2 bug-atexit1-lib \ | 504 | bug-dlsym1-lib1 bug-dlsym1-lib2 bug-atexit1-lib \ |
505 | - bug-atexit2-lib bug-atexit3-lib bug-dl-leaf-lib \ | ||
506 | + bug-atexit2-lib bug-dl-leaf-lib \ | ||
507 | bug-dl-leaf-lib-cb moddummy1 moddummy2 | ||
508 | |||
509 | +ifeq (y,$(OPTION_EGLIBC_CXX_TESTS)) | ||
510 | +modules-names += bug-atexit3-lib | ||
511 | +endif | ||
512 | failtestmod.so-no-z-defs = yes | ||
513 | glreflib2.so-no-z-defs = yes | ||
514 | errmsg1mod.so-no-z-defs = yes | ||
515 | Index: git/elf/Makefile | ||
516 | =================================================================== | ||
517 | --- git.orig/elf/Makefile | ||
518 | +++ git/elf/Makefile | ||
519 | @@ -17,6 +17,8 @@ | ||
520 | |||
521 | # Makefile for elf subdirectory of GNU C Library. | ||
522 | |||
523 | +include ../option-groups.mak | ||
524 | + | ||
525 | subdir := elf | ||
526 | |||
527 | include ../Makeconfig | ||
528 | @@ -144,10 +146,11 @@ tests += loadtest restest1 preloadtest loadfail multiload origtest resolvfail \ | ||
529 | unload3 unload4 unload5 unload6 unload7 unload8 tst-global1 order2 \ | ||
530 | tst-audit1 tst-audit2 tst-audit8 tst-audit9 \ | ||
531 | tst-stackguard1 tst-addr1 tst-thrlock \ | ||
532 | - tst-unique1 tst-unique2 tst-unique3 tst-unique4 \ | ||
533 | + tst-unique1 tst-unique2 \ | ||
534 | tst-initorder tst-initorder2 tst-relsort1 tst-null-argv \ | ||
535 | tst-ptrguard1 | ||
536 | # reldep9 | ||
537 | +tests-$(OPTION_EGLIBC_CXX_TESTS) += tst-unique3 tst-unique4 | ||
538 | ifeq ($(build-hardcoded-path-in-tests),yes) | ||
539 | tests += tst-dlopen-aout | ||
540 | endif | ||
541 | @@ -205,8 +208,6 @@ modules-names = testobj1 testobj2 testobj3 testobj4 testobj5 testobj6 \ | ||
542 | tst-unique1mod1 tst-unique1mod2 \ | ||
543 | tst-unique2mod1 tst-unique2mod2 \ | ||
544 | tst-auditmod9a tst-auditmod9b \ | ||
545 | - tst-unique3lib tst-unique3lib2 \ | ||
546 | - tst-unique4lib \ | ||
547 | tst-initordera1 tst-initorderb1 \ | ||
548 | tst-initordera2 tst-initorderb2 \ | ||
549 | tst-initordera3 tst-initordera4 \ | ||
550 | @@ -214,6 +215,9 @@ modules-names = testobj1 testobj2 testobj3 testobj4 testobj5 testobj6 \ | ||
551 | tst-initorder2d \ | ||
552 | tst-relsort1mod1 tst-relsort1mod2 tst-array2dep \ | ||
553 | tst-array5dep tst-null-argv-lib | ||
554 | +ifeq (y,$(OPTION_EGLIBC_CXX_TESTS)) | ||
555 | +modules-names += tst-unique3lib tst-unique3lib2 tst-unique4lib | ||
556 | +endif | ||
557 | ifeq (yesyes,$(have-fpie)$(build-shared)) | ||
558 | modules-names += tst-piemod1 | ||
559 | tests += tst-pie1 tst-pie2 | ||
507 | Index: git/elf/dl-support.c | 560 | Index: git/elf/dl-support.c |
508 | =================================================================== | 561 | =================================================================== |
509 | --- git.orig/elf/dl-support.c | 562 | --- git.orig/elf/dl-support.c |
@@ -3103,6 +3156,27 @@ Index: git/nptl/Makefile | |||
3103 | # Files which must not be linked with libpthread. | 3156 | # Files which must not be linked with libpthread. |
3104 | tests-nolibpthread = tst-unload | 3157 | tests-nolibpthread = tst-unload |
3105 | 3158 | ||
3159 | @@ -363,12 +377,18 @@ | ||
3160 | $(common-objpfx)libc.a | ||
3161 | |||
3162 | tests-static += tst-locale1 tst-locale2 tst-stackguard1-static \ | ||
3163 | - tst-cancel21-static tst-cancel24-static tst-cond8-static \ | ||
3164 | + tst-cancel21-static tst-cond8-static \ | ||
3165 | tst-mutex8-static tst-mutexpi8-static tst-sem11-static \ | ||
3166 | tst-sem12-static | ||
3167 | -tests += tst-stackguard1-static tst-cancel21-static tst-cancel24-static \ | ||
3168 | + | ||
3169 | +ifeq (y,$(OPTION_EGLIBC_CXX_TESTS)) | ||
3170 | +tests-static += tst-cancel24-static | ||
3171 | +endif | ||
3172 | + | ||
3173 | +tests += tst-stackguard1-static tst-cancel21-static \ | ||
3174 | tst-cond8-static tst-mutex8-static tst-mutexpi8-static \ | ||
3175 | tst-sem11-static tst-sem12-static | ||
3176 | +tests-$(OPTION_EGLIBC_CXX_TESTS) += tst-cancel24-static | ||
3177 | xtests-static += tst-setuid1-static | ||
3178 | |||
3179 | # These tests are linked with libc before libpthread | ||
3106 | Index: git/nptl/pthread_create.c | 3180 | Index: git/nptl/pthread_create.c |
3107 | =================================================================== | 3181 | =================================================================== |
3108 | --- git.orig/nptl/pthread_create.c | 3182 | --- git.orig/nptl/pthread_create.c |