Link Error (probably My Error)


gmiller1018

Member
Joined
Sep 21, 2006
Messages
336
Location
USA Florida
Website
Visit site
I have compiled a rather large project fro the first time with C++ on my windows box for the gp2x but I am getting an error diring the link that seems to point at a configuration error in my tool set up. Here is the error I am seeing:

Code:
Making all in sdl
make[2]: Entering directory `/home/gmiller/vbaSDL/src/sdl'
arm-linux-c++ -fno-exceptions -I/c/devkitPro/devkitGP2X/include/SDL -D_REENTRANT -I/c/devkitPro/devkitGP2X/include -DC_CORE -DPROFILING -DDEV_VERSION  -L/c/devkitPro/devkitGP2X/lib -o VisualBoyAdvance  SDL.o debugger.o 2xSaI.o Cheats.o EEprom.o Flash.o GBA.o Gfx.o Globals.o Mode0.o Mode1.o Mode2.o Mode3.o Mode4.o Mode5.o RTC.o Sound.o Sram.o Text.o Util.o admame.o agbprint.o armdis.o bilinear.o bios.o elf.o expr-lex.o expr.o exprNode.o getopt.o getopt1.o hq2x.o interframe.o memgzio.o motionblur.o pixel.o remote.o scanline.o simple2x.o unzip.o ../gb/libgb.a ../prof/libprof.a -L/c/devkitPro/devkitGP2X/lib -Wl,-rpath,/c/devkitPro/devkitGP2X/lib -lSDL -lpthread -lz  -L/c/devkitPro/devkitGP2X/lib -lpng12 -lz -lm  
c:\devkitpro\devkitgp2x\bin\..\lib\gcc\arm-linux\4.0.2\..\..\..\..\arm-linux\bin\ld.exe: cannot find /usr/lib/ inside c:\devkitpro\devkitgp2x\arm-linux\bin\../../sysroot
I have tried g++ and this try with c++ and the error is the same each time. I do have a folder in sysroot /usr/lib with a number of files in it. Has anyone see this before? I assume there is a setup problem since the compile works but the link process is fubar.

Here are the environment script I am using:
Code:
echo "Modifying environment for GP2X"

PATH=$DEVKITGP2X/arm-linux/bin:$DEVKITGP2X/bin:$PATH
export PATH


CC=arm-linux-gcc
CXX=arm-linux-g++

export CC CXX

LDFLAGS=-L$DEVKITGP2X/lib
export LDFLAGS

CFLAGS=-I$DEVKITGP2X/include
CPPFLAGS=-I$DEVKITGP2X/include
CXXFLAGS=-I$DEVKITGP2X/include

export CFLAGS CPPFLAGS CXXFLAGS

PKG_CONFIG_PATH=$DEVKITGP2X/lib/pkgconfig
export PKG_CONFIG_PATH

echo "enviornment Modified for GP2X..."
My autoconfig setup seems to work and the complete compile finishes with no warnings or errors so it point to configuration. Any thoughts?

BTW: My small C code project compile and link with no problems so this might be a c++ configuration/environment variable issue.
 
The most important part is:
cannot find /usr/lib/ inside c:\devkitpro\devkitgp2x\arm-linux\bin\../../sysroot

Looks like your library folder seems to be the wrong file path in the makefile.
 
yaustar posted on Sep 27 2006 at 08:25 AM said:
The most important part is:
cannot find /usr/lib/ inside c:\devkitpro\devkitgp2x\arm-linux\bin\../../sysroot

Looks like your library folder seems to be the wrong file path in the makefile.

Well using the relative path in the error message the folder is there and I do not specify this path in any of the setup so I assumed the tool was looking for it but "it's there". The dev kit is Octoate's GP2x toolchain (2006/03/06) so if there is an issue with it I guess I just need to know.
 
Last edited by a moderator:
Back
Top