[Linux] [PCem v13.1] Compile errors

Support and general discussion.
Post Reply
User avatar
TheMechanist
Posts: 39
Joined: Mon 03 Apr, 2017 6:59 pm

[Linux] [PCem v13.1] Compile errors

Post by TheMechanist » Wed 17 Jan, 2018 7:55 pm

Hi folks,

just tried to compile PCem v13.1, getting a lot of errors regarding wxWidgets:
Example

Code: Select all

wx-app.h:57:29: error: invalid use of incomplete type ‘class wxCommandEvent’
 class CallbackEvent: public wxCommandEvent
                             ^
In file included from /usr/include/wx-3.0/wx/wx.h:24:0,
                 from wx-app.h:6,
                 from wx-main.cc:1:
/usr/include/wx-3.0/wx/event.h:632:28: note: forward declaration of ‘class wxCommandEvent’
 class WXDLLIMPEXP_FWD_CORE wxCommandEvent;
                            ^
In file included from wx-main.cc:1:0:
wx-app.h: In constructor ‘CallbackEvent::CallbackEvent(WX_CALLBACK, void*)’:
wx-app.h:60:59: error: type ‘wxCommandEvent’ is not a direct base of ‘CallbackEvent’
         CallbackEvent(WX_CALLBACK callback, void* data) : wxCommandEvent(WX_CAL
Using Ubuntu 16.04, installed libsdl2-dev, libwxbase3.0-dev & libopenal-dev from the repositories.

Any suggestions ?

Greetz

szadycbr
Posts: 215
Joined: Mon 21 Nov, 2016 6:23 pm

Re: [Linux] [PCem v13.1] Compile errors

Post by szadycbr » Wed 17 Jan, 2018 9:37 pm

Hard to tell, i am not a programmer nor any specialist, but i never install libwxbase.3.0-dev but as instructed by bit, in his original Linux GUI discussion post i do the line :
sudo apt install libwxgtk3.0-dev libsdl2-dev libopenal-dev , and from my Stretch repos i get all dependiecies automatically wchich is 28.1 Mb of archives and 98.2 after unpacked and installed.
Just try libwxgtk3.0-dev and all dependiencies like libwxbase3.0-dev should be installed automatically.
just now i put new build env. on fresh linux install, and add cpp, make , g++ ,gcc with above line and it compiled without any errors, straight from src. by make -f Makefile.linux64-wx-sdl2. but as Sarah often do remind us, it is good to run ./configure every now and then if something is wrong, then You can see what is wrong.
Hope it helps. :)

JosepMa
Posts: 92
Joined: Tue 20 Jun, 2017 6:25 pm

Re: [Linux] [PCem v13.1] Compile errors

Post by JosepMa » Thu 18 Jan, 2018 7:34 pm

@TheMechanist: try running autoreconf -i first if ./configure isn't enough

szadycbr
Posts: 215
Joined: Mon 21 Nov, 2016 6:23 pm

Re: [Linux] [PCem v13.1] Compile errors

Post by szadycbr » Thu 18 Jan, 2018 11:03 pm

Autoreconf is good too, but i did'nt know that there is such a command, untill Sarah pointed me to it, and i did'nt know that it is a program, which is installed from synaptic on debian stretch.

User avatar
TheMechanist
Posts: 39
Joined: Mon 03 Apr, 2017 6:59 pm

Re: [Linux] [PCem v13.1] Compile errors

Post by TheMechanist » Fri 19 Jan, 2018 5:47 am

Solved it, libwxbase is not enough, had to install libwxgtk too, now it compiled like charm ! But ./configure --release-build didn't complain about missing libwxgtk, so I had no hint first ...

szadycbr
Posts: 215
Joined: Mon 21 Nov, 2016 6:23 pm

Re: [Linux] [PCem v13.1] Compile errors

Post by szadycbr » Fri 19 Jan, 2018 7:52 am

