Hacking [Release+Mini Tutorial] AIO.bat: All-In-1 batch file for compiling 3DS stuff

Rohul1997

Well-Known Member
Member
Joined
Dec 7, 2015
Messages
357
Trophies
0
Age
27
Location
Giant Chasm
XP
873
Country
atm when trying to Compile Luma3DS, this Errors out and the Compile doesnt complete:

khaxinit.cpp
arm-none-eabi-g++ -MMD -MP -MF /c/Users/Cael/Downloads/Work/Luma3DS/CakeBrah/build/khaxinit.d -g -Wall -Wextra -O3 -mword-relocations -fomit-frame-pointer -ffast-math -march=armv6k -mtune=mpcore -mfloat-abi=hard -I/c/Users/Cael/Downloads/Work/Luma3DS/CakeBrah/include -I/c/devkitPro/libctru/include -I/c/Users/Cael/Downloads/Work/Luma3DS/CakeBrah/build -DARM11 -D_3DS -DARM_ARCH -DLAUNCHER_PATH='"Luma3DS.dat"' -fno-rtti -fno-exceptions -std=gnu++11 -c /c/Users/Cael/Downloads/Work/Luma3DS/CakeBrah/source/libkhax/khaxinit.cpp -o khaxinit.o
c:/Users/Cael/Downloads/Work/Luma3DS/CakeBrah/source/libkhax/khaxinit.cpp: In function 'Result KHAX::IsNew3DS(bool*, u32)':
c:/Users/Cael/Downloads/Work/Luma3DS/CakeBrah/source/libkhax/khaxinit.cpp:985:47: error: cannot convert 'bool*' to 'u8* {aka unsigned char*}' for argument '1' to 'Result APT_CheckNew3DS(u8*)'
if (Result error = APT_CheckNew3DS(&isNew3DS))
^
make[2]: *** [khaxinit.o] Error 1
make[1]: *** [build] Error 2
make: *** [out/3ds/Luma3DS] Error 2
This was mentioned already. read from there and onwards - https://gbatemp.net/threads/release...ompiling-3ds-stuff.427577/page-8#post-6475939
 
  • Like
Reactions: Madridi

DjoeN

Captain Haddock!
Member
Joined
Oct 21, 2005
Messages
5,489
Trophies
0
Age
54
Location
Somewhere in this potatoland!
Website
djoen.dommel.be
XP
2,857
Country
Belgium
Maybe 2 new Homebrews to add from @Wolvan :

https://github.com/Wolvan/encTitleKeys.bin-Updater
https://github.com/Wolvan/Homebr3w

make dist-zip, zips the release ready for distribution, instead of using default tar

encTitleKeys.bin-Updater
Code:
@echo off
%~d0
cd %~dp0
cls
Title = Building encTitleKeys.bin-Updater...
if exist "encTitleKeys.bin-Updater" (
    echo Making a backup of your current encTitleKeys.bin-Updater folder
    xcopy "encTitleKeys.bin-Updater\*" "Backups_Compiles\Backup_encTitleKeys.bin-Updater" /e /i /y >nul
    cls
    cd encTitleKeys.bin-Updater
    Title = Building encTitleKeys.bin-Updater ^(Update^)...
    echo Updating repo...
    git pull origin master
    git submodule update --init --recursive
) else (
    Title = Building encTitleKeys.bin-Updater ^(Clone^)...
    echo Cloning repo...
    git clone --recursive https://github.com/Wolvan/encTitleKeys.bin-Updater
    cd encTitleKeys.bin-Updater
)
echo Building encTitleKeys.bin-Updater...
Title = Building encTitleKeys.bin-Updater ^(Clean^)...
make clean
Title = Building encTitleKeys.bin-Updater ^(Release^)...
make dist-zip
Title = Building encTitleKeys.bin-Updater ^(Done^)
echo.
cd %~dp0
echo.
echo ############################################
color A
echo Done. zip file is in "encTitleKeys.bin-Updater/build" folder.
echo Press any key to continue ...
Pause >nul
GOTO END


