summaryrefslogtreecommitdiffstats
path: root/src/bin/pg_dump/Makefile
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 13:44:03 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 13:44:03 +0000
commit293913568e6a7a86fd1479e1cff8e2ecb58d6568 (patch)
treefc3b469a3ec5ab71b36ea97cc7aaddb838423a0c /src/bin/pg_dump/Makefile
parentInitial commit. (diff)
downloadpostgresql-16-293913568e6a7a86fd1479e1cff8e2ecb58d6568.tar.xz
postgresql-16-293913568e6a7a86fd1479e1cff8e2ecb58d6568.zip
Adding upstream version 16.2.upstream/16.2
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/bin/pg_dump/Makefile')
-rw-r--r--src/bin/pg_dump/Makefile74
1 files changed, 74 insertions, 0 deletions
diff --git a/src/bin/pg_dump/Makefile b/src/bin/pg_dump/Makefile
new file mode 100644
index 0000000..24de759
--- /dev/null
+++ b/src/bin/pg_dump/Makefile
@@ -0,0 +1,74 @@
+#-------------------------------------------------------------------------
+#
+# Makefile for src/bin/pg_dump
+#
+# Portions Copyright (c) 1996-2023, PostgreSQL Global Development Group
+# Portions Copyright (c) 1994, Regents of the University of California
+#
+# src/bin/pg_dump/Makefile
+#
+#-------------------------------------------------------------------------
+
+PGFILEDESC = "pg_dump/pg_restore/pg_dumpall - backup and restore PostgreSQL databases"
+PGAPPICON=win32
+
+subdir = src/bin/pg_dump
+top_builddir = ../../..
+include $(top_builddir)/src/Makefile.global
+
+export GZIP_PROGRAM=$(GZIP)
+export LZ4
+export ZSTD
+export with_icu
+
+override CPPFLAGS := -I$(libpq_srcdir) $(CPPFLAGS)
+LDFLAGS_INTERNAL += -L$(top_builddir)/src/fe_utils -lpgfeutils $(libpq_pgport)
+
+OBJS = \
+ $(WIN32RES) \
+ compress_gzip.o \
+ compress_io.o \
+ compress_lz4.o \
+ compress_none.o \
+ compress_zstd.o \
+ dumputils.o \
+ parallel.o \
+ pg_backup_archiver.o \
+ pg_backup_custom.o \
+ pg_backup_db.o \
+ pg_backup_directory.o \
+ pg_backup_null.o \
+ pg_backup_tar.o \
+ pg_backup_utils.o
+
+all: pg_dump pg_restore pg_dumpall
+
+pg_dump: pg_dump.o common.o pg_dump_sort.o $(OBJS) | submake-libpq submake-libpgport submake-libpgfeutils
+ $(CC) $(CFLAGS) pg_dump.o common.o pg_dump_sort.o $(OBJS) $(LDFLAGS) $(LDFLAGS_EX) $(LIBS) -o $@$(X)
+
+pg_restore: pg_restore.o $(OBJS) | submake-libpq submake-libpgport submake-libpgfeutils
+ $(CC) $(CFLAGS) pg_restore.o $(OBJS) $(LDFLAGS) $(LDFLAGS_EX) $(LIBS) -o $@$(X)
+
+pg_dumpall: pg_dumpall.o dumputils.o $(WIN32RES) | submake-libpq submake-libpgport submake-libpgfeutils
+ $(CC) $(CFLAGS) pg_dumpall.o dumputils.o $(WIN32RES) $(LDFLAGS) $(LDFLAGS_EX) $(LIBS) -o $@$(X)
+
+install: all installdirs
+ $(INSTALL_PROGRAM) pg_dump$(X) '$(DESTDIR)$(bindir)'/pg_dump$(X)
+ $(INSTALL_PROGRAM) pg_restore$(X) '$(DESTDIR)$(bindir)'/pg_restore$(X)
+ $(INSTALL_PROGRAM) pg_dumpall$(X) '$(DESTDIR)$(bindir)'/pg_dumpall$(X)
+
+installdirs:
+ $(MKDIR_P) '$(DESTDIR)$(bindir)'
+
+check:
+ $(prove_check)
+
+installcheck:
+ $(prove_installcheck)
+
+uninstall:
+ rm -f $(addprefix '$(DESTDIR)$(bindir)'/, pg_dump$(X) pg_restore$(X) pg_dumpall$(X))
+
+clean distclean maintainer-clean:
+ rm -f pg_dump$(X) pg_restore$(X) pg_dumpall$(X) $(OBJS) pg_dump.o common.o pg_dump_sort.o pg_restore.o pg_dumpall.o
+ rm -rf tmp_check