Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

50 рядки
2.1 KiB

  1. EXTENSION?=txt
  2. FORMAT?=DEFAULT
  3. .PHONY: all parse clean raylib_api
  4. raylib_parser: raylib_parser.c
  5. cc raylib_parser.c -o raylib_parser
  6. raylib_api: ../src/raylib.h raylib_parser
  7. FORMAT=DEFAULT EXTENSION=txt $(MAKE) raylib_api.txt
  8. FORMAT=JSON EXTENSION=json $(MAKE) raylib_api.json
  9. FORMAT=XML EXTENSION=xml $(MAKE) raylib_api.xml
  10. FORMAT=LUA EXTENSION=lua $(MAKE) raylib_api.lua
  11. raylib_api.$(EXTENSION): ../src/raylib.h raylib_parser
  12. ./raylib_parser -i ../src/raylib.h -o raylib_api.$(EXTENSION) -f $(FORMAT) -d RLAPI
  13. raymath_api.$(EXTENSION): ../src/raymath.h raylib_parser
  14. ./raylib_parser -i ../src/raymath.h -o raymath_api.$(EXTENSION) -f $(FORMAT) -d RMAPI
  15. rlgl_api.$(EXTENSION): ../src/rlgl.h raylib_parser
  16. ./raylib_parser -i ../src/rlgl.h -o rlgl_api.$(EXTENSION) -f $(FORMAT) -d RLAPI -t "RLGL IMPLEMENTATION"
  17. reasings_api.$(EXTENSION): ../examples/others/reasings.h raylib_parser
  18. ./raylib_parser -i ../examples/others/reasings.h -o reasings_api.$(EXTENSION) -f $(FORMAT) -d EASEDEF
  19. rmem_api.$(EXTENSION): ../rmem.h raylib_parser
  20. ./raylib_parser -i ../rmem.h -o rmem_api.$(EXTENSION) -f $(FORMAT) -d RMEMAPI -t "RMEM IMPLEMENTATION"
  21. physac_api.$(EXTENSION): ../physac.h raylib_parser
  22. ./raylib_parser -i ../physac.h -o physac_api.$(EXTENSION) -f $(FORMAT) -d PHYSACDEF -t "PHYSAC IMPLEMENTATION"
  23. raygui_api.$(EXTENSION): ../raygui.h raylib_parser
  24. ./raylib_parser -i ../raygui.h -o raygui_api.$(EXTENSION) -f $(FORMAT) -d RAYGUIAPI -t "RAYGUI IMPLEMENTATION"
  25. parse: raylib_api.$(EXTENSION) raymath_api.$(EXTENSION) rlgl_api.$(EXTENSION) rmem_api.$(EXTENSION) physac_api.$(EXTENSION) raygui_api.$(EXTENSION)
  26. # `make parse` (and therefore `make all) requires
  27. # rmem.h, physac.h and raygui.h to exist in the correct directory
  28. # API files for individual headers can be created likeso, provided the relevant header exists:
  29. # FORMAT=JSON EXTENSION=json make raygui_api.json
  30. all: raylib_parser
  31. FORMAT=DEFAULT EXTENSION=txt $(MAKE) parse
  32. FORMAT=JSON EXTENSION=json $(MAKE) parse
  33. FORMAT=XML EXTENSION=xml $(MAKE) parse
  34. FORMAT=LUA EXTENSION=lua $(MAKE) parse
  35. clean:
  36. rm -f raylib_parser *.json *.txt *.xml *.lua