Homebr3w
Code:
@echo off
%~d0
cd %~dp0
cls
Title = Building Homebr3w...
if exist "Homebr3w" (
    echo Making a backup of your current Homebr3w folder
    xcopy "Homebr3w\*" "Backups_Compiles\Backup_Homebr3w" /e /i /y >nul
    cls
    cd Homebr3w
    Title = Building Homebr3w ^(Update^)...
    echo Updating repo...
    git pull origin master
    git submodule update --init --recursive
) else (
    Title = Building Homebr3w ^(Clone^)...
    echo Cloning repo...
    git clone --recursive https://github.com/Wolvan/Homebr3w
    cd Homebr3w
)
echo Building Homebr3w...
Title = Building Homebr3w ^(Clean^)...
make clean
Title = Building Homebr3w ^(Release^)...
make dist-zip
Title = Building Homebr3w ^(Done^)
echo.
cd %~dp0
echo.
echo ############################################
color A
echo Done. zip file is in "Homebr3w/build" folder.
echo Press any key to continue ...
Pause >nul
GOTO END
 
Last edited by DjoeN,
  • Like
Reactions: Madridi

Madridi

Card Collector
OP
Member
Joined
May 9, 2008
Messages
3,562
Trophies
2
Age
38
Location
Doha
XP
3,071
Country
Qatar
Maybe 2 new Homebrews to add from @Wolvan :

https://github.com/Wolvan/encTitleKeys.bin-Updater
https://github.com/Wolvan/Homebr3w

make dist-zip, zips the release ready for distribution, instead of using default tar

encTitleKeys.bin-Updater
Code:
@echo off
%~d0
cd %~dp0
cls
Title = Building encTitleKeys.bin-Updater...
if exist "encTitleKeys.bin-Updater" (
    echo Making a backup of your current encTitleKeys.bin-Updater folder
    xcopy "encTitleKeys.bin-Updater\*" "Backups_Compiles\Backup_encTitleKeys.bin-Updater" /e /i /y >nul
    cls
    cd encTitleKeys.bin-Updater
    Title = Building encTitleKeys.bin-Updater ^(Update^)...
    echo Updating repo...
    git pull origin master
    git submodule update --init --recursive
) else (
    Title = Building encTitleKeys.bin-Updater ^(Clone^)...
    echo Cloning repo...
    git clone --recursive https://github.com/Wolvan/encTitleKeys.bin-Updater
    cd encTitleKeys.bin-Updater
)
echo Building encTitleKeys.bin-Updater...
Title = Building encTitleKeys.bin-Updater ^(Clean^)...
make clean
Title = Building encTitleKeys.bin-Updater ^(Release^)...
make dist-zip
Title = Building encTitleKeys.bin-Updater ^(Done^)
echo.
cd %~dp0
echo.
echo ############################################
color A
echo Done. zip file is in "encTitleKeys.bin-Updater/build" folder.
echo Press any key to continue ...
Pause >nul
GOTO END


Homebr3w
Code:
@echo off
%~d0
cd %~dp0
cls
Title = Building Homebr3w...
if exist "Homebr3w" (
    echo Making a backup of your current Homebr3w folder
    xcopy "Homebr3w\*" "Backups_Compiles\Backup_Homebr3w" /e /i /y >nul
    cls
    cd Homebr3w
    Title = Building Homebr3w ^(Update^)...
    echo Updating repo...
    git pull origin master
    git submodule update --init --recursive
) else (
    Title = Building Homebr3w ^(Clone^)...
    echo Cloning repo...
    git clone --recursive https://github.com/Wolvan/Homebr3w
    cd Homebr3w
)
echo Building Homebr3w...
Title = Building Homebr3w ^(Clean^)...
make clean
Title = Building Homebr3w ^(Release^)...
make dist-zip
Title = Building Homebr3w ^(Done^)
echo.
cd %~dp0
echo.
echo ############################################
color A
echo Done. zip file is in "Homebr3w/build" folder.
echo Press any key to continue ...
Pause >nul
GOTO END
Thanks, I should really be getting back to this lol.. I haven't been doing anything 3ds related lately

