Re: [BUILDROBOT] Selftest failed for i686-wrs-vxworks
Hi! On Wed, 5 Oct 2016 16:36:01 +0200, Bernd Schmidtwrote: > On 10/05/2016 04:14 PM, David Malcolm wrote: > > Thanks. I'm not able to formally approve these changes, but FWIW these > > patches look good to me (assuming usual testing). > > LGTM too, so OK. Without changes, committed to trunk in r241043 and r241044: commit 441751466e69eaf8d8da7c0d388055509b35bc63 Author: tschwinge Date: Wed Oct 12 13:09:06 2016 + In gcc/Makefile.in, factor out SELFTEST_FLAGS gcc/ * Makefile.in (SELFTEST_FLAGS): New variable. (s-selftest, selftest-gdb, selftest-valgrind): Use it. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@241043 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 3 +++ gcc/Makefile.in | 11 --- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git gcc/ChangeLog gcc/ChangeLog index e57438e..003316f 100644 --- gcc/ChangeLog +++ gcc/ChangeLog @@ -1,5 +1,8 @@ 2016-10-12 Thomas Schwinge + * Makefile.in (SELFTEST_FLAGS): New variable. + (s-selftest, selftest-gdb, selftest-valgrind): Use it. + * vmsdbgout.c (vmsdbg_debug_hooks): Add filename parameter to early_finish hook. diff --git gcc/Makefile.in gcc/Makefile.in index 2914605..02d0c45 100644 --- gcc/Makefile.in +++ gcc/Makefile.in @@ -1877,6 +1877,10 @@ endif # This does the things that can't be done on the host machine. rest.cross: specs +# GCC's selftests. +# Specify a dummy input file to placate the driver. +SELFTEST_FLAGS = -x c /dev/null -S -fself-test + # Run the selftests during the build once we have a driver and a cc1, # so that self-test failures are caught as early as possible. # Use "s-selftest" to ensure that we only run the selftests if the @@ -1884,18 +1888,19 @@ rest.cross: specs .PHONY: selftest selftest: s-selftest s-selftest: $(GCC_PASSES) cc1$(exeext) stmp-int-hdrs - $(GCC_FOR_TARGET) -xc -S -c /dev/null -fself-test + $(GCC_FOR_TARGET) $(SELFTEST_FLAGS) $(STAMP) $@ # Convenience method for running selftests under gdb: .PHONY: selftest-gdb selftest-gdb: $(GCC_PASSES) cc1$(exeext) stmp-int-hdrs - $(GCC_FOR_TARGET) -xc -S -c /dev/null -fself-test -wrapper gdb,--args + $(GCC_FOR_TARGET) $(SELFTEST_FLAGS) \ + -wrapper gdb,--args # Convenience method for running selftests under valgrind: .PHONY: selftest-valgrind selftest-valgrind: $(GCC_PASSES) cc1$(exeext) stmp-int-hdrs - $(GCC_FOR_TARGET) -xc -S -c /dev/null -fself-test \ + $(GCC_FOR_TARGET) $(SELFTEST_FLAGS) \ -wrapper valgrind,--leak-check=full # Recompile all the language-independent object files. commit c2d86129ef8141bb214958ca90be15fbeb42f4b1 Author: tschwinge Date: Wed Oct 12 13:09:17 2016 + Make GCC selftests work for *-wrs-vxworks-* targets gcc/ * Makefile.in (SELFTEST_FLAGS): Add -nostdinc. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@241044 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 2 ++ gcc/Makefile.in | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git gcc/ChangeLog gcc/ChangeLog index 003316f..d6880d9 100644 --- gcc/ChangeLog +++ gcc/ChangeLog @@ -1,5 +1,7 @@ 2016-10-12 Thomas Schwinge + * Makefile.in (SELFTEST_FLAGS): Add -nostdinc. + * Makefile.in (SELFTEST_FLAGS): New variable. (s-selftest, selftest-gdb, selftest-valgrind): Use it. diff --git gcc/Makefile.in gcc/Makefile.in index 02d0c45..f1ff782 100644 --- gcc/Makefile.in +++ gcc/Makefile.in @@ -1879,7 +1879,9 @@ rest.cross: specs # GCC's selftests. # Specify a dummy input file to placate the driver. -SELFTEST_FLAGS = -x c /dev/null -S -fself-test +# Specify -nostdinc to work around missing WIND_BASE environment variable +# required for *-wrs-vxworks-* targets. +SELFTEST_FLAGS = -nostdinc -x c /dev/null -S -fself-test # Run the selftests during the build once we have a driver and a cc1, # so that self-test failures are caught as early as possible. Grüße Thomas
Re: [BUILDROBOT] Selftest failed for i686-wrs-vxworks
On 10/05/2016 04:14 PM, David Malcolm wrote: Thanks. I'm not able to formally approve these changes, but FWIW these patches look good to me (assuming usual testing). LGTM too, so OK. Bernd
Re: [BUILDROBOT] Selftest failed for i686-wrs-vxworks
On Wed, 2016-10-05 at 14:34 +0200, Thomas Schwinge wrote: > Hi! > > I've now also run into this issue, during contrib/config-list.mk > testing; > log/arm-wrs-vxworks-make.out, log/i686-wrs-vxworks-make.out, > log/i686-wrs-vxworksae-make.out, log/mips-wrs-vxworks-make.out, > log/powerpc-wrs-vxworks-make.out, log/powerpc-wrs-vxworksae-make.out, > log/powerpc-wrs-vxworksmils-make.out, log/sh-wrs-vxworks-make.out, > log/sparc-wrs-vxworks-make.out: > > [...]/build-multi/arm-wrs-vxworks/./gcc/xgcc -B[...]/build > -multi/arm-wrs-vxworks/./gcc/ -xc -S -c /dev/null -fself-test > xgcc: fatal error: environment variable 'WIND_BASE' not defined > compilation terminated. > make[2]: *** [s-selftest] Error 1 > [...] > make[1]: *** [all-gcc] Error 2 > > On Thu, 30 Jun 2016 16:09:23 -0400, David Malcolm < > dmalc...@redhat.com> wrote: > > On Thu, 2016-06-30 at 08:38 -0400, Nathan Sidwell wrote: > > > [...] WIND_BASE is expected to point at a vxworks install [...] > > > [...] > > > > Hence it appears that passing "-nostdinc" as a param will avoid the > > error: [...] > > > > Presumably if you're explicitly building for vxworks you have a > > vxworks > > install, so there is a meaningful value to set WIND_BASE to, > > whereas if > > you don't have a vxworks install (and are merely building > > everything as > > a smoketest), you presumably only want to build the "gcc" subdir, > > since > > AFAIK you can't run then driver. > > > > So there are at least 2 ways of fixing this: > > > > (a) add "-nostdinc" when running the selftests i.e. to the > > invocations > > of GCC_FOR_TARGET in the "s-selftest" and "selftest-gdb" clauses of > > gcc/Makefile.in. > > I've verified that this fixes the issue for --target=i686-wrs > > -vxworks. > > OK to apply the following two patches? First, a little bit of > refactoring: > > commit 0b124fda378c9dc726bd709f805dd52a7dc7c78a > Author: Thomas Schwinge> Date: Wed Oct 5 08:06:00 2016 +0200 > > In gcc/Makefile.in, factor out SELFTEST_FLAGS > > gcc/ > * Makefile.in (SELFTEST_FLAGS): New variable. > (s-selftest, selftest-gdb, selftest-valgrind): Use it. > --- > gcc/Makefile.in | 11 --- > 1 file changed, 8 insertions(+), 3 deletions(-) > > diff --git gcc/Makefile.in gcc/Makefile.in > index 15c48bc..08b96a6 100644 > --- gcc/Makefile.in > +++ gcc/Makefile.in > @@ -1876,6 +1876,10 @@ endif > # This does the things that can't be done on the host machine. > rest.cross: specs > > +# GCC's selftests. > +# Specify a dummy input file to placate the driver. > +SELFTEST_FLAGS = -x c /dev/null -S -fself-test > + > # Run the selftests during the build once we have a driver and a > cc1, > # so that self-test failures are caught as early as possible. > # Use "s-selftest" to ensure that we only run the selftests if the > @@ -1883,18 +1887,19 @@ rest.cross: specs > .PHONY: selftest > selftest: s-selftest > s-selftest: $(GCC_PASSES) cc1$(exeext) stmp-int-hdrs > - $(GCC_FOR_TARGET) -xc -S -c /dev/null -fself-test > + $(GCC_FOR_TARGET) $(SELFTEST_FLAGS) > $(STAMP) $@ > > # Convenience method for running selftests under gdb: > .PHONY: selftest-gdb > selftest-gdb: $(GCC_PASSES) cc1$(exeext) stmp-int-hdrs > - $(GCC_FOR_TARGET) -xc -S -c /dev/null -fself-test -wrapper > gdb,--args > + $(GCC_FOR_TARGET) $(SELFTEST_FLAGS) \ > + -wrapper gdb,--args > > # Convenience method for running selftests under valgrind: > .PHONY: selftest-valgrind > selftest-valgrind: $(GCC_PASSES) cc1$(exeext) stmp-int-hdrs > - $(GCC_FOR_TARGET) -xc -S -c /dev/null -fself-test \ > + $(GCC_FOR_TARGET) $(SELFTEST_FLAGS) \ > -wrapper valgrind,--leak-check=full > > # Recompile all the language-independent object files. > > ..., and then the real change: > > commit 8ab49582c42809b385eb957c20b84d21a90e041a > Author: Thomas Schwinge > Date: Wed Oct 5 08:08:37 2016 +0200 > > Make GCC selftests work for *-wrs-vxworks-* targets > > gcc/ > Makefile.in (SELFTEST_FLAGS): Add -nostdinc. > --- > gcc/Makefile.in | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git gcc/Makefile.in gcc/Makefile.in > index 08b96a6..23623ac 100644 > --- gcc/Makefile.in > +++ gcc/Makefile.in > @@ -1878,7 +1878,9 @@ rest.cross: specs > > # GCC's selftests. > # Specify a dummy input file to placate the driver. > -SELFTEST_FLAGS = -x c /dev/null -S -fself-test > +# Specify -nostdinc to work around missing WIND_BASE environment > variable > +# required for *-wrs-vxworks-* targets. > +SELFTEST_FLAGS = -nostdinc -x c /dev/null -S -fself-test > > # Run the selftests during the build once we have a driver and a > cc1, > # so that self-test failures are caught as early as possible. Thanks. I'm not able to formally approve these changes, but FWIW these patches look good to me (assuming usual testing).
Re: [BUILDROBOT] Selftest failed for i686-wrs-vxworks
Hi! I've now also run into this issue, during contrib/config-list.mk testing; log/arm-wrs-vxworks-make.out, log/i686-wrs-vxworks-make.out, log/i686-wrs-vxworksae-make.out, log/mips-wrs-vxworks-make.out, log/powerpc-wrs-vxworks-make.out, log/powerpc-wrs-vxworksae-make.out, log/powerpc-wrs-vxworksmils-make.out, log/sh-wrs-vxworks-make.out, log/sparc-wrs-vxworks-make.out: [...]/build-multi/arm-wrs-vxworks/./gcc/xgcc -B[...]/build-multi/arm-wrs-vxworks/./gcc/ -xc -S -c /dev/null -fself-test xgcc: fatal error: environment variable 'WIND_BASE' not defined compilation terminated. make[2]: *** [s-selftest] Error 1 [...] make[1]: *** [all-gcc] Error 2 On Thu, 30 Jun 2016 16:09:23 -0400, David Malcolmwrote: > On Thu, 2016-06-30 at 08:38 -0400, Nathan Sidwell wrote: > > [...] WIND_BASE is expected to point at a vxworks install [...] > [...] > > Hence it appears that passing "-nostdinc" as a param will avoid the > error: [...] > > Presumably if you're explicitly building for vxworks you have a vxworks > install, so there is a meaningful value to set WIND_BASE to, whereas if > you don't have a vxworks install (and are merely building everything as > a smoketest), you presumably only want to build the "gcc" subdir, since > AFAIK you can't run then driver. > > So there are at least 2 ways of fixing this: > > (a) add "-nostdinc" when running the selftests i.e. to the invocations > of GCC_FOR_TARGET in the "s-selftest" and "selftest-gdb" clauses of > gcc/Makefile.in. > I've verified that this fixes the issue for --target=i686-wrs-vxworks. OK to apply the following two patches? First, a little bit of refactoring: commit 0b124fda378c9dc726bd709f805dd52a7dc7c78a Author: Thomas Schwinge Date: Wed Oct 5 08:06:00 2016 +0200 In gcc/Makefile.in, factor out SELFTEST_FLAGS gcc/ * Makefile.in (SELFTEST_FLAGS): New variable. (s-selftest, selftest-gdb, selftest-valgrind): Use it. --- gcc/Makefile.in | 11 --- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git gcc/Makefile.in gcc/Makefile.in index 15c48bc..08b96a6 100644 --- gcc/Makefile.in +++ gcc/Makefile.in @@ -1876,6 +1876,10 @@ endif # This does the things that can't be done on the host machine. rest.cross: specs +# GCC's selftests. +# Specify a dummy input file to placate the driver. +SELFTEST_FLAGS = -x c /dev/null -S -fself-test + # Run the selftests during the build once we have a driver and a cc1, # so that self-test failures are caught as early as possible. # Use "s-selftest" to ensure that we only run the selftests if the @@ -1883,18 +1887,19 @@ rest.cross: specs .PHONY: selftest selftest: s-selftest s-selftest: $(GCC_PASSES) cc1$(exeext) stmp-int-hdrs - $(GCC_FOR_TARGET) -xc -S -c /dev/null -fself-test + $(GCC_FOR_TARGET) $(SELFTEST_FLAGS) $(STAMP) $@ # Convenience method for running selftests under gdb: .PHONY: selftest-gdb selftest-gdb: $(GCC_PASSES) cc1$(exeext) stmp-int-hdrs - $(GCC_FOR_TARGET) -xc -S -c /dev/null -fself-test -wrapper gdb,--args + $(GCC_FOR_TARGET) $(SELFTEST_FLAGS) \ + -wrapper gdb,--args # Convenience method for running selftests under valgrind: .PHONY: selftest-valgrind selftest-valgrind: $(GCC_PASSES) cc1$(exeext) stmp-int-hdrs - $(GCC_FOR_TARGET) -xc -S -c /dev/null -fself-test \ + $(GCC_FOR_TARGET) $(SELFTEST_FLAGS) \ -wrapper valgrind,--leak-check=full # Recompile all the language-independent object files. ..., and then the real change: commit 8ab49582c42809b385eb957c20b84d21a90e041a Author: Thomas Schwinge Date: Wed Oct 5 08:08:37 2016 +0200 Make GCC selftests work for *-wrs-vxworks-* targets gcc/ Makefile.in (SELFTEST_FLAGS): Add -nostdinc. --- gcc/Makefile.in | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git gcc/Makefile.in gcc/Makefile.in index 08b96a6..23623ac 100644 --- gcc/Makefile.in +++ gcc/Makefile.in @@ -1878,7 +1878,9 @@ rest.cross: specs # GCC's selftests. # Specify a dummy input file to placate the driver. -SELFTEST_FLAGS = -x c /dev/null -S -fself-test +# Specify -nostdinc to work around missing WIND_BASE environment variable +# required for *-wrs-vxworks-* targets. +SELFTEST_FLAGS = -nostdinc -x c /dev/null -S -fself-test # Run the selftests during the build once we have a driver and a cc1, # so that self-test failures are caught as early as possible. Grüße Thomas
Re: [BUILDROBOT] Selftest failed for i686-wrs-vxworks
On Thu, 2016-06-30 16:09:23 -0400, David Malcolmwrote: > On Thu, 2016-06-30 at 08:38 -0400, Nathan Sidwell wrote: > > > I haven't given it any additional manual testing so far. It's > > > pre-installation though. Maybe I'd just set WIND_BASE to some > > > arbitrary value, just to make xgcc pass it's initial start-up > > > test so that it can continue with self-testing? Or shall we set > > > some value in gcc/Makefile.in for running the self-test? > > > > As I recall, WIND_BASE is expected to point at a vxworks install > > to pick up header files. It is an error not to have it set > > (silently skipping it leads to user confusion). > > > > If that's irrelevant for this testing environment, then setting it > > to something (probably just "", but safer might be > > "/These.are.not.the.dirs.you.are.looking.for") should be fine. > > Sorry about the breakage. You just uncovered it :) > The error message appears to affect a few other targets within > gcc/Makefile.in. [...] > > So there are at least 2 ways of fixing this: > > (a) add "-nostdinc" when running the selftests i.e. to the invocations > of GCC_FOR_TARGET in the "s-selftest" and "selftest-gdb" clauses of > gcc/Makefile.in. > I've verified that this fixes the issue for --target=i686-wrs-vxworks. > > (b) set WIND_BASE to a dummy value in contrib/config-list.mk (if not > already set) so that the vxworks targets are able to at least build all > of "gcc" without needing a vxworks install. I'd probably just do (b) and go for it. Easy, non-invasive fix. MfG, JBG -- Jan-Benedict Glaw jbg...@lug-owl.de +49-172-7608481 Signature of:Don't believe in miracles: Rely on them! the second : signature.asc Description: Digital signature
Re: [BUILDROBOT] Selftest failed for i686-wrs-vxworks
On Thu, 2016-06-30 at 08:38 -0400, Nathan Sidwell wrote: > Jan-Benedict, > > > I haven't given it any additional manual testing so far. It's > > pre-installation though. Maybe I'd just set WIND_BASE to some > > arbitrary value, just to make xgcc pass it's initial start-up test > > so > > that it can continue with self-testing? Or shall we set some value > > in gcc/Makefile.in for running the self-test? > > As I recall, WIND_BASE is expected to point at a vxworks install to > pick up > header files. It is an error not to have it set (silently skipping > it leads to > user confusion). > > If that's irrelevant for this testing environment, then setting it to > something > (probably just "", but safer might be > "/These.are.not.the.dirs.you.are.looking.for") should be fine. Sorry about the breakage. The error message appears to affect a few other targets within gcc/Makefile.in. For example: $ make s-macro_list echo | ./xgcc -B./ -B/usr/local/i686-wrs-vxworks/bin/ -isystem /usr/local/i686-wrs-vxworks/include -isystem /usr/local/i686-wrs -vxworks/sys-include -L/home/david/archive/huge/gcc-git-all -configs/selftest-multi-mk/i686-wrs-vxworks/gcc/../ld -E -dM - | \ sed -n -e 's/^#define \([^_][a-zA-Z0-9_]*\).*/\1/p' \ -e 's/^#define \(_[^_A-Z][a-zA-Z0-9_]*\).*/\1/p' | \ sort -u > tmp-macro_list xgcc: fatal error: environment variable ‘WIND_BASE’ not defined compilation terminated. /bin/sh /home/david/coding-3/gcc-git-unittests/src/gcc/../move-if -change tmp-macro_list macro_list cmp: EOF on tmp-macro_list echo timestamp > s-macro_list However the above issue doesn't fail the build: $ echo $? 0 It can be trivially reproduced like this: $ ./xgcc -B. -E - xgcc: fatal error: environment variable ‘WIND_BASE’ not defined compilation terminated. It happens due to evaluating this spec function: "getenv(WIND_BASE /target/h)" from this within gcc/config/vxworks.h: /* Since we provide a default -isystem, expand -isystem on the command line early. */ #undef VXWORKS_ADDITIONAL_CPP_SPEC #define VXWORKS_ADDITIONAL_CPP_SPEC \ "%{!nostdinc: \ %{isystem*} -idirafter \ %{mrtp: %:getenv(WIND_USR /h) \ ;:%:getenv(WIND_BASE /target/h)}}" Hence it appears that passing "-nostdinc" as a param will avoid the error: $ echo | ./xgcc -B. -E - -nostdinc # 1 "" # 1 "" # 1 "" # 1 "" $ echo $? 0 Presumably if you're explicitly building for vxworks you have a vxworks install, so there is a meaningful value to set WIND_BASE to, whereas if you don't have a vxworks install (and are merely building everything as a smoketest), you presumably only want to build the "gcc" subdir, since AFAIK you can't run then driver. So there are at least 2 ways of fixing this: (a) add "-nostdinc" when running the selftests i.e. to the invocations of GCC_FOR_TARGET in the "s-selftest" and "selftest-gdb" clauses of gcc/Makefile.in. I've verified that this fixes the issue for --target=i686-wrs-vxworks. (b) set WIND_BASE to a dummy value in contrib/config-list.mk (if not already set) so that the vxworks targets are able to at least build all of "gcc" without needing a vxworks install. Thoughts?
Re: [BUILDROBOT] Selftest failed for i686-wrs-vxworks
Jan-Benedict, I haven't given it any additional manual testing so far. It's pre-installation though. Maybe I'd just set WIND_BASE to some arbitrary value, just to make xgcc pass it's initial start-up test so that it can continue with self-testing? Or shall we set some value in gcc/Makefile.in for running the self-test? As I recall, WIND_BASE is expected to point at a vxworks install to pick up header files. It is an error not to have it set (silently skipping it leads to user confusion). If that's irrelevant for this testing environment, then setting it to something (probably just "", but safer might be "/These.are.not.the.dirs.you.are.looking.for") should be fine. nathan
[BUILDROBOT] Selftest failed for i686-wrs-vxworks
Hi Nathan! The recent self-testing fails for i686-wrs-vxworks: /home/jbglaw/build-configlist_mk/i686-wrs-vxworks/build-gcc/mk/i686-wrs-vxworks/./gcc/xgcc -B/home/jbglaw/build-configlist_mk/i686-wrs-vxworks/build-gcc/mk/i686-wrs-vxworks/./gcc/ -xc -S -c /dev/null -fself-test xgcc: fatal error: environment variable ‘WIND_BASE’ not defined compilation terminated. Makefile:1877: recipe for target 's-selftest' failed make[2]: *** [s-selftest] Error 1 That's straight out of config-list.mk, see eg. build http://toolchain.lug-owl.de/buildbot/show_build_details.php?id=567929 I haven't given it any additional manual testing so far. It's pre-installation though. Maybe I'd just set WIND_BASE to some arbitrary value, just to make xgcc pass it's initial start-up test so that it can continue with self-testing? Or shall we set some value in gcc/Makefile.in for running the self-test? MfG, JBG -- Jan-Benedict Glaw jbg...@lug-owl.de +49-172-7608481 Signature of: 17:44 <@uschebit> Evangelist ist doch ein Vertriebler the second : für unverkäufliche Produkte, oder? (#korsett, 20120821) signature.asc Description: Digital signature