ChrisZim / edb-debugger

Automatically exported from code.google.com/p/edb-debugger
GNU General Public License v2.0
0 stars 0 forks source link

make fails during compilation #101

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hello,
I use Mac ports, qt4-mac 4.7.3, boost 1.47.0. When I try to run make after 
qmake, after a while I get this error:
/usr/bin/g++-4.2 -c -pipe -O2 -arch x86_64 -Xarch_x86_64 
-mmacosx-version-min=10.6 -Wall -W -fPIC -DEDB_PLUGIN -DQT_NO_DEBUG -DQT_PLUGIN 
-DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I/opt/local/share/qt4/mkspecs/macx-g++ 
-I. -I.moc/release-shared -I../../include -I../../include/os/unix 
-I../../include/os/unix/osx -I../../include/arch/x86_64 -Iunix -Iunix/osx 
-I/opt/local/include/QtGui -I/opt/local/include/QtCore -I/opt/local/include -o 
.obj/release-shared/PlatformState.o unix/osx/PlatformState.cpp
unix/osx/PlatformState.cpp: In member function ‘virtual Register 
PlatformState::value(const QString&) const’:
unix/osx/PlatformState.cpp:134: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:135: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:136: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:137: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:138: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:139: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:140: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:141: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:142: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:143: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:144: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:145: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:146: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:147: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:148: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:149: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:150: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:151: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:152: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:153: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:154: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:155: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:156: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:157: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:158: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:159: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:160: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:161: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:162: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:163: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:164: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:165: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:166: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:167: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:168: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:169: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:170: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:171: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:172: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:173: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:174: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:175: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:176: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:177: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:178: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:179: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:180: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:181: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:182: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:183: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:184: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:185: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:186: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:187: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:188: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:189: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:190: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:191: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:192: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:193: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:194: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:195: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:196: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:197: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:198: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:199: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:200: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:201: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:202: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:203: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:204: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:205: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:206: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp: In member function ‘virtual edb::address_t 
PlatformState::frame_pointer() const’:
unix/osx/PlatformState.cpp:220: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp: In member function ‘virtual edb::address_t 
PlatformState::instruction_pointer() const’:
unix/osx/PlatformState.cpp:232: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp: In member function ‘virtual edb::address_t 
PlatformState::stack_pointer() const’:
unix/osx/PlatformState.cpp:244: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp: In member function ‘virtual edb::reg_t 
PlatformState::debug_register(int) const’:
unix/osx/PlatformState.cpp:254: error: ‘const struct x86_debug_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:255: error: ‘const struct x86_debug_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:256: error: ‘const struct x86_debug_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:257: error: ‘const struct x86_debug_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:258: error: ‘const struct x86_debug_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:259: error: ‘const struct x86_debug_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:260: error: ‘const struct x86_debug_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp:261: error: ‘const struct x86_debug_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp: In member function ‘virtual edb::reg_t 
PlatformState::flags() const’:
unix/osx/PlatformState.cpp:274: error: ‘const struct x86_thread_state64_t’ 
has no member named ‘__x’
unix/osx/PlatformState.cpp: At global scope:
unix/osx/PlatformState.cpp:282: warning: unused parameter ‘n’
unix/osx/PlatformState.cpp: In member function ‘virtual void 
PlatformState::adjust_stack(int)’:
unix/osx/PlatformState.cpp:308: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp: In member function ‘virtual void 
PlatformState::set_debug_register(int, edb::reg_t)’:
unix/osx/PlatformState.cpp:329: error: ‘struct x86_debug_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:330: error: ‘struct x86_debug_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:331: error: ‘struct x86_debug_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:332: error: ‘struct x86_debug_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:333: error: ‘struct x86_debug_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:334: error: ‘struct x86_debug_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:335: error: ‘struct x86_debug_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:336: error: ‘struct x86_debug_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp: In member function ‘virtual void 
PlatformState::set_flags(edb::reg_t)’:
unix/osx/PlatformState.cpp:350: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp: In member function ‘virtual void 
PlatformState::set_instruction_pointer(edb::address_t)’:
unix/osx/PlatformState.cpp:362: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp: In member function ‘virtual void 
PlatformState::set_register(const QString&, edb::reg_t)’:
unix/osx/PlatformState.cpp:392: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:393: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:394: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:395: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:396: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:397: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:398: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:399: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:400: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:401: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:402: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:403: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:404: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:405: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:406: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:407: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:408: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:409: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:410: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:411: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
unix/osx/PlatformState.cpp:412: error: ‘struct x86_thread_state64_t’ has no 
member named ‘__x’
make[2]: *** [.obj/release-shared/PlatformState.o] Error 1
make[1]: *** [sub-DebuggerCore-make_default] Error 2
make: *** [sub-plugins-make_default-ordered] Error 2
I've tried to clean reinstall mac ports, qmake and boost, it did not helped.

Original issue reported on code.google.com by evan.teran on 3 Oct 2012 at 3:22

GoogleCodeExporter commented 9 years ago

Original comment by evan.teran on 3 Oct 2012 at 4:13

GoogleCodeExporter commented 9 years ago
It comes from improper token pasting.

This fixes the build for me. There may be other issues that come up with 
actually trying to use it on OS X, but at least this is a start.

diff --git a/plugins/DebuggerCore/unix/osx/PlatformState.cpp 
b/plugins/DebuggerCore/unix/osx/PlatformState.cpp
index d27bd63..efd6f79 100644
--- a/plugins/DebuggerCore/unix/osx/PlatformState.cpp
+++ b/plugins/DebuggerCore/unix/osx/PlatformState.cpp
@@ -18,7 +18,7 @@ along with this program.  If not, see 
<http://www.gnu.org/licenses/>.

 #include "PlatformState.h"
 #if __DARWIN_UNIX03
-#define REG(x) __x
+#define REG(x) __##x
 #else
 #define REG(x) x
 #endif

Original comment by j...@vt.edu on 15 Dec 2013 at 3:41

GoogleCodeExporter commented 9 years ago
Thanks for the comment/Fix. I've actually already applied that fix int he SVN. 
Please give the SVN trunk a try as it has much newer/improved code :-).

Thanks!

Original comment by evan.teran on 16 Dec 2013 at 4:31