Makefile.win32 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. # Copyright (C) 2006,2008 G.P. Halkes
  2. # This program is free software: you can redistribute it and/or modify
  3. # it under the terms of the GNU General Public License version 3, as
  4. # published by the Free Software Foundation.
  5. #
  6. # This program is distributed in the hope that it will be useful,
  7. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  8. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  9. # GNU General Public License for more details.
  10. #
  11. # You should have received a copy of the GNU General Public License
  12. # along with this program. If not, see <http://www.gnu.org/licenses/>.
  13. # C-compiler flags
  14. CFLAGS=/O2
  15. # Regular expression support
  16. # REGEX should have one of the values POSIX, OLDPOSIX, PCRE, or be unset. All
  17. # the named options use the POSIX regular expression API. POSIX includes the
  18. # "regex.h" header file, OLDPOSIX also includes the "sys/types.h" header file,
  19. # and PCRE uses the "pcreposix.h" header file. The latter also requires
  20. # linking with pcreposix.lib for proper operation.
  21. # REGEXLIBS should provide any options necessary for linking all the libraries
  22. # required for the regular expression code
  23. REGEX=
  24. REGEXLIBS=
  25. CSOURCES=src\argcount.c src\clash.c src\depend.c src\freeData.c src\generate.c src\generateCommon.c src\generateLLgenStyle.c src\generateTS.c src\globals.c src\io.c src\list.c src\main.c src\nonRuleAnalysis.c src\option.c src\os.c src\printInput.c src\ruleAnalysis.c src\scope.c src\set.c src\traceTokens.c src\clashStrings.c
  26. LSOURCES=src\lexer.l
  27. GSOURCES=src\grammar.g
  28. OBJECTS=$(CSOURCES:.c=.obj) $(LSOURCES:.l=.obj) $(GSOURCES:.g=.obj)
  29. all: LLnextgen
  30. clean:
  31. del src\*.obj src\grammar.c src\grammar.h src\lexer.c
  32. dist-clean: clean
  33. del LLnextgen.exe
  34. LLnextgen: $(OBJECTS)
  35. $(CC) /FeLLnextgen $(OBJECTS) $(LDLIBS) $(REGEXLIBS)
  36. src\lexer.c: src\lexer.c.dist
  37. copy src\lexer.c.dist src\lexer.c
  38. src\grammar.c: src\grammar.c.dist
  39. copy src\grammar.c.dist src\grammar.c
  40. src\grammar.h: src\grammar.h.dist
  41. copy src\grammar.h.dist src\grammar.h
  42. src\grammar.obj: src\grammar.h
  43. src\io.obj: src\grammar.h
  44. src\lexer.obj: src\grammar.h
  45. src\main.obj: src\grammar.h
  46. src\printInput.obj: src\grammar.h
  47. .c.obj:
  48. $(CC) $(CFLAGS) /DREGEX=$(REGEX) /c $< /Fo$@