mirror of https://github.com/postgres/postgres
parent
6da92d94bc
commit
676404d5dc
@ -1,32 +0,0 @@ |
||||
#
|
||||
# Makefile
|
||||
#
|
||||
#
|
||||
PGINTERFACE = pginterface.o halt.o
|
||||
TARGET = pginsert pgwordcount pgnulltest
|
||||
CFLAGS = -g -Wall -I. -I../../src/interfaces/libpq -I/usr/local/pgsql/include
|
||||
LDFLAGS = -L/usr/local/pgsql/lib -lpq
|
||||
|
||||
all : $(TARGET) |
||||
|
||||
pginsert: $(PGINTERFACE) pginsert.c |
||||
gcc -o $@ $(CFLAGS) $@.c $(PGINTERFACE) $(LDFLAGS)
|
||||
|
||||
pgwordcount: $(PGINTERFACE) pgwordcount.c |
||||
gcc -o $@ $(CFLAGS) $@.c $(PGINTERFACE) $(LDFLAGS)
|
||||
|
||||
pgnulltest: $(PGINTERFACE) pgnulltest.c |
||||
gcc -o $@ $(CFLAGS) $@.c $(PGINTERFACE) $(LDFLAGS)
|
||||
|
||||
pginterface.o: pginterface.c |
||||
gcc -c $(CFLAGS) pginterface.c
|
||||
|
||||
halt.o: halt.c |
||||
gcc -c $(CFLAGS) halt.c
|
||||
|
||||
clean: |
||||
rm -f *.o $(TARGET) log core
|
||||
|
||||
install: |
||||
install -s -o bin -g bin $(TARGET) /usr/local/pgsql/bin
|
||||
|
||||
@ -1,15 +0,0 @@ |
||||
|
||||
|
||||
Pginterface 2.0 |
||||
|
||||
Attached is a copy of the Postgres support routines I wrote to allow me |
||||
to more cleanly interface to the libpg library, more like a 4gl SQL |
||||
interface. |
||||
|
||||
You can create a library of pginterface.c and halt.c, and just include |
||||
pginterface.h in your source code. |
||||
|
||||
I am willing to maintain this if people find problems or want additional |
||||
functionality. |
||||
|
||||
Bruce Momjian (root@candle.pha.pa.us) |
||||
@ -0,0 +1,89 @@ |
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Makefile
|
||||
# Makefile for pgeasy library
|
||||
#
|
||||
# IDENTIFICATION
|
||||
# $Header: /cvsroot/pgsql/src/interfaces/pgeasy/Attic/Makefile.in,v 1.1 1999/10/11 17:47:01 momjian Exp $
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
|
||||
NAME= pgeasy
|
||||
SO_MAJOR_VERSION= 2
|
||||
SO_MINOR_VERSION= 0
|
||||
|
||||
SRCDIR= @top_srcdir@
|
||||
include $(SRCDIR)/Makefile.global |
||||
|
||||
ifdef KRBVERS |
||||
CFLAGS+= $(KRBFLAGS)
|
||||
endif |
||||
|
||||
OBJS= pgeasy.o halt.o
|
||||
|
||||
SHLIB_LINK+= -L../libpq -lpq
|
||||
|
||||
SHLIB_LINK+= -L../libpq -lpq
|
||||
|
||||
# If crypt is a separate library, rather than part of libc, it may need
|
||||
# to be referenced separately to keep (broken) linkers happy. (This is
|
||||
# braindead; users of libpq should not need to know what it depends on.)
|
||||
SHLIB_LINK+= $(findstring -lcrypt,$(LIBS))
|
||||
|
||||
# Shared library stuff, also default 'all' target
|
||||
include $(SRCDIR)/Makefile.shlib |
||||
|
||||
|
||||
.PHONY: install install-headers |
||||
|
||||
install: install-headers install-lib $(install-shlib-dep) |
||||
|
||||
install-headers: pgeasy.h |
||||
@if [ ! -d $(HEADERDIR) ]; then mkdir $(HEADERDIR); fi
|
||||
$(INSTALL) $(INSTLOPTS) pgeasy.h $(HEADERDIR)/pgeasy.h
|
||||
|
||||
.PHONY: clean |
||||
|
||||
clean: clean-shlib |
||||
rm -f lib$(NAME).a $(OBJS)
|
||||
|
||||
depend dep: |
||||
$(CC) -MM $(CFLAGS) *.c >depend
|
||||
|
||||
ifeq (depend,$(wildcard depend)) |
||||
include depend |
||||
endif |
||||
|
||||
|
||||
|
||||
PGEASY = pgeasy.o halt.o
|
||||
TARGET = libpgeasy.a pginsert pgwordcount pgnulltest
|
||||
CFLAGS = -g -Wall -I. -I../../src/interfaces/libpq -I/usr/local/pgsql/include
|
||||
LDFLAGS = -L/usr/local/pgsql/lib -lpq
|
||||
|
||||
all : $(TARGET) |
||||
|
||||
libpgeasy.a: pgeasy.o halt.o |
||||
ar r libpgeasy.a pgeasy.o halt.o
|
||||
|
||||
pgeasy.o: pgeasy.c |
||||
gcc -c $(CFLAGS) pgeasy.c
|
||||
|
||||
halt.o: halt.c |
||||
gcc -c $(CFLAGS) halt.c
|
||||
|
||||
pginsert: $(PGEASY) pginsert.c |
||||
gcc -o $@ $(CFLAGS) $@.c $(PGEASY) $(LDFLAGS)
|
||||
|
||||
pgwordcount: $(PGEASY) pgwordcount.c |
||||
gcc -o $@ $(CFLAGS) $@.c $(PGEASY) $(LDFLAGS)
|
||||
|
||||
pgnulltest: $(PGEASY) pgnulltest.c |
||||
gcc -o $@ $(CFLAGS) $@.c $(PGEASY) $(LDFLAGS)
|
||||
|
||||
clean: |
||||
rm -f *.o $(TARGET) log core
|
||||
|
||||
install: |
||||
install -s -o bin -g bin $(TARGET) /usr/local/pgsql/bin
|
||||
|
||||
@ -0,0 +1,10 @@ |
||||
|
||||
|
||||
Pgeasy 2.0 |
||||
(Formerly contrib/pginterface) |
||||
|
||||
Attached is a copy of the Postgres support routines I wrote to allow me |
||||
to more cleanly interface to the libpg library, more like a 4gl SQL |
||||
interface. |
||||
|
||||
Bruce Momjian (root@candle.pha.pa.us) |
||||
@ -0,0 +1,27 @@ |
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Makefile
|
||||
# Makefile for pgeasy examples
|
||||
#
|
||||
# IDENTIFICATION
|
||||
# $Header: /cvsroot/pgsql/src/interfaces/pgeasy/examples/Attic/Makefile,v 1.1 1999/10/11 17:47:02 momjian Exp $
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
|
||||
TARGET = pginsert pgwordcount pgnulltest
|
||||
LDFLAGS = -lpgeasy
|
||||
|
||||
all : $(TARGET) |
||||
|
||||
pginsert: |
||||
gcc -o $@ $(CFLAGS) $@.c $(PGEASY) $(LDFLAGS)
|
||||
|
||||
pgwordcount: |
||||
gcc -o $@ $(CFLAGS) $@.c $(PGEASY) $(LDFLAGS)
|
||||
|
||||
pgnulltest: |
||||
gcc -o $@ $(CFLAGS) $@.c $(PGEASY) $(LDFLAGS)
|
||||
|
||||
clean: |
||||
rm -f *.o $(TARGET) log core
|
||||
|
||||
Loading…
Reference in new issue