1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-06 13:46:51 +03:00

Turn on plpython build by default if we have something that looks like a

shared library, or we can do without one.
This commit is contained in:
Peter Eisentraut
2001-08-27 00:29:49 +00:00
parent af70014686
commit 42ae4f2940
3 changed files with 29 additions and 7 deletions

View File

@@ -1,10 +1,21 @@
# $Header: /cvsroot/pgsql/src/pl/plpython/Makefile,v 1.8 2001/07/10 16:33:02 petere Exp $
# $Header: /cvsroot/pgsql/src/pl/plpython/Makefile,v 1.9 2001/08/27 00:29:49 petere Exp $
subdir = src/pl/plpython
top_builddir = ../../..
include $(top_builddir)/src/Makefile.global
# On some platforms we can only build PL/Python if libpython is a
# shared library. Since there is no official way to determine this,
# we see if there is a file that is named like a shared library.
ifneq (,$(wildcard $(python_configdir)/libpython*$(DLSUFFIX)*))
shared_libpython = yes
endif
# If we don't have a shared library and the platform doesn't allow it
# to work without, we have to skip it.
ifneq (,$(findstring yes, $(shared_libpython)$(allow_nonpic_in_shlib)))
override CPPFLAGS := -I$(srcdir) $(python_includespec) $(CPPFLAGS)
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
@@ -36,3 +47,14 @@ clean distclean maintainer-clean: clean-lib
installcheck:
PATH=$(bindir):$$PATH $(SHELL) $(srcdir)/test.sh
else # can't build
all:
@echo ""; \
echo "*** Cannot build PL/Python because libpython is not a shared library." ; \
echo "*** You might have to rebuild your Python installation. Refer to"; \
echo "*** the documentation for details."; \
echo ""
endif # can't build