Homebrew Homebrew Development

daxtsu

Well-Known Member
Member
Joined
Jun 9, 2007
Messages
5,627
Trophies
2
XP
5,194
Country
Antarctica
Hey can someone please help me out, I am trying to compile ninjhax2.x but i keep getting this error.
Code:
Makefile:6: *** "Please set CTRULIB in your environment. export DEVKITARM=<path to>ctrulib/libctru".  Stop.
Currently I am running Linux Mint17.1(ubuntu 14.04) i have devpro setup and its working(compiled reinand fine). I tried placing the ctrulib in the devpro directory and setting the path but it still wont work.
Anyone know how to fix this ?

If you want to do it the cheating way, edit the makefile and remove lines 5-7: https://github.com/smealum/ninjhax2.x/blob/master/Makefile#L5-L7

Otherwise, set/export the CTRULIB variable to just inside the ctrulib folder (so it'll see the include/lib folders). In my case it's something like C:\devkitPro\libctru\. In there is the include folder and the lib folder.
 

suhaib10

Active Member
Newcomer
Joined
Jan 15, 2016
Messages
32
Trophies
0
XP
60
Country
Canada
If you want to do it the cheating way, edit the makefile and remove lines 5-7: https://github.com/smealum/ninjhax2.x/blob/master/Makefile#L5-L7

Otherwise, set/export the CTRULIB variable to just inside the ctrulib folder (so it'll see the include/lib folders). In my case it's something like C:\devkitPro\libctru\. In there is the include folder and the lib folder.
Ok so i have libctru in my devkitpro folder I tried Exporting CTRULIB to it but same error, just a bit confused do i export CTRULIB or DEVKITARM since th error says to export that.

About the cheat way wont that break certain things??
 
Last edited by suhaib10,

suhaib10

Active Member
Newcomer
Joined
Jan 15, 2016
Messages
32
Trophies
0
XP
60
Country
Canada
As long as your ctrulib folder is indeed in the devkitPro folder, then it should be fine.

Well tried it by removing the requirement line in make got this:
Code:
make[1]: Entering directory `/home/suhaib10/Downloads/ninjhax2.x/firm_constants'
make[2]: Entering directory `/home/suhaib10'
make[2]: *** No targets specified and no makefile found.  Stop.
make[2]: Leaving directory `/home/suhaib10'
make[1]: *** [constants.txt] Error 2
make[1]: Leaving directory `/home/suhaib10/Downloads/ninjhax2.x/firm_constants'
make: *** [firm_constants/constants.txt] Error 2

P.S. Also when i try 'make clean' get a bunch of the same errors about CTRULIB, the checks are there in all make files in sub folders, so i guess ill try looking around to make ctrulib work. ALso could it be an issue with ctrulib 1.1.0 maybe i should try using an older version.
 
Last edited by suhaib10,

omikes

Well-Known Member
Newcomer
Joined
Oct 29, 2015
Messages
86
Trophies
0
Age
38
XP
121
Country
United States
I am stuck at the very beginning of a project. I had high expectations for it, I wanted both images and text. I have installed freetype-2.5.4 on Mac, Windows, and Linux, linked -lfreetype, but when I compile I always get this result:

Code:
C:\mingw\msys\1.0\bin\make.exe -f Makefile
linking sf2d_sample.elf
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `ftc_face_requester':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:44: undefined reference to `FT_New_Face'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:50: undefined reference to `FT_New_Memory_Face'
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `sftd_init':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:64: undefined reference to `FT_Init_FreeType'
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `sftd_fini':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:77: undefined reference to `FT_Done_FreeType'
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `sftd_load_font_file':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:100: undefined reference to `FTC_Manager_New'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:115: undefined reference to `FTC_CMapCache_New'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:116: undefined reference to `FTC_ImageCache_New'
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `sftd_load_font_mem':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:136: undefined reference to `FTC_Manager_New'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:150: undefined reference to `FTC_CMapCache_New'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:151: undefined reference to `FTC_ImageCache_New'
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `sftd_free_font':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:164: undefined reference to `FTC_Manager_RemoveFaceID'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:165: undefined reference to `FTC_Manager_Done'
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `sftd_draw_text':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:210: undefined reference to `FTC_Manager_LookupFace'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:213: undefined reference to `FT_Get_Charmap_Index'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:230: undefined reference to `FTC_CMapCache_Lookup'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:239: undefined reference to `FTC_ImageCache_LookupScaler'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:234: undefined reference to `FT_Get_Kerning'
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `sftd_draw_wtext':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:287: undefined reference to `FTC_Manager_LookupFace'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:290: undefined reference to `FT_Get_Charmap_Index'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:307: undefined reference to `FTC_CMapCache_Lookup'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:316: undefined reference to `FTC_ImageCache_LookupScaler'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:311: undefined reference to `FT_Get_Kerning'
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `sftd_get_text_width':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:364: undefined reference to `FTC_Manager_LookupFace'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:367: undefined reference to `FT_Get_Charmap_Index'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:384: undefined reference to `FTC_CMapCache_Lookup'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:393: undefined reference to `FTC_ImageCache_LookupScaler'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:388: undefined reference to `FT_Get_Kerning'
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `sftd_draw_text_wrap':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:424: undefined reference to `FTC_Manager_LookupFace'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:427: undefined reference to `FT_Get_Charmap_Index'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:475: undefined reference to `FTC_ImageCache_LookupScaler'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:463: undefined reference to `FTC_CMapCache_Lookup'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:470: undefined reference to `FT_Get_Kerning'
c:/Users/michael.oriley/Desktop/ctrulib-master/sample/../libsftd/lib\libsftd.a(sftd.o): In function `sftd_calc_bounding_box':
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:517: undefined reference to `FTC_Manager_LookupFace'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:520: undefined reference to `FT_Get_Charmap_Index'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:572: undefined reference to `FTC_ImageCache_LookupScaler'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:560: undefined reference to `FTC_CMapCache_Lookup'
c:/Users/michael.oriley/Desktop/ctrulib-master/libsftd/source/sftd.c:567: undefined reference to `FT_Get_Kerning'
collect2.exe: error: ld returned 1 exit status
make.exe[1]: *** [/c/Users/michael.oriley/Desktop/ctrulib-master/sample/sf2d_sample.elf] Error 1
make.exe": *** [build] Error 2

BUILD FAILED (exit value 2, total time: 3s)

It implies, from what I can gather on Google, that freetype is not being linked correctly. I have tried moving the link order around, downloading various libfreetype.a files from online, even compiled freetype on three different OSes as mentioned before... this is all I get. Has anyone run into a similar issue?
 

JJTapia19

I fight for my friends.
Member
Joined
May 31, 2015
Messages
2,171
Trophies
1
Age
32
XP
2,438
Country
Puerto Rico
Ok I finally give up trying to fix this for myself. I've spent hours and I'm still stuck in the same place. Right now I'm trying to set up a development environment I'm trying to install the portlibs but I'm always getting this error trying to install zlib

Code:
arm-none-eabi-gcc -march=armv6k -mtune=mpcore -mfloat-abi=hard -O3 -mword-relocations  -DHAVE_HIDDEN -I/c/devkitPro/portlibs/armv6k/include  -c -o gzread.o gzread.c
arm-none-eabi-gcc -march=armv6k -mtune=mpcore -mfloat-abi=hard -O3 -mword-relocations  -DHAVE_HIDDEN -I/c/devkitPro/portlibs/armv6k/include  -c -o gzwrite.o gzwrite.c
arm-none-eabi-ar rc libz.a adler32.o crc32.o deflate.o infback.o inffast.o inflate.o inftrees.o trees.o zutil.o compress.o uncompr.o gzclose.o gzlib.o gzread.o gzwrite.o
arm-none-eabi-gcc -march=armv6k -mtune=mpcore -mfloat-abi=hard -O3 -mword-relocations  -DHAVE_HIDDEN -o example example.o -L. libz.a
c:/devkitpro/devkitarm/bin/../lib/gcc/arm-none-eabi/5.3.0/../../../../arm-none-eabi/bin/ld.exe: warning: cannot find entry symbol _start; defaulting to 00008020
arm-none-eabi-gcc -march=armv6k -mtune=mpcore -mfloat-abi=hard -O3 -mword-relocations  -DHAVE_HIDDEN -I. -c -o minigzip.o test/minigzip.c
arm-none-eabi-gcc -march=armv6k -mtune=mpcore -mfloat-abi=hard -O3 -mword-relocations  -DHAVE_HIDDEN -o minigzip minigzip.o -L. libz.a
c:/devkitpro/devkitarm/bin/../lib/gcc/arm-none-eabi/5.3.0/../../../../arm-none-eabi/bin/ld.exe: warning: cannot find entry symbol _start; defaulting to 00008020
make[1]: Leaving directory `/c/devkitPro/portlibs/zlib-1.2.8'

This is getting really frustrating. I want to learn and figure out stuff by myself but I have no idea on what to do and maybe it's just something simple to fix. I only find troubleshooting about that error for other operating systems but I'm on windows 10. Any help will be greatly appreciated.
 
Last edited by JJTapia19,

Slashcash

Well-Known Member
Member
Joined
Oct 15, 2015
Messages
338
Trophies
0
XP
611
Country
Italy
Ok I finally give up trying to fix this for myself. I've spent hours and I'm still stuck in the same place. Right now I'm trying to set up a development environment I'm trying to install the portlibs but I'm always getting this error trying to install zlib

I would suggest to use the precompiled version of the portlibs, they are available here: https://github.com/xerpi/3ds_portlibs/releases

If you are on Windows just grab the correct file and unzip it as is in C:\devkitpro

Once you've placed the files in the folder you can just compile sftd with make and then make install
 
Last edited by Slashcash,

JJTapia19

I fight for my friends.
Member
Joined
May 31, 2015
Messages
2,171
Trophies
1
Age
32
XP
2,438
Country
Puerto Rico
I would suggest to use the precompiled version of the portlibs, they are available here: https://github.com/xerpi/3ds_portlibs/releases

If you are on Windows just grab the correct file and unzip it as is in C:\devkitpro

Once you've placed the files in the folder you can just compile sftd with make and then make install
That worked perfectly. I compiled the original homebrew launcher to test. Thanks a lot for helping me! I had no idea a precompiled version was available. :yay:
 

omikes

Well-Known Member
Newcomer
Joined
Oct 29, 2015
Messages
86
Trophies
0
Age
38
XP
121
Country
United States
I would suggest to use the precompiled version of the portlibs, they are available here: https://github.com/xerpi/3ds_portlibs/releases

If you are on Windows just grab the correct file and unzip it as is in C:\devkitpro

Once you've placed the files in the folder you can just compile sftd with make and then make install

build successful... i haven't seen those words in THREE DAYS. thank you! and good luck with your project, let me know if you need an API if you decide to take it online.
 

Slashcash

Well-Known Member
Member
Joined
Oct 15, 2015
Messages
338
Trophies
0
XP
611
Country
Italy
build successful... i haven't seen those words in THREE DAYS. thank you! and good luck with your project, let me know if you need an API if you decide to take it online.

The plan is to take it online as soon as i finish adding those two or three features missing! I will surely ask for help.
 
D

Deleted User

Guest
Just a quick question; what's the difference between a system applet and a library applet?
 

daxtsu

Well-Known Member
Member
Joined
Jun 9, 2007
Messages
5,627
Trophies
2
XP
5,194
Country
Antarctica
Just a quick question; what's the difference between a system applet and a library applet?

System applets are things like the friends list, the internet browser, and notes. Library applets are things like the parental controls PIN keypad, and the software keyboard that you typically get when entering names in games, or URLs in the browser.
 
  • Like
Reactions: Deleted User
D

Deleted User

Guest
System applets are things like the friends list, the internet browser, and notes. Library applets are things like the parental controls PIN keypad, and the software keyboard that you typically get when entering names in games, or URLs in the browser.
Thanks. I'm now trying to see if I can get the software keyboard to function (obviously in a CIA build). I noticed stuff here, which is giving me a rough time again:
Code:
/**
 * @brief Prepares to start a library applet.
 * @param appID ID of the applet to start.
 */
Result APT_PrepareToStartLibraryApplet(NS_APPID appID);

/**
 * @brief Starts a library applet.
 * @param appID ID of the applet to launch.
 * @param inhandle Handle to pass to the applet.
 * @param parambuf Buffer containing applet parameters.
 * @param parambufsize Size of parambuf.
 */
Result APT_StartLibraryApplet(NS_APPID appID, Handle inhandle, u32 *parambuf, u32 parambufsize);

/**
 * @brief Launches a library applet.
 * Note: This is not usable from the homebrew launcher. This is broken: when the applet does get launched at all, the applet process doesn't actually get terminated when the applet gets closed.
 * @param appID ID of the applet to launch.
 * @param inhandle Handle to pass to the applet.
 * @param parambuf Buffer containing applet parameters.
 * @param parambufsize Size of parambuf.
 */
Result APT_LaunchLibraryApplet(NS_APPID appID, Handle inhandle, u32 *parambuf, u32 parambufsize);
 

daxtsu

Well-Known Member
Member
Joined
Jun 9, 2007
Messages
5,627
Trophies
2
XP
5,194
Country
Antarctica
Thanks. I'm now trying to see if I can get the software keyboard to function (obviously in a CIA build). I noticed stuff here, which is giving me a rough time again:

I don't think you'll be able to; the software keyboard requires a huge block of data that nobody's seemed to reverse engineer yet. That, and I think the comment is still true about it being broken when launching library applets (even from CIAs).
 
D

Deleted User

Guest
That, and I think the comment is still true about it being broken when launching library applets (even from CIAs).
I thought that disclaimer only applied to homebrew builds though. :blink:

anyhow, it looks as if I'm having to make my own keyboard layout, if that's the case.

--------------------- MERGED ---------------------------

Also, what's this?
Code:
APPID_SOFTWARE_KEYBOARD = 0x401
I saw this in a typedef enum.
 

daxtsu

Well-Known Member
Member
Joined
Jun 9, 2007
Messages
5,627
Trophies
2
XP
5,194
Country
Antarctica
I thought that disclaimer only applied to homebrew builds though. :blink:

anyhow, it looks as if I'm having to make my own keyboard layout, if that's the case.

I'm fairly sure it applies to both CIA and 3dsx; they've not really put a lot of priority into fixing it as far as I know. There are several homebrew keyboard libraries out there, so it shouldn't be too hard to find one that you might like.

Also, what's this?
Code:
APPID_SOFTWARE_KEYBOARD = 0x401
I saw this in a typedef enum.

That's just the ID number if you will, of the keyboard, so that the 3DS knows which applet to run.
 
D

Deleted User

Guest
Thanks. If I could somehow manage to build the 3DS SDK samples using the omake build system, then I could be able to use the software keyboard from there, since Nintendo made a keyboard example!
 
Last edited by ,

daxtsu

Well-Known Member
Member
Joined
Jun 9, 2007
Messages
5,627
Trophies
2
XP
5,194
Country
Antarctica
Thanks. If I could somehow manage to build the 3DS SDK samples using the omake build system, then I could be able to use the software keyboard from there, since Nintendo made a keyboard example!

Probably, but you wouldn't be allowed to share binary versions of the homebrew here, for obvious reasons (source code would probably be questionable too..).
 
  • Like
Reactions: Deleted User
D

Deleted User

Guest
Probably, but you wouldn't be allowed to share binary versions of the homebrew here, for obvious reasons (source code would probably be questionable too..).
Ah yes, never thought of that. :P

--------------------- MERGED ---------------------------

If that's the case then, can I ask what's a good keyboard example to use?
 
  • Like
Reactions: daxtsu

Slashcash

Well-Known Member
Member
Joined
Oct 15, 2015
Messages
338
Trophies
0
XP
611
Country
Italy
  • Like
Reactions: Deleted User

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • BakerMan @ BakerMan:
    #stopkillinggames
    +1
  • BigOnYa @ BigOnYa:
    #mailmesomesirloinsteak
  • K3Nv2 @ K3Nv2:
    Mail you deeze nuts
  • BigOnYa @ BigOnYa:
    That be cheap, flat rate small envelope. Me- "Hey this envelope is empty, oh that makes since."
  • K3Nv2 @ K3Nv2:
    Still fits in your mouth the same way
  • BigOnYa @ BigOnYa:
    I was looking at steaks other day at grocery, can't believe some cuts (angus) are like $25 a pound. Crazyness. Price of good fish is just as bad.
  • BakerMan @ BakerMan:
    when i go to college,what do you guys think i should major?
  • BakerMan @ BakerMan:
    inb4 computer science
  • BigOnYa @ BigOnYa:
    Fake Leg scratching 101
  • K3Nv2 @ K3Nv2:
    IT support you can act like your own farts smell like cherries that way
  • K3Nv2 @ K3Nv2:
    Odin 2s $300 lol no
  • Scarlet @ Scarlet:
    The Mini is even more lol
  • K3Nv2 @ K3Nv2:
    That RG cube is starting to look like the better value price creep option
    +1
  • BigOnYa @ BigOnYa:
    I want a handheld gaming system with a tablet sized screen, like a 8 or10" screen, with controllers that can detach like the Switch.
  • BakerMan @ BakerMan:
    @BigOnYa i was legitimately trying to scratch my leg, this is reminding me of that cylinder post
  • Scarlet @ Scarlet:
    I don't see the buzz about a square screen personally. I think there will be a review on the site within a few weeks though if you are interested.
    +1
  • Scarlet @ Scarlet:
    I've put down the money on the Odin 2 Mini since I just love that Vita form factor. Loved the power of the Odin 2 but the size always put me off, this one seems exactly what I've been wanting.
  • K3Nv2 @ K3Nv2:
    I don't care about the square screen it's just nice to hold something you don't have to stretch your arms a foots length
  • K3Nv2 @ K3Nv2:
    All these things expecting to be super huge is overrated just run a type c cable to your TV if you want a big display or in my case screen mirror it
  • BigOnYa @ BigOnYa:
    On the go tho I meant, I use my 10" tablet and a Bluetooth controller for retro gaming while sitting on my porch or on long car rides sometimes. Easier on my eyes than the Switch screen.
  • K3Nv2 @ K3Nv2:
    My point is we already have enough shit with big displays having something pocketable with up to ps2 would be fine on the go
    +1
  • Psionic Roshambo @ Psionic Roshambo:
    Ken unless the games are made for that screen size most suck on a screen that size... Having a square screen and being brighter and higher res helps but it's not a cure all, text is tiny bullets are tiny, your.... Well lol
  • K3Nv2 @ K3Nv2:
    You can stretch to fit probably it's not all bad that they make it seem to be
  • K3Nv2 @ K3Nv2:
    People always yap about oh but you loose pixels but yeah it won't look awful either
    K3Nv2 @ K3Nv2: People always yap about oh but you loose pixels but yeah it won't look awful either