Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 218888

Summary: [gcc 4.3] app-emulation/bochs-2.3.7 fails to compile
Product: Gentoo Linux Reporter: Vladimir Lushnikov <vladimir>
Component: [OLD] GCC PortingAssignee: Luca Barbato <lu_zero>
Severity: normal CC: esigra, evan.teran, guido-genbugs
Priority: High    
Version: unspecified   
Hardware: AMD64   
OS: Linux   
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 198121    
Attachments: gcc 4.3 patch
updated ebuild
complete build log (before patch)
fixed version of the patch

Description Vladimir Lushnikov 2008-04-22 13:54:28 UTC
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 -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,
/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 -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 -o fetchdecode.o In member function ‘x86_insn disassembler::decode(bx_bool, bx_bool, bx_address, bx_address, const Bit8u*, char*)’: warning: deprecated conversion from string constant to ‘char*’ warning: deprecated conversion from string constant to ‘char*’ warning: deprecated conversion from string constant to ‘char*’ 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 -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 -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 -o dis_groups.o error: ISO C++ forbids declaration of ‘hash_map’ with no type error: expected ‘;’ before ‘<’ token error: expected constructor, destructor, or type conversion before ‘<’ token In constructor ‘context_t::context_t(Bit32u)’: error: ‘map’ was not declared in this scope In static member function ‘static context_t* context_t::get_context(Bit32u)’: error: ‘map’ was not declared in this scope

Reproducible: Always

Actual Results:  
Fails to compile without patch...
Comment 1 Vladimir Lushnikov 2008-04-22 13:55:58 UTC
Created attachment 150593 [details, diff]
gcc 4.3 patch

Red Hat patch, found on
Comment 2 Vladimir Lushnikov 2008-04-22 13:56:35 UTC
Created attachment 150594 [details]
updated ebuild
Comment 3 Vladimir Lushnikov 2008-04-22 13:57:53 UTC
Created attachment 150595 [details]
complete build log (before patch)
Comment 4 Vladimir Lushnikov 2008-05-20 11:47:02 UTC
Perhaps someone would like to verify it works for them, so this can go into portage? :)
Comment 5 Peter Alfredsen (RETIRED) gentoo-dev 2008-06-09 12:35:12 UTC
Does this still fail with 2.3.7 ?
Comment 6 Vladimir Lushnikov 2008-06-17 09:34:34 UTC
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/

  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).
Comment 8 Evan Teran 2008-07-01 04:06:24 UTC
is this going to make it into portage any time soon? It seems to be a trivial patch.
Comment 9 Luca Barbato gentoo-dev 2008-07-01 09:25:29 UTC
The commit got lost somehow, committed for sure now.
Comment 10 Evan Teran 2008-07-01 15:30:00 UTC
(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:
 *     , 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'.
Comment 11 Vladimir Lushnikov 2008-07-01 15:39:09 UTC
It's missing the unified diff header (if you look at the error message log).
Comment 12 Evan Teran 2008-07-03 15:23:20 UTC
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.
Comment 13 Peter Alfredsen (RETIRED) gentoo-dev 2008-07-23 12:36:48 UTC
+  23 Jul 2008; Peter Alfredsen <>
+  files/bochs-2.3.7-gcc43.patch:
+  Fix failing patch, bug #218888.
Comment 14 Christian Faulhammer (RETIRED) gentoo-dev 2008-11-04 18:31:13 UTC
*** Bug 228585 has been marked as a duplicate of this bug. ***