Holy moly. :O I've been away for months and now I saw this thread! Super special awesome work @Madridi
Glad you like it :)
 

Madridi

Card Collector
OP
Member
Joined
May 9, 2008
Messages
3,562
Trophies
2
Age
38
Location
Doha
XP
3,071
Country
Qatar
Ok, So here is a bit of a status update:

I have left this for a while since I lost a bit of interest since my 3ds was bricked. It's fixed now (I think, still haven't fully tested it lol) thanks to @gamesquest1 & @capito27 so I'm back at this again

I just checked the build I have, some compiled fine, some required minor changes on my end, some need some updates that I need to talk to the devs about, and some wont compile because of the libkhax issue.

As far as I understand, @Myria has already fixed that, and programs like Luma uses the libkhax module directly so it compiles fine. The main problem is that cakebrah (which many programs use) still uses an old version of libkhax. So until that's updated, it won't work unless you revert to an older version ctrulib.

So they will all stay for now, as they are technically all working, and now that I implemented a way to revert to a specific ctrulib commit, it shouldn't be a major problem (just a pain..)

As far as I can tell, this is what's currently affected by libkhax
D9UI
Bootctr9
Delebile's A9LH
SafeA9LH
r3tools
Reinand
rxtools

I see @ShinyMK removed the thread. But his github is there. I assume this is no longer needed and JK should be used?


Maybe 2 new Homebrews to add from @Wolvan :

https://github.com/Wolvan/encTitleKeys.bin-Updater
https://github.com/Wolvan/Homebr3w

make dist-zip, zips the release ready for distribution, instead of using default tar

encTitleKeys.bin-Updater
Code:
@echo off
%~d0
cd %~dp0
cls
Title = Building encTitleKeys.bin-Updater...
if exist "encTitleKeys.bin-Updater" (
    echo Making a backup of your current encTitleKeys.bin-Updater folder
    xcopy "encTitleKeys.bin-Updater\*" "Backups_Compiles\Backup_encTitleKeys.bin-Updater" /e /i /y >nul
    cls
    cd encTitleKeys.bin-Updater
    Title = Building encTitleKeys.bin-Updater ^(Update^)...
    echo Updating repo...
    git pull origin master
    git submodule update --init --recursive
) else (
    Title = Building encTitleKeys.bin-Updater ^(Clone^)...
    echo Cloning repo...
    git clone --recursive https://github.com/Wolvan/encTitleKeys.bin-Updater
    cd encTitleKeys.bin-Updater
)
echo Building encTitleKeys.bin-Updater...
Title = Building encTitleKeys.bin-Updater ^(Clean^)...
make clean
Title = Building encTitleKeys.bin-Updater ^(Release^)...
make dist-zip
Title = Building encTitleKeys.bin-Updater ^(Done^)
echo.
cd %~dp0
echo.
echo ############################################
color A
echo Done. zip file is in "encTitleKeys.bin-Updater/build" folder.
echo Press any key to continue ...
Pause >nul
GOTO END


Homebr3w
Code:
@echo off
%~d0
cd %~dp0
cls
Title = Building Homebr3w...
if exist "Homebr3w" (
    echo Making a backup of your current Homebr3w folder
    xcopy "Homebr3w\*" "Backups_Compiles\Backup_Homebr3w" /e /i /y >nul
    cls
    cd Homebr3w
    Title = Building Homebr3w ^(Update^)...
    echo Updating repo...
    git pull origin master
    git submodule update --init --recursive
) else (
    Title = Building Homebr3w ^(Clone^)...
    echo Cloning repo...
    git clone --recursive https://github.com/Wolvan/Homebr3w
    cd Homebr3w
)
echo Building Homebr3w...
Title = Building Homebr3w ^(Clean^)...
make clean
Title = Building Homebr3w ^(Release^)...
make dist-zip
Title = Building Homebr3w ^(Done^)
echo.
cd %~dp0
echo.
echo ############################################
color A
echo Done. zip file is in "Homebr3w/build" folder.
echo Press any key to continue ...
Pause >nul
GOTO END
Will add this once I get the other stuff sorted out.
I also have not forgotten about ctrbootmanager9 by @OperationNT .. I need to contact him to work out the kinks in compiling mentioned a couple of pages ago.

