app-emulation/bochs-2.3.6 fails to compile when linking libcpu.a The actual error is: x86_64-pc-linux-gnu-g++ -c -I.. -I./.. -I../instrument/stubs -I./../instrument/stubs -I. -I./. -march=core2 -O2 -pipe -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT symbols.cc -o symbols.o In file included from /usr/lib/gcc/x86_64-pc-linux-gnu/4.3.0/include/g++-v4/backward/hash_map:64, from symbols.cc:85: /usr/lib/gcc/x86_64-pc-linux-gnu/4.3.0/include/g++-v4/backward/backward_warning.h:32:2: warning: #warning This file includes at least one deprecated or antiquated header which may be removed without furthernotice at a future date. Please use a non-deprecated interface with equivalent functionality instead. For a listing of replacement headers and interfaces, consult the file backward_warning.h. To disable this warning use -Wno-deprecated. cd disasm && \ make libdisasm.a make[1]: Entering directory `/var/tmp/portage/app-emulation/bochs-2.3.6/work/bochs-2.3.6/disasm' x86_64-pc-linux-gnu-g++ -c -I.. -I./.. -I../instrument/stubs -I./../instrument/stubs -march=core2 -O2 -pipe -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT dis_decode.cc -o dis_decode.o x86_64-pc-linux-gnu-g++ -c -I.. -I./.. -I../instrument/stubs -I./../instrument/stubs -march=core2 -O2 -pipe -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT fetchdecode.cc -o fetchdecode.o dis_decode.cc: In member function ‘x86_insn disassembler::decode(bx_bool, bx_bool, bx_address, bx_address, const Bit8u*, char*)’: dis_decode.cc:285: warning: deprecated conversion from string constant to ‘char*’ dis_decode.cc:291: warning: deprecated conversion from string constant to ‘char*’ dis_decode.cc:323: warning: deprecated conversion from string constant to ‘char*’ dis_decode.cc:327: warning: deprecated conversion from string constant to ‘char*’ x86_64-pc-linux-gnu-g++ -c -I.. -I./.. -I../instrument/stubs -I./../instrument/stubs -march=core2 -O2 -pipe -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT slowdown_timer.cc -o slowdown_timer.o x86_64-pc-linux-gnu-g++ -c -I.. -I./.. -I../instrument/stubs -I./../instrument/stubs -march=core2 -O2 -pipe -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT ioapic.cc -o ioapic.o x86_64-pc-linux-gnu-g++ -c -I.. -I./.. -I../instrument/stubs -I./../instrument/stubs -march=core2 -O2 -pipe -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT dis_groups.cc -o dis_groups.o symbols.cc:137: error: ISO C++ forbids declaration of ‘hash_map’ with no type symbols.cc:137: error: expected ‘;’ before ‘<’ token symbols.cc:145: error: expected constructor, destructor, or type conversion before ‘<’ token symbols.cc: In constructor ‘context_t::context_t(Bit32u)’: symbols.cc:152: error: ‘map’ was not declared in this scope symbols.cc: In static member function ‘static context_t* context_t::get_context(Bit32u)’: symbols.cc:173: error: ‘map’ was not declared in this scope Reproducible: Always Actual Results: Fails to compile without patch...
Created attachment 150593 [details, diff] gcc 4.3 patch Red Hat patch, found on http://cvs.fedoraproject.org/viewcvs/devel/bochs/bochs-2.3.6-gcc43.patch?view=markup
Created attachment 150594 [details] updated ebuild
Created attachment 150595 [details] complete build log (before patch)
Perhaps someone would like to verify it works for them, so this can go into portage? :)
Does this still fail with 2.3.7 ?
Yes, it does - compiles with the same fix as before. This bug is pulled in by USE="debug". Last time I checked, upstream added a similar fix, to bx_debug/symbols.cc 98 #ifdef __GNUC__ 99 using namespace __gnu_cxx; 100 #endif The change is from yesterday (but I'm not so sure, I haven't checked CVS, I use a git mirror).
Link: http://bochs.cvs.sourceforge.net/bochs/bochs/bx_debug/symbols.cc?r1=1.11&r2=1.12
is this going to make it into portage any time soon? It seems to be a trivial patch.
The commit got lost somehow, committed for sure now.
(In reply to comment #9) > The commit got lost somehow, committed for sure now. > Patch fails to apply with: * Messages for package app-emulation/bochs-2.3.7: * Failed Patch: bochs-2.3.7-gcc43.patch ! * ( /usr/portage/app-emulation/bochs/files/bochs-2.3.7-gcc43.patch ) * * Include in your bugreport the contents of: * * /var/tmp/portage/app-emulation/bochs-2.3.7/temp/bochs-2.3.7-gcc43.patch-25272.out * * ERROR: app-emulation/bochs-2.3.7 failed. * Call stack: * ebuild.sh, line 49: Called src_unpack * environment, line 2668: Called epatch 'src_unpack' * environment, line 1603: Called die * The specific snippet of code: * die "Failed Patch: ${patchname}!"; * The die message: * Failed Patch: bochs-2.3.7-gcc43.patch! * * If you need support, post the topmost build error, and the call stack if relevant. * A complete build log is located at '/var/tmp/portage/app-emulation/bochs-2.3.7/temp/build.log'. * The ebuild environment file is located at '/var/tmp/portage/app-emulation/bochs-2.3.7/temp/environment'. *
It's missing the unified diff header (if you look at the error message log).
Created attachment 159428 [details, diff] fixed version of the patch making a minor change to the path specified in the patch makes it work. Please commit to portage, since the patch currently committed fails to apply.
+ 23 Jul 2008; Peter Alfredsen <loki_val@gentoo.org> + files/bochs-2.3.7-gcc43.patch: + Fix failing patch, bug #218888. +
*** Bug 228585 has been marked as a duplicate of this bug. ***