]> granicus.if.org Git - postgresql/blobdiff - src/pl/Makefile
Some more FLEXIBLE_ARRAY_MEMBER fixes.
[postgresql] / src / pl / Makefile
index aefd06707b899316ad8d59007211c9b7850aed04..c4a0d1cd07abdef10d3dec960415bbfc49790e8f 100644 (file)
@@ -1,49 +1,36 @@
 #-------------------------------------------------------------------------
 #
-# Makefile
-#    Makefile for src/pl (procedural languages)
+# Makefile for src/pl (procedural languages)
 #
 # Copyright (c) 1994, Regents of the University of California
 #
-#
-# IDENTIFICATION
-#    $Header: /cvsroot/pgsql/src/pl/Makefile,v 1.4 2000/03/25 14:25:31 momjian Exp $
+# src/pl/Makefile
 #
 #-------------------------------------------------------------------------
 
-SRCDIR= ..
-include $(SRCDIR)/Makefile.global
+subdir = src/pl
+top_builddir = ../..
+include $(top_builddir)/src/Makefile.global
 
+SUBDIRS = plpgsql
 
-.DEFAULT all install clean dep depend distclean:
-       $(MAKE) -C plpgsql $@
-ifeq ($(USE_TCL), true)
-       $(MAKE) -C tcl $@
-endif
-ifeq ($(USE_PERL), true)
-       -@if [ "$@" = "install" ]; then \
-               $(MAKE) $(MFLAGS) install-plperl; \
-       else \
-               $(MAKE) $(MFLAGS) plperl/Makefile; \
-               $(MAKE) $(MFLAGS) -C plperl $@; \
-       fi
+ifeq ($(with_perl), yes)
+SUBDIRS += plperl
+else
+ALWAYS_SUBDIRS += plperl
 endif
 
-plperl/Makefile: plperl/Makefile.PL
-       cd plperl && $(PERL) Makefile.PL POLLUTE=1
-
-install-plperl: plperl/Makefile
-       $(MAKE) -C plperl clean
-       cd plperl && POSTGRES_HOME="$(POSTGRESDIR)" $(PERL) Makefile.PL POLLUTE=1
-       $(MAKE) -C plperl all
-       -@if [ -w `sed -n -e 's/^ *INSTALLSITELIB *= *//p' plperl/Makefile` ]; then \
-               $(MAKE) $(MFLAGS) -C plperl install; \
-               rm -f plperl/Makefile; \
-       else \
-               echo "Skipping install of Perl module for lack of permissions."; \
-               echo "To install it, cd into interfaces/plperl, su to become the"; \
-               echo "appropriate user, and do '$(MAKE) install'."; \
-       fi
+ifeq ($(with_python), yes)
+SUBDIRS += plpython
+else
+ALWAYS_SUBDIRS += plpython
+endif
 
-.PHONY: install-plperl
+ifeq ($(with_tcl), yes)
+SUBDIRS += tcl
+else
+ALWAYS_SUBDIRS += tcl
+endif
 
+$(recurse)
+$(recurse_always)