Undefined reference to GPM?


Alex777

Still Fresh
Joined
Sep 2, 2008
Messages
95
I'm trying to compile the newer version of Crawl, and I get the following strange link errors:



Code:
    LINK crawl

/usr/local/angstrom/arm/lib/gcc/arm-angstrom-linux-gnueabi/4.3.3/../../../../arm-angstrom-linux-gnueabi/bin/ld: skipping incompatible /usr/lib/libncursesw.a when searching for -lncursesw

/usr/local/angstrom/arm/lib/gcc/arm-angstrom-linux-gnueabi/4.3.3/../../../../arm-angstrom-linux-gnueabi/bin/ld: skipping incompatible /usr/lib/libm.a when searching for -lm

/usr/local/angstrom/arm/lib/gcc/arm-angstrom-linux-gnueabi/4.3.3/../../../../arm-angstrom-linux-gnueabi/bin/ld: skipping incompatible /usr/lib/libc.a when searching for -lc

/usr/local/angstrom/arm/lib/gcc/arm-angstrom-linux-gnueabi/4.3.3/../../../../arm-angstrom-linux-gnueabi/lib/libncursesw.a(lib_mouse.o): In function `enable_gpm_mouse':

(.text+0x664): undefined reference to `Gpm_Close'

/usr/local/angstrom/arm/lib/gcc/arm-angstrom-linux-gnueabi/4.3.3/../../../../arm-angstrom-linux-gnueabi/lib/libncursesw.a(lib_mouse.o): In function `enable_gpm_mouse':

(.text+0x6a8): undefined reference to `Gpm_Open'

/usr/local/angstrom/arm/lib/gcc/arm-angstrom-linux-gnueabi/4.3.3/../../../../arm-angstrom-linux-gnueabi/lib/libncursesw.a(lib_mouse.o): In function `initialize_mousetype':

(.text+0x87c): undefined reference to `gpm_fd'

/usr/local/angstrom/arm/lib/gcc/arm-angstrom-linux-gnueabi/4.3.3/../../../../arm-angstrom-linux-gnueabi/lib/libncursesw.a(lib_mouse.o): In function `mouse_activate':

(.text+0xa20): undefined reference to `gpm_fd'

/usr/local/angstrom/arm/lib/gcc/arm-angstrom-linux-gnueabi/4.3.3/../../../../arm-angstrom-linux-gnueabi/lib/libncursesw.a(lib_mouse.o): In function `_nc_mouse_event':

(.text+0xd78): undefined reference to `Gpm_GetEvent'

collect2: ld returned 1 exit status

make: *** [crawl] Error 1


Crawl doesn't even use the mouse, why is it complaining about it? It looks like libncursesw is trying to use it, but why?
 
I'm not sure but it looks like you are trying to cross compile using a cross compiler and the cross compiler is looking at the x86 libraries for some reason. What guide are you following?
 
and the cross compiler is looking at the x86 libraries for some reason
That ain't the problem, though. The linker discards those immediately and the libs it's complaining about are in the arm lib folder.
 
Last edited by a moderator:
I'm not sure but it looks like you are trying to cross compile using a cross compiler and the cross compiler is looking at the x86 libraries for some reason. What guide are you following?
I'm using Yactfeau. No guide, just the included instructions.


The funny thing is, 0.7.2 compiled fine.
 
and the cross compiler is looking at the x86 libraries for some reason
That ain't the problem, though. The linker discards those immediately and the libs it's complaining about are in the arm lib folder.
Good point - didn't see that.


Maybe try cross compiling and installing GPM in the ARM lib directories, as it doesn't seem to find the arm version of GPM. Maybe it's a dependancy in the newer version?
 
Back
Top