mirror of
https://github.com/italicsjenga/agb.git
synced 2025-01-11 01:21:34 +11:00
Build example gba files into examples/target
This commit is contained in:
parent
c0bf88e771
commit
0aa5d51c6f
6
.github/scripts/build-example-gba-files.sh
vendored
6
.github/scripts/build-example-gba-files.sh
vendored
|
@ -17,10 +17,12 @@ function build_rom() {
|
||||||
|
|
||||||
(cd "$GAME_FOLDER" && cargo build --release --verbose --target thumbv4t-none-eabi)
|
(cd "$GAME_FOLDER" && cargo build --release --verbose --target thumbv4t-none-eabi)
|
||||||
|
|
||||||
|
mkdir -p examples/target/examples
|
||||||
|
|
||||||
arm-none-eabi-objcopy -O binary "$TARGET_FOLDER/thumbv4t-none-eabi/release/$GAME_NAME" "$GBA_FILE"
|
arm-none-eabi-objcopy -O binary "$TARGET_FOLDER/thumbv4t-none-eabi/release/$GAME_NAME" "$GBA_FILE"
|
||||||
gbafix -p "-t${INTERNAL_NAME:0:12}" "-c${INTERNAL_NAME:0:4}" -mGC "$GBA_FILE"
|
gbafix -p "-t${INTERNAL_NAME:0:12}" "-c${INTERNAL_NAME:0:4}" -mGC "$GBA_FILE"
|
||||||
|
|
||||||
cp -v "$GBA_FILE" "examples/$GAME_NAME.gba"
|
cp -v "$GBA_FILE" "examples/target/examples/$GAME_NAME.gba"
|
||||||
}
|
}
|
||||||
|
|
||||||
mkdir -p examples/target
|
mkdir -p examples/target
|
||||||
|
@ -30,4 +32,4 @@ build_rom "examples/the-hat-chooses-the-wizard" "HATWIZARD"
|
||||||
|
|
||||||
build_rom "book/games/pong" "PONG"
|
build_rom "book/games/pong" "PONG"
|
||||||
|
|
||||||
zip examples/target/examples.zip examples/*.gba
|
(cd examples/target && zip examples.zip examples/*.gba)
|
1
examples/.gitignore
vendored
1
examples/.gitignore
vendored
|
@ -1 +0,0 @@
|
||||||
*.gba
|
|
Loading…
Reference in a new issue