2017-07-20 08:26:35 +00:00
|
|
|
unset CFLAGS CXXFLAGS LDFLAGS
|
2017-05-14 09:57:29 +00:00
|
|
|
builddir() {
|
2017-05-20 20:04:22 +00:00
|
|
|
rm -rf build/ &&
|
2017-05-14 09:57:29 +00:00
|
|
|
mkdir -pv build/
|
|
|
|
}
|
|
|
|
rm -rvvf out/
|
|
|
|
mkdir -pv out/
|
|
|
|
#x86-PC config
|
|
|
|
{
|
|
|
|
echo 0 #x86-pc
|
|
|
|
yes ''
|
|
|
|
} | ./config.py &&
|
|
|
|
builddir &&
|
|
|
|
pushd build &&
|
2017-08-26 13:45:02 +00:00
|
|
|
cmake -DCMAKE_TOOLCHAIN_FILE=../toolchains/i686-elf.cmake .. &&
|
2017-05-14 09:57:29 +00:00
|
|
|
make -j$(nproc) &&
|
|
|
|
popd &&
|
|
|
|
buildtools/grub-iso.sh &&
|
2017-07-20 16:48:44 +00:00
|
|
|
mv bootable.iso out/x86-pc.iso &&
|
|
|
|
cp build/kernel/kernel out/x86-pc.elf
|
2017-05-14 09:57:29 +00:00
|
|
|
|
|
|
|
#x86-PC config
|
|
|
|
{
|
|
|
|
echo 1 #x86_64-pc
|
|
|
|
yes ''
|
|
|
|
} | ./config.py &&
|
|
|
|
builddir &&
|
|
|
|
pushd build &&
|
|
|
|
cmake -DCMAKE_TOOLCHAIN_FILE=../toolchains/x86_64-elf.cmake .. &&
|
|
|
|
make -j$(nproc) &&
|
|
|
|
popd &&
|
|
|
|
buildtools/grub-iso.sh &&
|
2017-07-20 16:48:44 +00:00
|
|
|
mv bootable.iso out/x86_64-pc.iso &&
|
|
|
|
cp build/kernel/kernel out/x86_64-pc.elf
|
2017-05-14 09:57:29 +00:00
|
|
|
|
|
|
|
#arm-3ds9 config
|
2017-07-29 11:07:16 +00:00
|
|
|
builddir &&
|
|
|
|
pushd build &&
|
|
|
|
git clone https://github.com/MTGos/mtgos-3ds9 &&
|
|
|
|
pushd mtgos-3ds9 &&
|
2017-05-14 09:57:29 +00:00
|
|
|
builddir &&
|
|
|
|
pushd build &&
|
|
|
|
cmake -DCMAKE_TOOLCHAIN_FILE=../toolchains/arm-none-eabi.cmake .. &&
|
|
|
|
make -j$(nproc) &&
|
|
|
|
popd &&
|
2017-07-29 11:07:16 +00:00
|
|
|
mv build/kernel/kernel ../../kernel9
|
|
|
|
popd &&
|
|
|
|
popd &&
|
2017-05-14 09:57:29 +00:00
|
|
|
cp -v kernel9 out/arm9loaderhax.elf
|
|
|
|
|
|
|
|
#arm-3ds11 config
|
|
|
|
{
|
|
|
|
echo 2 #arm
|
2017-07-29 11:07:16 +00:00
|
|
|
echo 0 #3ds11
|
2017-05-14 09:57:29 +00:00
|
|
|
yes ''
|
|
|
|
} | ./config.py &&
|
|
|
|
builddir &&
|
|
|
|
pushd build &&
|
|
|
|
cmake -DCMAKE_TOOLCHAIN_FILE=../toolchains/arm-none-eabi.cmake .. &&
|
|
|
|
make -j$(nproc) &&
|
|
|
|
popd &&
|
|
|
|
mv kernel9 build/kernel &&
|
|
|
|
buildtools/sighax-firm.sh &&
|
|
|
|
mv sighax.firm out/ &&
|
|
|
|
cp -v build/kernel/kernel out/arm11loaderhax.elf
|
2017-07-20 08:26:35 +00:00
|
|
|
|
2017-12-09 18:46:35 +00:00
|
|
|
cat > /dev/null << EOF
|
2017-07-20 08:26:35 +00:00
|
|
|
{
|
|
|
|
echo 2
|
2017-07-29 11:07:16 +00:00
|
|
|
echo 1
|
2017-07-20 08:26:35 +00:00
|
|
|
yes ''
|
|
|
|
} | ./config.py &&
|
|
|
|
builddir &&
|
|
|
|
pushd build &&
|
|
|
|
cmake -DCMAKE_TOOLCHAIN_FILE=../toolchains/arm-none-eabi.cmake .. &&
|
|
|
|
make -j$(nproc) &&
|
|
|
|
popd &&
|
|
|
|
cp -v build/kernel/kernel out/raspi2.elf
|
2017-12-09 18:46:35 +00:00
|
|
|
EOF
|