Ticket #1232 (closed bug: duplicate)
t/src/warnings.t: Test fails when Parrot built with g++ and --optimize
Reported by: | jkeenan | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | testing | Version: | 1.7.0 |
Severity: | medium | Keywords: | g++ optimize |
Cc: | Language: | ||
Patch status: | Platform: |
Description
Inspired by mikehh's testing adventures, I decided to try to configure and build Parrot on my Linux/i386 box using, for the first time, g++ for all options and optimized, i.e.:
perl Configure.pl --test --optimize --cc=g++ --cxx=g++ --link=g++ --ld=g++ --maintainer
I got one test failure which I would not (and did not) get when I simply configured on the same machine simply with:
perl Configure.pl --test
Here is the failing test:
$ prove -v t/src/warnings.t t/src/warnings.t .. 1..2 ok 1 - print_pbc_location # 'g++ -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -DHASATTRIBUTE_CONST -DHASATTRIBUTE_DEPRECATED -DHASATTRIBUTE_MALLOC -DHASATTRIBUTE_NONNULL -DHASATTRIBUTE_NORETURN -DHASATTRIBUTE_PURE -DHASATTRIBUTE_UNUSED -DHASATTRIBUTE_WARN_UNUSED_RESULT -falign-functions=16 -fvisibility=hidden -funit-at-a-time -maccumulate-outgoing-args -W -Wall -Waggregate-return -Wcast-align -Wcast-qual -Wchar-subscripts -Wcomment -Wdisabled-optimization -Wendif-labels -Wextra -Wformat -Wformat-extra-args -Wformat-nonliteral -Wformat-security -Wformat-y2k -Wimplicit -Wimport -Winit-self -Winline -Winvalid-pch -Wlogical-op -Wmissing-braces -Wmissing-field-initializers -Wno-missing-format-attribute -Wmissing-include-dirs -Wpacked -Wparentheses -Wpointer-arith -Wreturn-type -Wsequence-point -Wno-shadow -Wsign-compare -Wstrict-aliasing -Wstrict-aliasing=2 -Wswitch -Wswitch-default -Wtrigraphs -Wundef -Wunknown-pragmas -Wno-unused -Wvariadic-macros -Wwrite-strings -Wlarger-than-4096 -DDISABLE_GC_DEBUG=1 -DNDEBUG -O2 -DHAS_GETTEXT -I./include -c -o t/src/warnings_2.o t/src/warnings_2.c' failed with exit code 1 # Failed to build 't/src/warnings_2.o': t/src/warnings_2.c: In function 'int main(int, char**)': # t/src/warnings_2.c:14: error: invalid use of incomplete type 'struct Parrot_Context_attributes' # ./include/parrot/context.h:34: error: forward declaration of 'struct Parrot_Context_attributes' not ok 2 - Parrot_warn # Failed test 'Parrot_warn' # at t/src/warnings.t line 54. # Looks like you failed 1 test of 2. Dubious, test returned 1 (wstat 256, 0x100) Failed 1/2 subtests Test Summary Report ------------------- t/src/warnings.t (Wstat: 256 Tests: 2 Failed: 1) Failed test: 2 Non-zero exit status: 1 Files=1, Tests=2, 0 wallclock secs ( 0.04 usr 0.00 sys + 0.24 cusr 0.05 csys = 0.33 CPU) Result: FAIL
Change History
Note: See
TracTickets for help on using
tickets.