[Python-checkins] CVS: python/dist/src/Parser grammar.mak,NONE,1.1
Tim Peters
tim_one@users.sourceforge.net
Sat, 13 Oct 2001 13:16:20 -0700
Update of /cvsroot/python/python/dist/src/Parser
In directory usw-pr-cvs1:/tmp/cvs-serv2119/python/Parser
Added Files:
grammar.mak
Log Message:
An MSVC makefile to rebuild the grammar files (graminit.[ch]) manually.
Ugly, but it works.
--- NEW FILE: grammar.mak ---
# This manages to rebuild graminit.{h, c} under MSVC 6 (Windows), via
#
# nmake /f grammar.mak
#
# The intermediate files can be nuked afterwards:
#
# nmake /f grammar.mak clean
#
# I don't understand the maze of preprocessor #define's on Windows, and
# as a result this requires linking with python22.lib, so it's of no use
# for bootstrapping (the cause appears to be a useless-- in this
# particular case --pragma in PC\pyconfig.h, which demands that
# python22.lib get linked in).
LIBS= ..\PCbuild\python22.lib
CFLAGS= /I ..\Include /I ..\PC /D MS_NO_COREDLL
GRAMMAR_H= ..\Include\graminit.h
GRAMMAR_C= ..\Python\graminit.c
GRAMMAR_INPUT= ..\Grammar\Grammar
PGEN= pgen.exe
POBJS= acceler.obj grammar1.obj listnode.obj node.obj parser.obj \
parsetok.obj tokenizer.obj bitset.obj metagrammar.obj
PARSER_OBJS= $(POBJS) myreadline.obj
PGOBJS= firstsets.obj grammar.obj pgen.obj printgrammar.obj pgenmain.obj
PGENOBJS= $(POBJS) $(PGOBJS)
$(GRAMMAR_H) $(GRAMMAR_C): $(PGEN) $(GRAMMAR_INPUT)
$(PGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
$(PGEN): $(PGENOBJS)
$(CC) $(PGENOBJS) $(LIBS) /Fe$(PGEN)
clean:
del *.obj
del $(PGEN)