I'll also add the HBL upstream (though I cant get it compiled atm)

I hope I did not forget anything else :)
 
Last edited by Madridi,
  • Like
Reactions: Rohul1997

PRAGMA

Well-Known Member
Member
Joined
Dec 29, 2015
Messages
2,258
Trophies
1
Location
Ireland
Website
github.com
XP
5,037
Country
Ireland
Ok, So here is a bit of a status update:

I have left this for a while since I lost a bit of interest since my 3ds was bricked. It's fixed now (I think, still haven't fully tested it lol) thanks to @gamesquest1 & @capito27 so I'm back at this again

I just checked the build I have, some compiled fine, some required minor changes on my end, some need some updates that I need to talk to the devs about, and some wont compile because of the libkhax issue.

As far as I understand, @Myria has already fixed that, and programs like Luma uses the libkhax module directly so it compiles fine. The main problem is that cakebrah (which many programs use) still uses an old version of libkhax. So until that's updated, it won't work unless you revert to an older version ctrulib.

So they will all stay for now, as they are technically all working, and now that I implemented a way to revert to a specific ctrulib commit, it shouldn't be a major problem (just a pain..)

As far as I can tell, this is what's currently affected by libkhax
D9UI
Bootctr9
Delebile's A9LH
SafeA9LH
r3tools
Reinand
rxtools


I see @ShinyMK removed the thread. But his github is there. I assume this is no longer needed and JK should be used?



Will add this once I get the other stuff sorted out.
I also have not forgotten about ctrbootmanager9 by @OperationNT .. I need to contact him to work out the kinks in compiling mentioned a couple of pages ago.

I'll also add the HBL upstream (though I cant get it compiled atm)

I hope I did not forget anything else :)
You guys can use it, But im not making it public here as I just get hate for it just cause I wasnt the original Creator. Some people are just ungrateful.
 

Madridi

Card Collector
OP
Member
Joined
May 9, 2008
Messages
3,562
Trophies
2
Age
38
Location
Doha
XP
3,071
Country
Qatar
You guys can use it, But im not making it public here as I just get hate for it just cause I wasnt the original Creator. Some people are just ungrateful.
As long as you gave him credit, I wouldn't see where the problem is. Don't take personally though. Lots of kids on this site unfortunately.
 
  • Like
Reactions: Rohul1997

PRAGMA

Well-Known Member
Member
Joined
Dec 29, 2015
Messages
2,258
Trophies
1
Location
Ireland
Website
github.com
XP
5,037
Country
Ireland
As long as you gave him credit, I wouldn't see where the problem is. Don't take personally though. Lots of kids on this site unfortunately.
I will take him personally, Before I made the thread I asked if I could post it etc, He didnt care, I post it, He sees it and sees how much more active my thread was compared to his, he started hating it, decides to leave my pm, i pm him again asking whats going on, he leaves then blocks me, then starts updating his version (After not updating it for almost a year) and only updates as a .3dsx/.cia not source code just so people would go to his version and not mine since I can t update my source to be the same as his but with my modifications.
 

Madridi

Card Collector
OP
Member
Joined
May 9, 2008
Messages
3,562
Trophies
2
Age
38
Location
Doha
XP
3,071
Country
Qatar
I will take him personally, Before I made the thread I asked if I could post it etc, He didnt care, I post it, He sees it and sees how much more active my thread was compared to his, he started hating it, decides to leave my pm, i pm him again asking whats going on, he leaves then blocks me, then starts updating his version (After not updating it for almost a year) and only updates as a .3dsx/.cia not source code just so people would go to his version and not mine since I can t update my source to be the same as his but with my modifications.
That's unfortunate. I hope it's just some crossed wires or something. That being said, I noticed his entire source was updated 2 days ago, so I wouldn't know about this.
Either way, it's a gaming community. I hope people just learn to have fun over here
 

