stonewell / madedit-pv

Automatically exported from code.google.com/p/madedit-pv
1 stars 0 forks source link

compile code error on ubuntu 13.10 64bit #9

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
while I build the souce code, get the error 

src/MadEdit/MadEdit.cpp: In function ‘int wxChCmp(const wchar_t*, const 
wxString&)’:
src/MadEdit/MadEdit.cpp:588:50: error: request for member ‘data’ in ‘(& 
wsStr)->wxString::wc_str()’, which is of non-class type ‘const wxChar* {aka 
const wchar_t*}’
     const wchar_t * wchTmpStr = (wsStr.wc_str()).data();
                                                  ^
src/MadEdit/MadEdit.cpp: In constructor ‘MadEdit::MadEdit(wxWindow*, 
wxWindowID, const wxPoint&, const wxSize&, long int)’:
src/MadEdit/MadEdit.cpp:902:17: warning: overflow in implicit constant 
conversion [-Woverflow]
     m_HexTopRow = size_t(-1);
                 ^
make[2]: *** [madedit-MadEdit.o] Error 1
make[2]: Leaving directory `/home/dhousy/Downloads/madedit-pv-read-only'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/dhousy/Downloads/madedit-pv-read-only'
make: *** [all] Error 2

Original issue reported on code.google.com by housy....@gmail.com on 21 Oct 2013 at 4:02

GoogleCodeExporter commented 9 years ago
sorry, your patch in issue 7 seems works

Original comment by housy....@gmail.com on 21 Oct 2013 at 6:35

GoogleCodeExporter commented 9 years ago
but still get new errors during build

/usr/bin/ld: madedit-MadEdit_gtk.o: undefined reference to symbol 
'XKeycodeToKeysym'
/usr/lib/x86_64-linux-gnu/libX11.so.6: error adding symbols: DSO missing from 
command line
collect2: error: ld returned 1 exit status

Would you please check why?
Thanks a lot

Original comment by housy....@gmail.com on 21 Oct 2013 at 6:37

GoogleCodeExporter commented 9 years ago
Add X11 to library path.

LDFLAGS=-lX11" _may_ fix your problem.

However, someone said this function 'XKeycodeToKeysym' is deprecated. I'll 
figure it out if I had time 

Original comment by minggang...@gmail.com on 21 Oct 2013 at 8:54

GoogleCodeExporter commented 9 years ago
madedit-MadSearchDialog.o: In function 
`MadSearchDialog::WxButtonFindAllClick(wxCommandEvent&)':
/home/dhousy/Downloads/madedit-pv-read-only/src/MadSearchDialog.cpp:844: 
undefined reference to `wxAuiManager::GetPane(wxWindow*)'
/home/dhousy/Downloads/madedit-pv-read-only/src/MadSearchDialog.cpp:845: 
undefined reference to `wxAuiManager::Update()'
/home/dhousy/Downloads/madedit-pv-read-only/src/MadSearchDialog.cpp:882: 
undefined reference to `wxAuiNotebook::GetPageIndex(wxWindow*) const'
/home/dhousy/Downloads/madedit-pv-read-only/src/MadSearchDialog.cpp:885: 
undefined reference to `wxAuiNotebook::GetPageText(unsigned long) const'
collect2: error: ld returned 1 exit status
make[2]: *** [madedit] Error 1
make[2]: Leaving directory `/home/dhousy/Downloads/madedit-pv-read-only'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/dhousy/Downloads/madedit-pv-read-only'
make: *** [all] Error 2

Original comment by housy....@gmail.com on 22 Oct 2013 at 1:40

Attachments:

GoogleCodeExporter commented 9 years ago
sorry, seems got another build error, please see the error.log

Original comment by housy....@gmail.com on 22 Oct 2013 at 1:47

GoogleCodeExporter commented 9 years ago
Not sure if it would help you:

in the wx-config call, replace --libs with --libs core, base, aui

aui is not included in the default set so you must request it

Original comment by minggang...@gmail.com on 22 Oct 2013 at 2:16

GoogleCodeExporter commented 9 years ago
thank you, can you explain more about "replace  --libs with --libs core, base, 
aui" ? shall I make changes on Makefile ?

Thank you so much

Original comment by housy....@gmail.com on 22 Oct 2013 at 2:30

GoogleCodeExporter commented 9 years ago
this time I got another error

/usr/bin/ld: madedit-clipbrd_gtk.o: undefined reference to symbol 
'gtk_main_iteration'
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0: error adding symbols: DSO 
missing from command line
collect2: error: ld returned 1 exit status
make[2]: *** [madedit] Error 1

Original comment by housy....@gmail.com on 22 Oct 2013 at 3:05

GoogleCodeExporter commented 9 years ago
I quoted the answer for the same error. 

http://us.generation-nt.com/answer/help-new-version-xmedcon-help-212176332.html

 This error tells that ld misses gtk from the linker command line.
 Luckily, the configure script already uses the pkg-config autotools
 macro to find the correct libs (Check for PKG_CHECK_MODULES(XMEDCON_GTK
 in configure.ac), so it's just a matter of adding them to the linker
 command:

 xmedcon-0.13.0.orig/source/Makefile.am 2013-08-18
 08:17:41.000000000 +0000
 +++ xmedcon-0.13.0/source/Makefile.am 2013-08-18 08:20:04.222504575 +0000
 @@ -91,7 +91,7 @@
 xmedcon_LDADD = $(APPICON_OBJ) libmdc.la
 xmedcon_LDFLAGS = -mwindows $(GDK_PIXBUF_LIBS) -lm
 else
 -xmedcon_LDADD = libmdc.la
 +xmedcon_LDADD = libmdc.la $(XMEDCON_GTK_LIBS)
 xmedcon_LDFLAGS = $(GDK_PIXBUF_LIBS) -lm
 endif

 Cheers,
 Andreas 

Original comment by minggang...@gmail.com on 22 Oct 2013 at 4:04

GoogleCodeExporter commented 9 years ago
wx-config call, replace --libs with --libs core, base, aui

This is the command line to compile wxWidgets which madedit depends on.

Original comment by minggang...@gmail.com on 22 Oct 2013 at 4:05