diff options
author | Jamie Bullock <postlude@users.sourceforge.net> | 2007-11-06 09:59:03 +0000 |
---|---|---|
committer | Jamie Bullock <postlude@users.sourceforge.net> | 2007-11-06 09:59:03 +0000 |
commit | 4aa74035b7f37d9cd1208efe06ce245f73b5dd18 (patch) | |
tree | 854c9ebf07e47c2408a359e601fd300f27a9c202 /psql/Makefile | |
parent | 523bac5887143597042338112f742fa19cd93ce9 (diff) |
psql external initial commit
svn path=/trunk/externals/postlude/; revision=8946
Diffstat (limited to 'psql/Makefile')
-rw-r--r-- | psql/Makefile | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/psql/Makefile b/psql/Makefile new file mode 100644 index 0000000..f4084e3 --- /dev/null +++ b/psql/Makefile @@ -0,0 +1,57 @@ +NAME=psql +CSYM=psql + +PDDIR=/usr/local/lib/pd +INCLUDE = -I/usr/include/postgresql + +all: pd_linux +current: pd_linux + +LDFLAGS = -lc -lm -lpq + +# Postgres ---------------------- + +SRCDIR= /usr/include +TARGDIR= ./ + +#include Makefile.global #needed for postgresql stuff + +# Linux ---------------------------------------------- + +pd_linux: $(NAME).pd_linux + +.SUFFIXES: .pd_linux + +LINUXCFLAGS = -g -DPD -O0 -fPIC -funroll-loops -fomit-frame-pointer \ + -Wall -W -Wshadow -Wstrict-prototypes -Werror \ + -Wno-unused -Wno-parentheses -Wno-switch + +.c.pd_linux: + $(CC) $(LINUXCFLAGS) $(INCLUDE) -o $*.o -c $*.c + $(CC) -export_dynamic -shared -o $*.pd_linux $*.o $(LDFLAGS) + strip --strip-unneeded $*.pd_linux + rm $*.o + +# Darwin ---------------------------------------------- + +pd_darwin: $(NAME).pd_darwin + +.SUFFIXES: .pd_darwin + +DARWINCFLAGS = -DPD -O3 -Wall -W -Wshadow -Wstrict-prototypes \ + -Wno-unused -Wno-parentheses -Wno-switch -L/usr/local/lib/ + +.c.pd_darwin: + $(CC) $(DARWINCFLAGS) $(INCLUDE) -o $*.o -c $*.c + $(CC) -bundle -undefined dynamic_lookup -o $(NAME).pd_darwin $*.o $(LDFLAGS) + rm -f *.o + +# Install ---------------------------------------------- + +install: + cp $(NAME).pd_* $(PDDIR)/extra/ + +# Clean ---------------------------------------------- + +clean: + rm -f *.pd_* *.o |