wii.sh 902 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. platform_enter_hook() {
  2. pushd arch/wii >/dev/null
  3. unzip -qq $HOME/megazeux/scripts/deps/wii.zip
  4. popd >/dev/null
  5. export DEVKITPRO=$HOME/bin/devkitpro
  6. export DEVKITPPC=$HOME/bin/devkitpro/devkitPPC
  7. export PATH=$DEVKITPPC/bin:$PATH
  8. BUILD_FLAGS="debuglink"
  9. CONFIG_FLAGS="$CONFIG_FLAGS --platform wii --prefix $DEVKITPPC \
  10. --enable-release --disable-utils --enable-tremor \
  11. --enable-meter"
  12. }
  13. platform_exit_hook() {
  14. rm -rf arch/wii/{libfat,libogg,libvorbis}
  15. }
  16. platform_build_test_hook() {
  17. if [ ! -f mzxrun -o ! -f megazeux ]; then
  18. ERRNO=1
  19. return
  20. fi
  21. file mzxrun | egrep -q "ELF 32-bit.*MSB.*PowerPC.*statically"
  22. if [ "$?" != "0" ]; then
  23. ERRNO=1
  24. return
  25. fi
  26. file megazeux | egrep -q "ELF 32-bit.*MSB.*PowerPC.*statically"
  27. if [ "$?" != "0" ]; then
  28. ERRNO=1
  29. return
  30. fi
  31. }
  32. platform_archive_test_hook() {
  33. [ ! -f build/dist/wii/*wii.zip ] && ERRNO=2
  34. }