diff options
author | toshii <toshii@pkgsrc.org> | 2003-04-03 18:06:12 +0000 |
---|---|---|
committer | toshii <toshii@pkgsrc.org> | 2003-04-03 18:06:12 +0000 |
commit | fe36e8843c0be8306ca4169f3a948af04ae0d43a (patch) | |
tree | 1d12e4507e9aae8fc7bb57c27562397c13cd9dcc /databases/postgresql/patches/patch-ah | |
parent | 6801ee7245b0965ed412c0b29dca2436bfa8f217 (diff) | |
download | pkgsrc-fe36e8843c0be8306ca4169f3a948af04ae0d43a.tar.gz |
Build py-postgresql from the postgresql 7.3.2 tarball. PKGREVISION++
Remove files and patches in the py-postgresql directory and add necessary
ones in the postgresql directory.
Diffstat (limited to 'databases/postgresql/patches/patch-ah')
-rw-r--r-- | databases/postgresql/patches/patch-ah | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/databases/postgresql/patches/patch-ah b/databases/postgresql/patches/patch-ah new file mode 100644 index 00000000000..21d3933420c --- /dev/null +++ b/databases/postgresql/patches/patch-ah @@ -0,0 +1,43 @@ +$NetBSD: patch-ah,v 1.12 2003/04/03 18:06:13 toshii Exp $ + +--- src/interfaces/python/GNUmakefile.orig Thu Dec 13 13:39:04 2001 ++++ src/interfaces/python/GNUmakefile +@@ -19,7 +19,14 @@ include $(top_srcdir)/src/Makefile.shlib + + override CPPFLAGS := -I$(libpq_srcdir) $(CPPFLAGS) $(python_includespec) + +-all: all-lib ++PY_SCRIPTS = pg.py pgdb.py ++ifeq ($(with_python_compile), yes) ++PY_COMPILED_SCRIPTS = $(PY_SCRIPTS:%.py=%.pyc) $(PY_SCRIPTS:%.py=%.pyo) ++else ++PY_COMPILED_SCRIPTS = ++endif ++ ++all: all-lib $(PY_COMPILED_SCRIPTS) + + all-lib: libpq-all + +@@ -27,6 +34,12 @@ all-lib: libpq-all + libpq-all: + $(MAKE) -C $(libpq_builddir) all + ++%.pyc: %.py ++ $(PYTHON) -c "import py_compile; py_compile.compile(\"$<\")" ++ ++%.pyo: %.py ++ $(PYTHON) -O -c "import py_compile; py_compile.compile(\"$<\")" ++ + install-warning-msg := { \ + echo "*** Skipping the installation of the Python interface module for lack"; \ + echo "*** of permissions. To install it, change to the directory"; \ +@@ -35,6 +48,9 @@ echo "*** become the appropriate user, a + + install: all installdirs + @if test -w $(DESTDIR)$(python_moduleexecdir) && test -w $(DESTDIR)$(python_moduledir); then \ ++ for i in $(PY_SCRIPTS) $(PY_COMPILED_SCRIPTS); do \ ++ $(INSTALL_DATA) $$i $(python_moduledir) ; \ ++ done ; \ + echo "$(INSTALL_SHLIB) $(shlib) $(DESTDIR)$(python_moduleexecdir)/_pgmodule$(DLSUFFIX)"; \ + $(INSTALL_SHLIB) $(shlib) $(DESTDIR)$(python_moduleexecdir)/_pgmodule$(DLSUFFIX); \ + \ |