Human68k CUI emulator with sound.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Makefile 2.8KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. MUSASHIFILES=m68kcpu.c m68kdasm.c
  2. MUSASHIGENCFILES=m68kops.c m68kopac.c m68kopdm.c m68kopnz.c
  3. MUSASHIOBJS=$(patsubst %.c,musashi/%.o,$(MUSASHIFILES))
  4. MUSASHIGENOBJS=$(patsubst %.c,musashi/%.o,$(MUSASHIGENCFILES))
  5. all: v68 xinfo sjis2utf8
  6. $(patsubst %.c,musashi/%.c,$(MUSASHIGENCFILES)): musashi/m68kmake musashi/m68k_in.c
  7. (cd musashi && ./m68kmake)
  8. musashi/m68kmake: musashi/m68kmake.o
  9. gcc $^ -o $@
  10. v68: main.o tools.o v68.o v68ipl.o v68io.o v68periph.o v68human.o v68doscall.o v68iocscall.o v68fecall.o sjis.o sjis_unicode.o utf8.o ym2151.o dmac.o okim6258.o vgm.o $(MUSASHIOBJS) $(MUSASHIGENOBJS) fake_ipl.inc fake_human.inc
  11. gcc -g -ggdb $(filter %.o,$^) $(shell pkg-config --libs ao) -lm -o $@
  12. v68human.o: v68human.c fake_human.inc
  13. v68ipl.o: v68ipl.c fake_ipl.inc
  14. HAS060=wine ~/ownCloud/X68000/run68/run68.exe 'H:\\ownCloud\\X68000\\has060.x'
  15. HASFLAGS=-m68000
  16. LK=wine ~/ownCloud/X68000/run68/run68.exe x/xc/BIN/LK.X
  17. fake_ipl.inc: fake_ipl.s xdump
  18. include=tests $(HAS060) $(HASFLAGS) $(patsubst %.inc,%.s,$@)
  19. $(LK) /bff0000 $(patsubst %.inc,%.o,$@)
  20. ./xdump $(patsubst %.inc,%.x,$@) > $@
  21. rm -f $(patsubst %.inc,%.x,$@) $(patsubst %.inc,%.o,$@)
  22. fake_human.inc: fake_human.s xdump
  23. include=tests $(HAS060) $(HASFLAGS) $(patsubst %.inc,%.s,$@)
  24. $(LK) /b006800 $(patsubst %.inc,%.o,$@)
  25. ./xdump $(patsubst %.inc,%.x,$@) > $@
  26. rm -f $(patsubst %.inc,%.x,$@) $(patsubst %.inc,%.o,$@)
  27. xinfo: xinfo.o md5.o cmdline.o
  28. gcc $^ -o $@
  29. xdump: xdump.o tools.o
  30. gcc $^ -o $@
  31. sjis2utf8: sjis2utf8.o sjis.o sjis_unicode.o utf8.o
  32. gcc $^ -o $@
  33. sjisstat: sjisstat.o sjis.o sjis_unicode.o utf8.o
  34. gcc $^ -o $@
  35. test-mem: test-mem.o v68.o v68human.o v68opm.o v68io.o v68doscall.o v68fecall.o v68iocscall.o okim6258.o ym2151.o vgm.o sjis.o sjis_unicode.o $(MUSASHIOBJS) $(MUSASHIGENOBJS)
  36. gcc $^ -lao -lm -o $@
  37. %.o: %.c
  38. gcc -g -ggdb -Wall $(shell pkg-config --cflags ao) -c $< -o $@
  39. clean:
  40. rm -f v68 xinfo xdump sjis2utf8 *.o musashi/*.o $(patsubst %.c,musashi/%.c,$(MUSASHIGENCFILES)) ay.js *.wasm *.map test
  41. main.o: main.c v68.h okim6258.h mamedef.h ym2151.h v68io.h cmdline.h \
  42. tools.h
  43. tools.o: tools.c tools.h
  44. v68.o: v68.c v68.h okim6258.h mamedef.h ym2151.h v68io.h \
  45. musashi/m68kcpu.h musashi/m68k.h musashi/m68kconf.h
  46. v68io.o: v68io.c v68io.h v68.h okim6258.h mamedef.h ym2151.h
  47. ym2151.o: ym2151.c mamedef.h ym2151.h
  48. okim6258.o: okim6258.c mamedef.h okim6258.h
  49. vgm.o: vgm.c vgm.h
  50. m68kcpu.o: musashi/m68kcpu.c musashi/m68kops.h musashi/m68kcpu.h \
  51. musashi/m68k.h musashi/m68kconf.h
  52. m68kdasm.o: musashi/m68kdasm.c musashi/m68k.h musashi/m68kconf.h
  53. m68kops.o: musashi/m68kops.c musashi/m68kops.h
  54. m68kopac.o: musashi/m68kopac.c musashi/m68kcpu.h musashi/m68k.h \
  55. musashi/m68kconf.h
  56. m68kopdm.o: musashi/m68kopdm.c musashi/m68kcpu.h musashi/m68k.h \
  57. musashi/m68kconf.h
  58. m68kopnz.o: musashi/m68kopnz.c musashi/m68kcpu.h musashi/m68k.h \
  59. musashi/m68kconf.h