Commit 59bb0800 authored by Sjoerd Mullender's avatar Sjoerd Mullender

Fix up problems when compiling in a directory other than the source

directory.
parent 227b1204
# 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= .. TOP= ..
PGENDIR= $(TOP)/Parser PGENDIR= $(TOP)/Parser
PGEN= $(PGENDIR)/pgen PGEN= $(PGENDIR)/pgen
DESTH= $(TOP)/Include/graminit.h DESTH= $(srcdir)/$(TOP)/Include/graminit.h
DESTC= $(TOP)/Python/graminit.c DESTC= $(srcdir)/$(TOP)/Python/graminit.c
all: install all: install
...@@ -20,10 +41,10 @@ $(DESTC): graminit.c ...@@ -20,10 +41,10 @@ $(DESTC): graminit.c
cp graminit.c $(DESTC) cp graminit.c $(DESTC)
graminit.c graminit.h: $(PGEN) Grammar graminit.c graminit.h: $(PGEN) Grammar
$(PGEN) Grammar $(PGEN) $(srcdir)/Grammar
$(PGEN): $(PGEN):
cd $(PGENDIR); make pgen cd $(PGENDIR); $(MAKE) pgen
clean: clean:
-rm -f *.o core *~ [@,#]* *.old *.orig *.rej -rm -f *.o core *~ [@,#]* *.old *.orig *.rej
......
...@@ -196,8 +196,7 @@ libpython$(VERSION).dylib: $(LIBRARY) ...@@ -196,8 +196,7 @@ libpython$(VERSION).dylib: $(LIBRARY)
$(SUBDIRS): Makefiles $(SUBDIRS): Makefiles
Grammar: Grammar:
P=`pwd`/Parser; cd $(srcdir)/Grammar; $(MAKE) PGENDIR=$$P \ cd Grammar ; $(MAKE) OPT="$(OPT)" VERSION="$(VERSION)" \
OPT="$(OPT)" VERSION="$(VERSION)" \
prefix="$(prefix)" exec_prefix="$(exec_prefix)" all prefix="$(prefix)" exec_prefix="$(exec_prefix)" all
Parser: Parser:
......
...@@ -1167,6 +1167,7 @@ AC_CHECK_TYPE(socklen_t, int) ...@@ -1167,6 +1167,7 @@ AC_CHECK_TYPE(socklen_t, int)
AC_OUTPUT(Makefile \ AC_OUTPUT(Makefile \
Objects/Makefile \ Objects/Makefile \
Parser/Makefile \ Parser/Makefile \
Grammar/Makefile \
Python/Makefile \ Python/Makefile \
Modules/Makefile.pre \ Modules/Makefile.pre \
Modules/Setup.config) Modules/Setup.config)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment