2011-01-18 01:33:27 +00:00
|
|
|
# View README.pg_filedump first
|
|
|
|
|
2012-03-12 16:08:33 +00:00
|
|
|
# note this must match version macros in pg_filedump.h
|
|
|
|
FD_VERSION=9.2.0
|
2011-11-26 22:14:08 +00:00
|
|
|
|
2011-01-18 01:33:27 +00:00
|
|
|
CC=gcc
|
|
|
|
CFLAGS=-g -O -Wall -Wmissing-prototypes -Wmissing-declarations
|
|
|
|
|
2012-03-12 16:08:33 +00:00
|
|
|
# If working with a PG source directory, point PGSQL_INCLUDE_DIR to its
|
|
|
|
# src/include subdirectory. If working with an installed tree, point to
|
|
|
|
# the server include subdirectory, eg /usr/local/include/postgresql/server
|
|
|
|
PGSQL_INCLUDE_DIR=../../pgsql/src/include
|
2011-01-18 02:28:26 +00:00
|
|
|
|
2011-01-18 01:33:27 +00:00
|
|
|
|
2011-11-26 22:14:08 +00:00
|
|
|
DISTFILES= README.pg_filedump Makefile Makefile.contrib \
|
|
|
|
pg_filedump.h pg_filedump.c
|
|
|
|
|
2011-01-18 01:33:27 +00:00
|
|
|
all: pg_filedump
|
|
|
|
|
2012-03-12 16:08:33 +00:00
|
|
|
pg_filedump: pg_filedump.o
|
|
|
|
${CC} ${CFLAGS} -o pg_filedump pg_filedump.o
|
2011-01-18 01:33:27 +00:00
|
|
|
|
|
|
|
pg_filedump.o: pg_filedump.c
|
2012-03-12 16:08:33 +00:00
|
|
|
${CC} ${CFLAGS} -I${PGSQL_INCLUDE_DIR} pg_filedump.c -c
|
2011-01-18 01:33:27 +00:00
|
|
|
|
2011-11-26 22:14:08 +00:00
|
|
|
dist:
|
|
|
|
rm -rf pg_filedump-${FD_VERSION} pg_filedump-${FD_VERSION}.tar.gz
|
|
|
|
mkdir pg_filedump-${FD_VERSION}
|
|
|
|
cp -p ${DISTFILES} pg_filedump-${FD_VERSION}
|
|
|
|
tar cfz pg_filedump-${FD_VERSION}.tar.gz pg_filedump-${FD_VERSION}
|
|
|
|
rm -rf pg_filedump-${FD_VERSION}
|
|
|
|
|
2011-01-18 01:33:27 +00:00
|
|
|
clean:
|
2011-01-18 02:28:26 +00:00
|
|
|
rm -f *.o pg_filedump
|