Makefile 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. BUILD_OPTS =
  2. BUILD = ${BUILD_OPTS} go build
  3. EXT =
  4. all: door32${EXT} testdoor/testdoor${EXT} space-ace/space-ace${EXT} yt2000/yt2000${EXT} mines/mines${EXT} door32${EXT}
  5. mines/mines: mines/*.go
  6. cd mines; ${BUILD}
  7. # The old utility:
  8. # font-out: font-out.go
  9. # go build font-out.go
  10. # cd font-show; go build
  11. # font-util does it all! show, extract, list
  12. font-util/font-util:
  13. cd font-util; ${BUILD}
  14. door32${EXT}: door32.go convert.go
  15. ${BUILD_OPTS} go build door32.go convert.go
  16. # door32: door32.c
  17. # gcc -g -o door32d door32.c
  18. # gcc -o door32 door32.c
  19. testdoor/fonts.go: font-util/font-util
  20. ./font-util/font-util extract -f "Amazon Cyan,Anarchy Blue,Unchained,Asylum,ArmageonRed,BrainDmgBlu,Boner,Descent,Remorse,Dungeon" TDFONTS.TDF TDFONTS2.TDF TDFONTS9.TDF > testdoor/fonts.go
  21. # Extract font, change colors, rename font to RedGreen.
  22. testdoor/rgfont.go: font-util/font-util
  23. ./font-util/font-util extract -f Armageddon -c 7,1 -c 4,2 TDFONTS2.TDF > testdoor/rgfont.go
  24. sed -i 's/Armageddon/RedGreen/g' testdoor/rgfont.go
  25. ansi-to-go/ansi-to-go: ansi-to-go/ansi-to-go.go
  26. cd ansi-to-go; ${BUILD}
  27. # Instead, use:
  28. # //go:embed growl.ans
  29. # var growl string
  30. #
  31. # testdoor/art.go: testdoor/growl.ans ansi-to-go/ansi-to-go
  32. # ./ansi-to-go/ansi-to-go testdoor/growl.ans > testdoor/art.go
  33. space-ace/space.go: space-ace/space.ans
  34. ./ansi-to-go/ansi-to-go space-ace/space.ans > space-ace/space.go
  35. # ./ansi-to-go.py main space.ans > space-ace/space.go
  36. testdoor/testdoor${EXT}: testdoor/art.go testdoor/fonts.go testdoor/rgfont.go testdoor/*.go door/*.go
  37. cd testdoor; ${BUILD}
  38. # Build a windows exe, because we can!
  39. # testdoor/testdoor.exe: testdoor/art.go testdoor/fonts.go testdoor/rgfont.go testdoor/*.go door/*.go
  40. # cd testdoor; GOOS=windows GOARCH=amd64 go build
  41. # Build, with static link of sqlite.
  42. space-ace/space-ace${EXT}: space-ace/*.go door/*.go space-ace/space.go
  43. cd space-ace; ${BUILD} -ldflags="-extldflags=-static" -tags sqlite_omit_load_extension
  44. # ./font-out -f "Amazon Cyan,Medieval,Anarchy Blue" TDFONTS.TDF
  45. # ./font-out -f Unchained,Asylum,ArmageonRed,BrainDmgBlu TDFONTS2.TDF
  46. # ./font-out -f Boner,Descent,Remorse,Dungeon TDFONTS9.TDF
  47. yt2000/ytopen.go: yt2000/ytopen.ans
  48. ./ansi-to-go/ansi-to-go yt2000/ytopen.ans > yt2000/ytopen.go
  49. yt2000/cyberwar.go:
  50. ./font-util/font-util extract -f CyberWar *.TDF > yt2000/cyberwar.go
  51. yt2000/armagedonred.go:
  52. ./font-util/font-util extract -f ArmagedonRed *.TDF > yt2000/armagedonred.go
  53. yt2000/yt2000${EXT}: yt2000/yt.go yt2000/ytopen.go yt2000/cyberwar.go
  54. cd yt2000; ${BUILD}