# Main Makefile for pgbrowse.  It assumes, that there is a precompiled
# wishpqx binary in bin/Linux, so this isn't remade.  If you want to
# compile wishpqx yourself, cd into the src dir, and type "make install".


# where things go:
prefix=/usr/local/postgres
manext=1
mandir=$(prefix)/man/man$(manext)
bindir=$(prefix)/bin
pgbrowsedir=`pwd`


all:


install:
	sed -e "s?@PGBROWSE@?$(pgbrowsedir)?" bin/pgbrowse.sh >$(bindir)/pgbrowse
	chmod 755 $(bindir)/pgbrowse
	cp man/man1/pgbrowse.1 $(mandir)/pgbrowse.$(manext)
	chmod 644 $(mandir)/pgbrowse.$(manext)
