Make errors with 3DS examples (2 undefined references)...
Posted: Mon Jan 05, 2015 6:29 pm
Hello, I am attempting to build the 3DS examples included with libctru. I used the Windows installer to install devkitPro (1.5.4), then downloaded the latest zip from the libctru github, replaced the libctru directory contents in c:/devkitPro/ and copied the examples to c:/devkitPro/examples/3ds (following the lead of the other examples folders). When I run make (through cmd or through Programmer's Notepad), this is the output that I get:
> "make"
linking hello-world.elf
main.o: In function `main':
c:/devkitPro/examples/3ds/graphics/printing/hello-world/source/main.c:23: undefined reference to `gfxInitDefault'
c:/devkitPro/examples/3ds/graphics/printing/hello-world/source/main.c:27: undefined reference to `consoleInit'
collect2.exe: error: ld returned 1 exit status
make[1]: *** [/c/devkitPro/examples/3ds/graphics/printing/hello-world/hello-world.elf] Error 1
"make": *** [build] Error 2
> Process Exit Code: 2
> Time Taken: 00:01
That's running the Makefile inside of /examples/3ds/graphics/printing/hello-world/ but I get the same error on basically any Makefile I try to make in any of these examples.
The examples in the /nds/ directory work fine however, so I assume I have missed something somewhere, I'm just not sure what. I have just uninstalled and reinstalled devkitPro and have made no changes to the environment.
As a side note (and it hasn't gotten to this point yet), once I get this error sorted I want to compile .3dsx files since I'm using the Cubic Ninja exploit to run homebrew on my 3DSXL.
Thank you for your help and awesome toolchain. I have gone through the 12 pages of this forum and haven't seen this exact issue.
> "make"
linking hello-world.elf
main.o: In function `main':
c:/devkitPro/examples/3ds/graphics/printing/hello-world/source/main.c:23: undefined reference to `gfxInitDefault'
c:/devkitPro/examples/3ds/graphics/printing/hello-world/source/main.c:27: undefined reference to `consoleInit'
collect2.exe: error: ld returned 1 exit status
make[1]: *** [/c/devkitPro/examples/3ds/graphics/printing/hello-world/hello-world.elf] Error 1
"make": *** [build] Error 2
> Process Exit Code: 2
> Time Taken: 00:01
That's running the Makefile inside of /examples/3ds/graphics/printing/hello-world/ but I get the same error on basically any Makefile I try to make in any of these examples.
The examples in the /nds/ directory work fine however, so I assume I have missed something somewhere, I'm just not sure what. I have just uninstalled and reinstalled devkitPro and have made no changes to the environment.
As a side note (and it hasn't gotten to this point yet), once I get this error sorted I want to compile .3dsx files since I'm using the Cubic Ninja exploit to run homebrew on my 3DSXL.
Thank you for your help and awesome toolchain. I have gone through the 12 pages of this forum and haven't seen this exact issue.