summaryrefslogtreecommitdiff
path: root/contrib/pgbench
diff options
context:
space:
mode:
authorPeter Eisentraut <peter_e@gmx.net>2001-09-06 10:49:30 +0000
committerPeter Eisentraut <peter_e@gmx.net>2001-09-06 10:49:30 +0000
commit17cc78ef01679deae3f0dac1c35ae777c2c73723 (patch)
tree57c116d4f29272878495dc748a14cb7249f5dc7c /contrib/pgbench
parent22ae53d4cdca7244b0de25f1d28255e1649aa936 (diff)
downloadpostgresql-17cc78ef01679deae3f0dac1c35ae777c2c73723.tar.gz
To fix the perpetually broken makefiles in the contrib tree, I have
written a generic framework of rules that the contrib makefiles can use instead of writing their own each time. You only need to set a few variables and off you go.
Diffstat (limited to 'contrib/pgbench')
-rw-r--r--contrib/pgbench/Makefile34
1 files changed, 6 insertions, 28 deletions
diff --git a/contrib/pgbench/Makefile b/contrib/pgbench/Makefile
index 157e9c168c..e52e577931 100644
--- a/contrib/pgbench/Makefile
+++ b/contrib/pgbench/Makefile
@@ -1,37 +1,15 @@
-#
-# $Header: /cvsroot/pgsql/contrib/pgbench/Makefile,v 1.9 2001/02/20 19:20:27 petere Exp $
-#
+# $Header: /cvsroot/pgsql/contrib/pgbench/Makefile,v 1.10 2001/09/06 10:49:30 petere Exp $
subdir = contrib/pgbench
top_builddir = ../..
include $(top_builddir)/src/Makefile.global
-override CPPFLAGS := -I$(libpq_srcdir) $(CPPFLAGS)
-
+PROGRAM = pgbench
OBJS = pgbench.o
-all: pgbench
-
-pgbench: $(OBJS) $(libpq_builddir)/libpq.a
- $(CC) $(CFLAGS) $(OBJS) $(libpq) $(LDFLAGS) $(LIBS) -o $@
-
-install: all installdirs
- $(INSTALL_PROGRAM) pgbench$(X) $(bindir)
- $(INSTALL_DATA) README.pgbench $(docdir)/contrib
- $(INSTALL_DATA) README.pgbench_jis $(docdir)/contrib
-
-installdirs:
- $(mkinstalldirs) $(bindir) $(docdir)/contrib
-
-uninstall:
- rm -f $(bindir)/pgbench$(X) $(docdir)/contrib/README.pgbench $(docdir)/contrib/README.pgbench_jis
-
-clean distclean maintainer-clean:
- rm -f pgbench$(X) $(OBJS)
+PG_CPPFLAGS = -I$(libpq_srcdir)
+PG_LIBS = $(libpq)
-depend dep:
- $(CC) -MM -MG $(CFLAGS) *.c > depend
+DOCS = README.pgbench README.pgbench_jis
-ifeq (depend,$(wildcard depend))
-include depend
-endif
+include $(top_srcdir)/contrib/contrib-global.mk