From 73709b2611f29d73dbe31de70cc775f27e2650aa Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Thu, 25 Apr 2013 19:23:11 +0000 Subject: [PATCH] Move x86_64-specific audit tests to sysdeps/x86_64/. --- ChangeLog | 96 ++++++++++++++++++++++++++++++++ elf/Makefile | 47 ---------------- sysdeps/x86_64/Makefile | 44 +++++++++++++++ {elf => sysdeps/x86_64}/tst-audit3.c | 0 {elf => sysdeps/x86_64}/tst-audit4.c | 0 {elf => sysdeps/x86_64}/tst-audit5.c | 0 {elf => sysdeps/x86_64}/tst-audit6.c | 0 {elf => sysdeps/x86_64}/tst-audit7.c | 0 {elf => sysdeps/x86_64}/tst-auditmod3a.c | 0 {elf => sysdeps/x86_64}/tst-auditmod3b.c | 0 {elf => sysdeps/x86_64}/tst-auditmod4a.c | 0 {elf => sysdeps/x86_64}/tst-auditmod4b.c | 0 {elf => sysdeps/x86_64}/tst-auditmod5a.c | 0 {elf => sysdeps/x86_64}/tst-auditmod5b.c | 0 {elf => sysdeps/x86_64}/tst-auditmod6a.c | 0 {elf => sysdeps/x86_64}/tst-auditmod6b.c | 0 {elf => sysdeps/x86_64}/tst-auditmod6c.c | 0 {elf => sysdeps/x86_64}/tst-auditmod7a.c | 0 {elf => sysdeps/x86_64}/tst-auditmod7b.c | 0 19 files changed, 140 insertions(+), 47 deletions(-) rename {elf => sysdeps/x86_64}/tst-audit3.c (100%) rename {elf => sysdeps/x86_64}/tst-audit4.c (100%) rename {elf => sysdeps/x86_64}/tst-audit5.c (100%) rename {elf => sysdeps/x86_64}/tst-audit6.c (100%) rename {elf => sysdeps/x86_64}/tst-audit7.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod3a.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod3b.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod4a.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod4b.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod5a.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod5b.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod6a.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod6b.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod6c.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod7a.c (100%) rename {elf => sysdeps/x86_64}/tst-auditmod7b.c (100%) diff --git a/ChangeLog b/ChangeLog index 1d56dad..461c466 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,99 @@ +2013-04-25 Joseph Myers + + * elf/Makefile [$(config-machine) = x86_64] (tests): Remove + additions to variable. + [$(config-machine) = x86_64] (modules-names): Likewise. + ($(objpfx)tst-audit3): Remove dependency. + ($(objpfx)tst-audit3.out): Likewise. + ($(objpfx)tst-audit4): Likewise. + ($(objpfx)tst-audit4.out): Likewise. + ($(objpfx)tst-audit5): Likewise. + ($(objpfx)tst-audit5.out): Likewise. + ($(objpfx)tst-audit6): Likewise. + ($(objpfx)tst-audit6.out): Likewise. + ($(objpfx)tst-audit7): Likewise. + ($(objpfx)tst-audit7.out): Likewise. + (tst-audit3-ENV): Remove variable. + (tst-audit4-ENV): Likewise. + (tst-audit5-ENV): Likewise. + (tst-audit6-ENV): Likewise. + (tst-audit7-ENV): Likewise. + [$(config-cflags-avx) = yes] (AVX-CFLAGS): Likewise. + [$(config-cflags-avx) = yes] (CFLAGS-tst-audit4.c): Remove + addition to variable. + [$(config-cflags-avx) = yes] (CFLAGS-tst-auditmod4a.c): Likewise. + [$(config-cflags-avx) = yes] (CFLAGS-tst-auditmod4b.c): Likewise. + [$(config-cflags-avx) = yes] (CFLAGS-tst-auditmod6b.c): Likewise. + [$(config-cflags-avx) = yes] (CFLAGS-tst-auditmod6c.c): Likewise. + [$(config-cflags-avx) = yes] (CFLAGS-tst-auditmod7b.c): Likewise. + * sysdeps/x86_64/Makefile [$(subdir) = elf] (tests): Add + tst-audit3, tst-audit4 and tst-audit5. + [$(subdir) = elf && $(config-cflags-avx) = yes] (tests): Add + tst-audit6 and tst-audit7. + [$(subdir) = elf] (modules-names): Add audit modules for those + tests. + [$(subdir) = elf] ($(objpfx)tst-audit3): New dependency. + [$(subdir) = elf] ($(objpfx)tst-audit3.out): Likewise. + [$(subdir) = elf] ($(objpfx)tst-audit4): Likewise. + [$(subdir) = elf] ($(objpfx)tst-audit4.out): Likewise. + [$(subdir) = elf] ($(objpfx)tst-audit5): Likewise. + [$(subdir) = elf] ($(objpfx)tst-audit5.out): Likewise. + [$(subdir) = elf] ($(objpfx)tst-audit6): Likewise. + [$(subdir) = elf] ($(objpfx)tst-audit6.out): Likewise. + [$(subdir) = elf] ($(objpfx)tst-audit7): Likewise. + [$(subdir) = elf] ($(objpfx)tst-audit7.out): Likewise. + [$(subdir) = elf] (tst-audit3-ENV): New variable. + [$(subdir) = elf] (tst-audit4-ENV): Likewise. + [$(subdir) = elf] (tst-audit5-ENV): Likewise. + [$(subdir) = elf] (tst-audit6-ENV): Likewise. + [$(subdir) = elf] (tst-audit7-ENV): Likewise. + [$(subdir) = elf && $(config-cflags-avx) = yes] (AVX-CFLAGS): + Likewise. + [$(subdir) = elf && $(config-cflags-avx) = yes] + (CFLAGS-tst-audit4.c): Append $(AVX-CFLAGS). + [$(subdir) = elf && $(config-cflags-avx) = yes] + (CFLAGS-tst-auditmod4a.c): Likewise. + [$(subdir) = elf && $(config-cflags-avx) = yes] + (CFLAGS-tst-auditmod4b.c): Likewise. + [$(subdir) = elf && $(config-cflags-avx) = yes] + (CFLAGS-tst-auditmod6b.c): Likewise. + [$(subdir) = elf && $(config-cflags-avx) = yes] + (CFLAGS-tst-auditmod6c.c): Likewise. + [$(subdir) = elf && $(config-cflags-avx) = yes] + (CFLAGS-tst-auditmod7b.c): Likewise. + * elf/tst-audit3.c: Move to ... + * sysdeps/x86_64/tst-audit3.c: ... here. + * elf/tst-audit4.c: Move to ... + * sysdeps/x86_64/tst-audit4.c: ... here. + * elf/tst-audit5.c: Move to ... + * sysdeps/x86_64/tst-audit5.c: ... here. + * elf/tst-audit6.c: Move to ... + * sysdeps/x86_64/tst-audit6.c: ... here. + * elf/tst-audit7.c: Move to ... + * sysdeps/x86_64/tst-audit7.c: ... here. + * elf/tst-auditmod3a.c: Move to ... + * sysdeps/x86_64/tst-auditmod3a.c: ... here. + * elf/tst-auditmod3b.c: Move to ... + * sysdeps/x86_64/tst-auditmod3b.c: ... here. + * elf/tst-auditmod4a.c: Move to ... + * sysdeps/x86_64/tst-auditmod4a.c: ... here. + * elf/tst-auditmod4b.c: Move to ... + * sysdeps/x86_64/tst-auditmod4b.c: ... here. + * elf/tst-auditmod5a.c: Move to ... + * sysdeps/x86_64/tst-auditmod5a.c: ... here. + * elf/tst-auditmod5b.c: Move to ... + * sysdeps/x86_64/tst-auditmod5b.c: ... here. + * elf/tst-auditmod6a.c: Move to ... + * sysdeps/x86_64/tst-auditmod6a.c: ... here. + * elf/tst-auditmod6b.c: Move to ... + * sysdeps/x86_64/tst-auditmod6b.c: ... here. + * elf/tst-auditmod6c.c: Move to ... + * sysdeps/x86_64/tst-auditmod6c.c: ... here. + * elf/tst-auditmod7a.c: Move to ... + * sysdeps/x86_64/tst-auditmod7a.c: ... here. + * elf/tst-auditmod7b.c: Move to ... + * sysdeps/x86_64/tst-auditmod7b.c: ... here. + 2013-04-25 Paul Pluzhnikov [BZ #15366] diff --git a/elf/Makefile b/elf/Makefile index 9477a4d..c01ca9e 100644 --- a/elf/Makefile +++ b/elf/Makefile @@ -152,12 +152,6 @@ selinux-enabled := $(shell cat /selinux/enforce 2> /dev/null) ifneq ($(selinux-enabled),1) tests-execstack-yes = tst-execstack tst-execstack-needed tst-execstack-prog endif -ifeq (x86_64,$(config-machine)) -tests += tst-audit3 tst-audit4 tst-audit5 -ifeq (yes,$(config-cflags-avx)) -tests += tst-audit6 tst-audit7 -endif -endif endif ifeq ($(run-built-tests),yes) tests: $(objpfx)tst-leaks1-mem $(objpfx)tst-leaks1-static-mem \ @@ -220,13 +214,6 @@ modules-names += tst-piemod1 tests += tst-pie1 tests-pie += tst-pie1 endif -ifeq (x86_64,$(config-machine)) -modules-names += tst-auditmod3a tst-auditmod3b \ - tst-auditmod4a tst-auditmod4b \ - tst-auditmod5a tst-auditmod5b \ - tst-auditmod6a tst-auditmod6b tst-auditmod6c \ - tst-auditmod7a tst-auditmod7b -endif modules-execstack-yes = tst-execstack-mod extra-test-objs += $(addsuffix .os,$(strip $(modules-names))) # We need this variable to be sure the test modules get the right CPPFLAGS. @@ -1001,27 +988,6 @@ tst-audit1-ENV = LD_AUDIT=$(objpfx)tst-auditmod1.so $(objpfx)tst-audit2.out: $(objpfx)tst-auditmod1.so tst-audit2-ENV = LD_AUDIT=$(objpfx)tst-auditmod1.so -$(objpfx)tst-audit3: $(objpfx)tst-auditmod3a.so -$(objpfx)tst-audit3.out: $(objpfx)tst-auditmod3b.so -tst-audit3-ENV = LD_AUDIT=$(objpfx)tst-auditmod3b.so - -$(objpfx)tst-audit4: $(objpfx)tst-auditmod4a.so -$(objpfx)tst-audit4.out: $(objpfx)tst-auditmod4b.so -tst-audit4-ENV = LD_AUDIT=$(objpfx)tst-auditmod4b.so - -$(objpfx)tst-audit5: $(objpfx)tst-auditmod5a.so -$(objpfx)tst-audit5.out: $(objpfx)tst-auditmod5b.so -tst-audit5-ENV = LD_AUDIT=$(objpfx)tst-auditmod5b.so - -$(objpfx)tst-audit6: $(objpfx)tst-auditmod6a.so -$(objpfx)tst-audit6.out: $(objpfx)tst-auditmod6b.so \ - $(objpfx)tst-auditmod6c.so -tst-audit6-ENV = LD_AUDIT=$(objpfx)tst-auditmod6b.so:$(objpfx)tst-auditmod6c.so - -$(objpfx)tst-audit7: $(objpfx)tst-auditmod7a.so -$(objpfx)tst-audit7.out: $(objpfx)tst-auditmod7b.so -tst-audit7-ENV = LD_AUDIT=$(objpfx)tst-auditmod7b.so - $(objpfx)tst-audit8: $(common-objpfx)math/libm.so $(objpfx)tst-audit8.out: $(objpfx)tst-auditmod1.so tst-audit8-ENV = LD_AUDIT=$(objpfx)tst-auditmod1.so @@ -1149,19 +1115,6 @@ $(objpfx)tst-initorder2.out: $(objpfx)tst-initorder2 $< > $@ cmp $@ tst-initorder2.exp > /dev/null -ifeq (yes,$(config-cflags-avx)) -AVX-CFLAGS=-mavx -ifeq (yes,$(config-cflags-novzeroupper)) -AVX-CFLAGS+=-mno-vzeroupper -endif -CFLAGS-tst-audit4.c += $(AVX-CFLAGS) -CFLAGS-tst-auditmod4a.c += $(AVX-CFLAGS) -CFLAGS-tst-auditmod4b.c += $(AVX-CFLAGS) -CFLAGS-tst-auditmod6b.c += $(AVX-CFLAGS) -CFLAGS-tst-auditmod6c.c += $(AVX-CFLAGS) -CFLAGS-tst-auditmod7b.c += $(AVX-CFLAGS) -endif - $(objpfx)tst-relsort1: $(libdl) $(objpfx)tst-relsort1mod1.so: $(libm) $(objpfx)tst-relsort1mod2.so $(objpfx)tst-relsort1mod2.so: $(libm) diff --git a/sysdeps/x86_64/Makefile b/sysdeps/x86_64/Makefile index 78c98e7..08db331 100644 --- a/sysdeps/x86_64/Makefile +++ b/sysdeps/x86_64/Makefile @@ -37,6 +37,50 @@ tests-pie += $(quad-pie-test) $(objpfx)tst-quad1pie: $(objpfx)tst-quadmod1pie.o $(objpfx)tst-quad2pie: $(objpfx)tst-quadmod2pie.o + +tests += tst-audit3 tst-audit4 tst-audit5 +ifeq (yes,$(config-cflags-avx)) +tests += tst-audit6 tst-audit7 +endif +modules-names += tst-auditmod3a tst-auditmod3b \ + tst-auditmod4a tst-auditmod4b \ + tst-auditmod5a tst-auditmod5b \ + tst-auditmod6a tst-auditmod6b tst-auditmod6c \ + tst-auditmod7a tst-auditmod7b + +$(objpfx)tst-audit3: $(objpfx)tst-auditmod3a.so +$(objpfx)tst-audit3.out: $(objpfx)tst-auditmod3b.so +tst-audit3-ENV = LD_AUDIT=$(objpfx)tst-auditmod3b.so + +$(objpfx)tst-audit4: $(objpfx)tst-auditmod4a.so +$(objpfx)tst-audit4.out: $(objpfx)tst-auditmod4b.so +tst-audit4-ENV = LD_AUDIT=$(objpfx)tst-auditmod4b.so + +$(objpfx)tst-audit5: $(objpfx)tst-auditmod5a.so +$(objpfx)tst-audit5.out: $(objpfx)tst-auditmod5b.so +tst-audit5-ENV = LD_AUDIT=$(objpfx)tst-auditmod5b.so + +$(objpfx)tst-audit6: $(objpfx)tst-auditmod6a.so +$(objpfx)tst-audit6.out: $(objpfx)tst-auditmod6b.so \ + $(objpfx)tst-auditmod6c.so +tst-audit6-ENV = LD_AUDIT=$(objpfx)tst-auditmod6b.so:$(objpfx)tst-auditmod6c.so + +$(objpfx)tst-audit7: $(objpfx)tst-auditmod7a.so +$(objpfx)tst-audit7.out: $(objpfx)tst-auditmod7b.so +tst-audit7-ENV = LD_AUDIT=$(objpfx)tst-auditmod7b.so + +ifeq (yes,$(config-cflags-avx)) +AVX-CFLAGS=-mavx +ifeq (yes,$(config-cflags-novzeroupper)) +AVX-CFLAGS+=-mno-vzeroupper +endif +CFLAGS-tst-audit4.c += $(AVX-CFLAGS) +CFLAGS-tst-auditmod4a.c += $(AVX-CFLAGS) +CFLAGS-tst-auditmod4b.c += $(AVX-CFLAGS) +CFLAGS-tst-auditmod6b.c += $(AVX-CFLAGS) +CFLAGS-tst-auditmod6c.c += $(AVX-CFLAGS) +CFLAGS-tst-auditmod7b.c += $(AVX-CFLAGS) +endif endif ifeq ($(subdir),csu) diff --git a/elf/tst-audit3.c b/sysdeps/x86_64/tst-audit3.c similarity index 100% rename from elf/tst-audit3.c rename to sysdeps/x86_64/tst-audit3.c diff --git a/elf/tst-audit4.c b/sysdeps/x86_64/tst-audit4.c similarity index 100% rename from elf/tst-audit4.c rename to sysdeps/x86_64/tst-audit4.c diff --git a/elf/tst-audit5.c b/sysdeps/x86_64/tst-audit5.c similarity index 100% rename from elf/tst-audit5.c rename to sysdeps/x86_64/tst-audit5.c diff --git a/elf/tst-audit6.c b/sysdeps/x86_64/tst-audit6.c similarity index 100% rename from elf/tst-audit6.c rename to sysdeps/x86_64/tst-audit6.c diff --git a/elf/tst-audit7.c b/sysdeps/x86_64/tst-audit7.c similarity index 100% rename from elf/tst-audit7.c rename to sysdeps/x86_64/tst-audit7.c diff --git a/elf/tst-auditmod3a.c b/sysdeps/x86_64/tst-auditmod3a.c similarity index 100% rename from elf/tst-auditmod3a.c rename to sysdeps/x86_64/tst-auditmod3a.c diff --git a/elf/tst-auditmod3b.c b/sysdeps/x86_64/tst-auditmod3b.c similarity index 100% rename from elf/tst-auditmod3b.c rename to sysdeps/x86_64/tst-auditmod3b.c diff --git a/elf/tst-auditmod4a.c b/sysdeps/x86_64/tst-auditmod4a.c similarity index 100% rename from elf/tst-auditmod4a.c rename to sysdeps/x86_64/tst-auditmod4a.c diff --git a/elf/tst-auditmod4b.c b/sysdeps/x86_64/tst-auditmod4b.c similarity index 100% rename from elf/tst-auditmod4b.c rename to sysdeps/x86_64/tst-auditmod4b.c diff --git a/elf/tst-auditmod5a.c b/sysdeps/x86_64/tst-auditmod5a.c similarity index 100% rename from elf/tst-auditmod5a.c rename to sysdeps/x86_64/tst-auditmod5a.c diff --git a/elf/tst-auditmod5b.c b/sysdeps/x86_64/tst-auditmod5b.c similarity index 100% rename from elf/tst-auditmod5b.c rename to sysdeps/x86_64/tst-auditmod5b.c diff --git a/elf/tst-auditmod6a.c b/sysdeps/x86_64/tst-auditmod6a.c similarity index 100% rename from elf/tst-auditmod6a.c rename to sysdeps/x86_64/tst-auditmod6a.c diff --git a/elf/tst-auditmod6b.c b/sysdeps/x86_64/tst-auditmod6b.c similarity index 100% rename from elf/tst-auditmod6b.c rename to sysdeps/x86_64/tst-auditmod6b.c diff --git a/elf/tst-auditmod6c.c b/sysdeps/x86_64/tst-auditmod6c.c similarity index 100% rename from elf/tst-auditmod6c.c rename to sysdeps/x86_64/tst-auditmod6c.c diff --git a/elf/tst-auditmod7a.c b/sysdeps/x86_64/tst-auditmod7a.c similarity index 100% rename from elf/tst-auditmod7a.c rename to sysdeps/x86_64/tst-auditmod7a.c diff --git a/elf/tst-auditmod7b.c b/sysdeps/x86_64/tst-auditmod7b.c similarity index 100% rename from elf/tst-auditmod7b.c rename to sysdeps/x86_64/tst-auditmod7b.c -- 2.7.4