PRAGMA

Well-Known Member
Member
Joined
Dec 29, 2015
Messages
2,258
Trophies
1
Location
Ireland
Website
github.com
XP
5,037
Country
Ireland
That's unfortunate. I hope it's just some crossed wires or something. That being said, I noticed his entire source was updated 2 days ago, so I wouldn't know about this.
Either way, it's a gaming community. I hope people just learn to have fun over here
All he did in it was sync it so he can start using GitHub Desktop/Git. Theres no changes
 

Madridi

Card Collector
OP
Member
Joined
May 9, 2008
Messages
3,562
Trophies
2
Age
38
Location
Doha
XP
3,071
Country
Qatar
.. and a new release!
I don't particularly like this release, since many of the sources required workarounds to work again. Those are necessary because basically devs are on holidays or something and have not updated their submodules.

- Workaround implemented for a lot of sources due to libkhax not being updated for these sources (Many listed in a couple of posts above
- Corbenik and r3tools removed
- Shadownand, Shadownand Installer, Homebr3w, enctitlekeys.bin-updater, 3DSident, Hourglass9UI were all added
- Tons of bug fixes (Too many to list or even remember)

A few of notes:
- Decrypt9 UI and Cosmo3DS will not compile anymore, but they are still in the program. @Shadowtrance will have to update his source for Decrypt9 UI to work, and @yifan_lu will hopefully get some time to work on the 3ds_injector issue to get Cosmo3DS to work again.
- Those workarounds will be removed once the devs update their sources. Some (like rxtools) will never be fixed cause they are abandoned, so they will stay the way it is.
- Special instructions for JKSM compiling: You need to reinstall sf2dlib again and follow the instructions on screen when they popup. It should compile and work fine afterwards. Thanks to to @JK_ for his help on this
- r3tools is the only tool that is both abandoned & not compile-able anymore. If @173210 fixes that, I'll gladly add that again.
- @chaoskagami unfortunately does not support Corbenik compiling on windows. Since I can't get it to compile, it has been removed. @chaoskagami if you decide at some point to make that possible on windows, please give me a shout :)
- Thanks to @Shadowhand for Shadownand and shadownand installer. I added both of these under a9lh rather than CFW since it deals with A9lh. So I want the user to be extra careful with that.
- Thanks to @Wolvan for Homebr3w and enctitlekey.bin-updater, to @Joel16 for 3dsident, and to @Shadowtrance for Hourglass9UI. All of these will be given proper credit reflected on the first page.
- And finally.. As usual, thanks to my trusty buddy @Rohul1997 for his testing and bug fixing, and to @DjoeN for his usual suggestions and "heads up" on anything new!

Enjoy :)
 
  • Like
Reactions: Rohul1997

Madridi

Card Collector
OP
Member
Joined
May 9, 2008
Messages
3,562
Trophies
2
Age
38
Location
Doha
XP
3,071
Country
Qatar
Damn I knew I forgot someone.. My apologies to @DanTheMan827 .. His Tikdevil source is also added, and appropriate credits will be added on the first page.

What I'm hoping to do in the next version:
- Remove those workarounds (I really hate them lol)
- Add @OperationNT 's fork of Ctrbootmanager9 once I can get a hold of him to get more clarity on the compiling process.
- Add HBL: This was going to be added in this version, but it's not working with the latest ctrulib. So I'll add it when it's updated to work with the latest
- Hopefully, new stuff :)
 

Madridi

Card Collector
OP
Member
Joined
May 9, 2008
Messages
3,562
Trophies
2
Age
38
Location
Doha
XP
3,071
Country
Qatar
@Madridi
I brought the issue up on xerpi's git for sf2d. So, maybe it won't need a special edit soon.
Nice! That would make me take off that pause I have for the manual edit.

It's also great that fincs changes where merged with xerpi's git, cause sftdlib was not compiling with fincs, which meant people would have to install xerpi first then fincs, which meant I would have had to have both forks in the program. Glad that's not the case cause it would've been a mess!
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    OctoAori20 @ OctoAori20: Nice nice-