Yep, You right , ./configure does not shown that there is something wrong with wx libraries, i thought it would ,but no :(

spiderman82
Posts: 1
Joined: Wed 31 Aug, 2016 9:15 am

Re: [Linux] [PCem v13.1] Compile errors

Post by spiderman82 » Sun 28 Jan, 2018 10:05 pm

about compilation errors:
when running the /.configure command

Code: Select all

You need to install the OpenAL library
but I have it!!!
Ubuntu 16.04 xenial
x86_64 Linux 4.4.0-112-generic
to compile using the terminal, what am I doing wrong

szadycbr
Posts: 215
Joined: Mon 21 Nov, 2016 6:23 pm

Re: [Linux] [PCem v13.1] Compile errors

Post by szadycbr » Tue 06 Feb, 2018 1:36 pm

now i have strange compiling error, and i have no clue what is happening.

Code: Select all

0 -lwx_gtk2u_html-3.0 -lwx_gtk2u_qa-3.0 -lwx_gtk2u_adv-3.0 -lwx_gtk2u_core-3.0 -
lwx_baseu_xml-3.0 -lwx_baseu_net-3.0 -lwx_baseu-3.0  -lSDL2
pcem-cdrom-image.o: In function `image_open':
/home/szady/Documents/pcem/src/cdrom-image.cc:519: undefined reference to `atapi
'
pcem-cdrom-null.o: In function `cdrom_null_open':
/home/szady/Documents/pcem/src/cdrom-null.c:102: undefined reference to `atapi'
pcem-ide.o: In function `resetide':
/home/szady/Documents/pcem/src/ide.c:282: undefined reference to `scsi_zip'
pcem-ide.o: In function `writeidew':
/home/szady/Documents/pcem/src/ide.c:312: undefined reference to `atapi_data_wri
te'
pcem-ide.o: In function `writeide':
/home/szady/Documents/pcem/src/ide.c:593: undefined reference to `atapi_command_
start'
pcem-ide.o: In function `readide':
/home/szady/Documents/pcem/src/ide.c:675: undefined reference to `atapi_read_iir
'
/home/szady/Documents/pcem/src/ide.c:712: undefined reference to `atapi_read_drq
'
/home/szady/Documents/pcem/src/ide.c:741: undefined reference to `atapi_read_drq
'
pcem-ide.o: In function `readidew':
/home/szady/Documents/pcem/src/ide.c:775: undefined reference to `atapi_data_rea
d'
pcem-ide.o: In function `callbackide':
/home/szady/Documents/pcem/src/ide.c:846: undefined reference to `atapi'
/home/szady/Documents/pcem/src/ide.c:851: undefined reference to `atapi'
/home/szady/Documents/pcem/src/ide.c:856: undefined reference to `atapi'
/home/szady/Documents/pcem/src/ide.c:861: undefined reference to `atapi'
/home/szady/Documents/pcem/src/ide.c:1175: undefined reference to `atapi_process
_packet'
pcem-keyboard_xt.o: In function `keyboard_xt_adddata':
/home/szady/Documents/pcem/src/keyboard_xt.c:65: undefined reference to `t1000_s
yskey'
/home/szady/Documents/pcem/src/keyboard_xt.c:69: undefined reference to `t1000_s
yskey'
/home/szady/Documents/pcem/src/keyboard_xt.c:71: undefined reference to `t1000_s
yskey'
/home/szady/Documents/pcem/src/keyboard_xt.c:73: undefined reference to `t1000_s
yskey'
/home/szady/Documents/pcem/src/keyboard_xt.c:75: undefined reference to `t1000_s
yskey'
pcem-keyboard_xt.o:/home/szady/Documents/pcem/src/keyboard_xt.c:77: more undefin
ed references to `t1000_syskey' follow
pcem-model.o:(.data.rel+0x948): undefined reference to `xt_t1000_init'
pcem-model.o:(.data.rel+0x950): undefined reference to `t1000_device'
pcem-model.o:(.data.rel+0xfc0): undefined reference to `xt_t1200_init'
pcem-model.o:(.data.rel+0xfc8): undefined reference to `t1000_device'
pcem-nvr.o: In function `loadnvr':
/home/szady/Documents/pcem/src/nvr.c:291: undefined reference to `tc8521_loadnvr
'
/home/szady/Documents/pcem/src/nvr.c:292: undefined reference to `t1000_configsy
s_loadnvr'
/home/szady/Documents/pcem/src/nvr.c:293: undefined reference to `t1000_emsboard
_loadnvr'
/home/szady/Documents/pcem/src/nvr.c:295: undefined reference to `tc8521_loadnvr
'
/home/szady/Documents/pcem/src/nvr.c:296: undefined reference to `t1000_emsboard
_loadnvr'
pcem-nvr.o: In function `savenvr':
/home/szady/Documents/pcem/src/nvr.c:371: undefined reference to `tc8521_savenvr
'
/home/szady/Documents/pcem/src/nvr.c:372: undefined reference to `t1000_configsy
s_savenvr'
/home/szady/Documents/pcem/src/nvr.c:373: undefined reference to `t1000_emsboard
_savenvr'
/home/szady/Documents/pcem/src/nvr.c:375: undefined reference to `tc8521_savenvr
'
/home/szady/Documents/pcem/src/nvr.c:376: undefined reference to `t1000_emsboard
_savenvr'
pcem-pc.o: In function `closepc':
/home/szady/Documents/pcem/src/pc.c:600: undefined reference to `atapi'
/home/szady/Documents/pcem/src/pc.c:613: undefined reference to `zip_eject'
pcem-scsi.o: In function `scsi_bus_init':
/home/szady/Documents/pcem/src/scsi.c:351: undefined reference to `scsi_zip'
pcem-scsi_cd.o: In function `atapi_event_status':
/home/szady/Documents/pcem/src/scsi_cd.c:229: undefined reference to `atapi'
/home/szady/Documents/pcem/src/scsi_cd.c:242: undefined reference to `atapi'
/home/szady/Documents/pcem/src/scsi_cd.c:247: undefined reference to `atapi'
pcem-scsi_cd.o: In function `scsi_cd_command':
/home/szady/Documents/pcem/src/scsi_cd.c:446: undefined reference to `atapi'
/home/szady/Documents/pcem/src/scsi_cd.c:474: undefined reference to `atapi'
pcem-scsi_cd.o:/home/szady/Documents/pcem/src/scsi_cd.c:487: more undefined refe
rences to `atapi' follow
pcem-video.o: In function `video_init':
/home/szady/Documents/pcem/src/video.c:446: undefined reference to `t1000_device
'
pcem-wx-sdl2.o: In function `wx_handle_command':
/home/szady/Documents/pcem/src/wx-sdl2.c:863: undefined reference to `createdisc                                                                                        image_open'
/home/szady/Documents/pcem/src/wx-sdl2.c:873: undefined reference to `zip_load'
/home/szady/Documents/pcem/src/wx-sdl2.c:878: undefined reference to `zip_eject'
/home/szady/Documents/pcem/src/wx-sdl2.c:1077: undefined reference to `atapi'
/home/szady/Documents/pcem/src/wx-sdl2.c:1109: undefined reference to `atapi'
/home/szady/Documents/pcem/src/wx-sdl2.c:1150: undefined reference to `atapi'
/home/szady/Documents/pcem/src/wx-sdl2.c:1186: undefined reference to `atapi'
pcem-wx-sdl2-status.o: In function `get_machine_info':
/home/szady/Documents/pcem/src/wx-sdl2-status.c:87: undefined reference to `zip_                                                                                        loaded'
pcem-cdrom-ioctl-linux.o: In function `ioctl_set_drive':
/home/szady/Documents/pcem/src/cdrom-ioctl-linux.c:673: undefined reference to `                                                                                        atapi'
pcem-cdrom-ioctl-linux.o: In function `ioctl_open':
/home/szady/Documents/pcem/src/cdrom-ioctl-linux.c:679: undefined reference to `                                                                                        atapi'
collect2: error: ld returned 1 exit status
Makefile:632: recipe for target 'pcem' failed
make[1]: *** [pcem] Error 1
make[1]: Leaving directory '/home/szady/Documents/pcem/src'
Makefile:365: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1
szady@fiut:~/Documents/pcem$



strange, i hope problem is on my side :)
Edit: it compiles fine when straight from src. by make -f Makefile.linux64-wx-sdl2 , but it make above errors when building by ./configure --enable-debug , make.

User avatar
SarahWalker
Site Admin
Posts: 1427
Joined: Thu 24 Apr, 2014 4:18 pm

Re: [Linux] [PCem v13.1] Compile errors

Post by SarahWalker » Tue 06 Feb, 2018 6:15 pm

Run autoreconf.

szadycbr
Posts: 215
Joined: Mon 21 Nov, 2016 6:23 pm

Re: [Linux] [PCem v13.1] Compile errors

Post by szadycbr » Tue 06 Feb, 2018 8:41 pm

Thanks, i forgot again, buahh :(
Edit: it compiled fine now, but now i got "segmantation fault" upon launching binary in linux command line.

Post Reply