1 #-------------------------------------------------------------------
3 # Makefile for src/interfaces/python, a.k.a. "PyGreSQL"
5 # Written by Peter Eisentraut <peter_e@gmx.net>
7 # $Header: /cvsroot/pgsql/src/interfaces/python/Attic/GNUmakefile.in,v 1.1 2000/06/10 18:02:00 petere Exp $
9 #-------------------------------------------------------------------
14 top_srcdir = @top_srcdir@
15 top_builddir = ../../..
19 exec_prefix = @exec_prefix@
21 includedir = @includedir@
24 INSTALL_DATA = @INSTALL_DATA@
29 python_extmakefile = @python_extmakefile@
30 python_moduledir = @python_moduledir@
33 all: Makefile pgmodule.c libpq-all
37 $(MAKE) -C $(top_builddir)/src/interfaces/libpq all
39 Makefile: Setup.in Makefile.pre.in
40 $(MAKE) -f Makefile.pre.in boot srcdir=$(srcdir) VPATH=$(srcdir)
42 Makefile.pre.in: $(python_extmakefile)
45 Setup.in: Setup.in.raw
46 sed -e "s%__LIBPQ__%${top_srcdir}/src/interfaces/libpq%g" \
47 -e "s%__EXTRA_LIBS__%${LIBS}%g" \
48 -e "s%__INCLUDES__%${top_srcdir}/src/include%g" \
52 @echo "Installing Python module"
53 @if ! ( $(INSTALL_DATA) pg.py $(python_moduledir) && \
54 $(MAKE) -f Makefile install ); then \
56 echo "* Skipping the installation of the Python interface module for lack"; \
57 echo "* of permissions. To install it, change to the directory"; \
58 echo "* "`pwd`", become the appropriate"; \
59 echo "* user, and do \`$(MAKE) install'."; \
64 # Python sometimes has a different idea what exactly "clean" is.
67 -[ -f Makefile ] && $(MAKE) -f Makefile clobber
68 rm -f Makefile.pre.in Makefile Setup Setup.in
70 distclean maintainer-clean: clean
74 .PHONY: all libpq-all install clean distclean maintainer-clean