1 # This manages to rebuild graminit.{h, c} under MSVC 6 (Windows), via
5 # The intermediate files can be nuked afterwards:
7 # nmake /f grammar.mak clean
9 # I don't understand the maze of preprocessor #define's on Windows, and
10 # as a result this requires linking with python22.lib, so it's of no use
11 # for bootstrapping (the cause appears to be a useless-- in this
12 # particular case --pragma in PC\pyconfig.h, which demands that
13 # python22.lib get linked in).
15 LIBS
= ..\PCbuild\python22.lib
17 CFLAGS
= /I ..\Include
/I ..\PC
/D MS_NO_COREDLL
19 GRAMMAR_H
= ..\Include\graminit.h
20 GRAMMAR_C
= ..\Python\graminit.c
21 GRAMMAR_INPUT
= ..\Grammar\Grammar
25 POBJS
= acceler.obj grammar1.obj listnode.obj node.obj parser.obj \
26 parsetok.obj tokenizer.obj bitset.obj metagrammar.obj
28 PARSER_OBJS
= $(POBJS
) myreadline.obj
30 PGOBJS
= firstsets.obj grammar.obj pgen.obj printgrammar.obj pgenmain.obj
32 PGENOBJS
= $(POBJS
) $(PGOBJS
)
34 $(GRAMMAR_H
) $(GRAMMAR_C
): $(PGEN
) $(GRAMMAR_INPUT
)
35 $(PGEN
) $(GRAMMAR_INPUT
) $(GRAMMAR_H
) $(GRAMMAR_C
)
38 $(CC
) $(PGENOBJS
) $(LIBS
) /Fe
$(PGEN
)