]> granicus.if.org Git - python/commitdiff
Fix up problems when compiling in a directory other than the source
authorSjoerd Mullender <sjoerd@acm.org>
Thu, 17 Aug 2000 11:38:18 +0000 (11:38 +0000)
committerSjoerd Mullender <sjoerd@acm.org>
Thu, 17 Aug 2000 11:38:18 +0000 (11:38 +0000)
directory.

Grammar/Makefile [deleted file]
Grammar/Makefile.in [new file with mode: 0644]
Makefile.in
configure.in

diff --git a/Grammar/Makefile b/Grammar/Makefile
deleted file mode 100644 (file)
index a490284..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-TOP=           ..
-PGENDIR=       $(TOP)/Parser
-PGEN=          $(PGENDIR)/pgen
-DESTH=         $(TOP)/Include/graminit.h
-DESTC=         $(TOP)/Python/graminit.c
-
-all:           install
-
-# This target is used by the master Makefile to add the objects to the library
-add2lib:
-
-install:       $(DESTH) $(DESTC)
-
-depend:
-
-$(DESTH):      graminit.h
-               cp graminit.h $(DESTH)
-
-$(DESTC):      graminit.c
-               cp graminit.c $(DESTC)
-
-graminit.c graminit.h: $(PGEN) Grammar
-               $(PGEN) Grammar
-
-$(PGEN):
-               cd $(PGENDIR); make pgen
-
-clean:
-               -rm -f *.o core *~ [@,#]* *.old *.orig *.rej
-               -rm -f graminit.[ch]
-
-clobber:       clean
-               -rm -f tags TAGS
diff --git a/Grammar/Makefile.in b/Grammar/Makefile.in
new file mode 100644 (file)
index 0000000..8121409
--- /dev/null
@@ -0,0 +1,54 @@
+# NOTE: Makefile.in is converted into Makefile by the configure script
+# in the parent directory.  Once configure has run, you can recreate
+# the Makefile by running just config.status.
+
+# === Variables set by config.stat ===
+
+VERSION=       @VERSION@
+
+srcdir=                @srcdir@
+VPATH=         @srcdir@
+
+CC=            @CC@
+RANLIB=                @RANLIB@
+AR=            @AR@
+
+DEFS=          @DEFS@
+LIBS=          @LIBS@
+
+
+# === Fixed definitions ===
+
+TOP=           ..
+PGENDIR=       $(TOP)/Parser
+PGEN=          $(PGENDIR)/pgen
+DESTH=         $(srcdir)/$(TOP)/Include/graminit.h
+DESTC=         $(srcdir)/$(TOP)/Python/graminit.c
+
+all:           install
+
+# This target is used by the master Makefile to add the objects to the library
+add2lib:
+
+install:       $(DESTH) $(DESTC)
+
+depend:
+
+$(DESTH):      graminit.h
+               cp graminit.h $(DESTH)
+
+$(DESTC):      graminit.c
+               cp graminit.c $(DESTC)
+
+graminit.c graminit.h: $(PGEN) Grammar
+               $(PGEN) $(srcdir)/Grammar
+
+$(PGEN):
+               cd $(PGENDIR); $(MAKE) pgen
+
+clean:
+               -rm -f *.o core *~ [@,#]* *.old *.orig *.rej
+               -rm -f graminit.[ch]
+
+clobber:       clean
+               -rm -f tags TAGS
index d4a063e56e422ae5eee9d1a3f0ad1c7720ea8ac8..88f4efea472cfd646ec8efc6313bb3ea3daa9548 100644 (file)
@@ -196,8 +196,7 @@ libpython$(VERSION).dylib: $(LIBRARY)
 $(SUBDIRS):    Makefiles
 
 Grammar:
-               P=`pwd`/Parser; cd $(srcdir)/Grammar; $(MAKE) PGENDIR=$$P \
-                       OPT="$(OPT)" VERSION="$(VERSION)" \
+               cd Grammar ; $(MAKE) OPT="$(OPT)" VERSION="$(VERSION)" \
                        prefix="$(prefix)" exec_prefix="$(exec_prefix)" all
 
 Parser:
index b05ce4b550f10cd3a8ef856f30428be4aa1f6d54..aeb322331ce75ed487da950ca245948b5657f0e1 100644 (file)
@@ -1167,6 +1167,7 @@ AC_CHECK_TYPE(socklen_t, int)
 AC_OUTPUT(Makefile \
  Objects/Makefile \
  Parser/Makefile \
+ Grammar/Makefile \
  Python/Makefile \
  Modules/Makefile.pre \
  Modules/Setup.config)