Page 1 of 1

[Solved] Build wxFreeChart in Debian 8 64

Posted: Sun Mar 27, 2016 3:54 pm
by mrdebug
I'm trying to build wxFreeChart in Debian 8 64 bit but i obtain this error:
wxcode_gtk2u_freechart-3.1 -L/usr/lib/x86_64-linux-gnu -pthread -lwx_gtk2u_unofficial_core-3.1 -lwx_baseu_unofficial-3.1 -lwx_gtk2u_unofficial_aui-3.1
/usr/bin/ld: wxFreeChartDemo_dll_demo.o: undefined reference to symbol '_ZN17wxAboutDialogInfo10SetVersionERK8wxStringS2_@@WXU_UNOFFICIAL_3.1'
//usr/lib/x86_64-linux-gnu/libwx_gtk2u_unofficial_adv-3.1.so.0: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
Makefile:508: set di istruzioni per l'obiettivo "sample/wxFreeChartDemo_dll" non riuscito
make: *** [sample/wxFreeChartDemo_dll] Errore 1
denis@Tomcat:~/Cpp/wxTrazioni/freechart$
Anyone knows what it means?

Re: Build wxFreeChart in Debian 8 64

Posted: Sun Mar 27, 2016 6:57 pm
by DavidHart
Hi,

It means you're trying to build, against wx3.1, a program that expects wx2.8 ;) .

In wx3.1 wxAboutDialogInfo is in the 'adv' library, which wxFreeChart doesn't try to link to. If you hack the makefile and add
-lwx_gtk2u_adv-3.1
to the 'end of the line:

Code: Select all

WX_LIBS = -L/mnt/SanDisk128-common/david/devel/git/wx/udb/lib -pthread   -Wl,-rpath,/mnt/SanDisk128-common/david/devel/git/wx/udb/lib -lwx_gtk2u_core-3.1 -lwx_baseu-3.1 -lwx_gtk2u_aui-3.1
you'll find it builds OK.

Alternatively, install wx2.8.12 and build against that.

Regards,

David

Re: Build wxFreeChart in Debian 8 64

Posted: Mon Mar 28, 2016 8:37 am
by mrdebug
Solved by adding -lwx_gtk2u_unofficial_adv-3.1 to the key WX_LIBS