| 1 |
1 |
dpavlin |
dir=`pwd` |
| 2 |
|
|
code=pgest |
| 3 |
|
|
|
| 4 |
59 |
dpavlin |
pod2html=pod2xhtml.pl --top '' |
| 5 |
75 |
dpavlin |
cite2href=sed -e 's!<cite>\([^>]*\)</cite>!<a href=\"\1.html\">\1</a>!g' |
| 6 |
59 |
dpavlin |
|
| 7 |
36 |
dpavlin |
all: install |
| 8 |
1 |
dpavlin |
psql test < pgest.sql |
| 9 |
|
|
cat test.sql | sed "s,##dir##,${dir}," | psql test |
| 10 |
|
|
|
| 11 |
|
|
clean: |
| 12 |
33 |
dpavlin |
rm -Rf data/casket *.o *.so doc |
| 13 |
1 |
dpavlin |
|
| 14 |
|
|
index: |
| 15 |
7 |
dpavlin |
cd data && make index |
| 16 |
1 |
dpavlin |
|
| 17 |
|
|
install: ${code}.so |
| 18 |
|
|
sudo cp ${code}.so `pg_config --pkglibdir` |
| 19 |
6 |
dpavlin |
|
| 20 |
|
|
test: |
| 21 |
|
|
perl -e 'use Test::Harness qw(&runtests $$verbose); $$verbose=0; runtests @ARGV;' t/*.t |
| 22 |
15 |
dpavlin |
|
| 23 |
|
|
html: |
| 24 |
23 |
dpavlin |
test -d doc || mkdir doc |
| 25 |
59 |
dpavlin |
${pod2html} < Tutorial.pod | ${cite2href} > doc/Tutorial.html |
| 26 |
|
|
${pod2html} < README.pod | ${cite2href} > doc/pgestraier.html |
| 27 |
75 |
dpavlin |
${pod2html} < bin/pgest-index.pl | ${cite2href} > doc/pgest-index.html |
| 28 |
|
|
svk update && svn2html.pl > doc/ChangeLog.html |
| 29 |
28 |
dpavlin |
|
| 30 |
76 |
dpavlin |
cvs: html |
| 31 |
28 |
dpavlin |
svn2cvs.pl file:///home/dpavlin/private/svn/pgestraier/trunk/ :ext:dpavlin@cvs.pgfoundry.org:/cvsroot/pgestraier pgestraier |
| 32 |
75 |
dpavlin |
test -d doc && rsync -ra doc/ pgfoundry.org:/home/pgfoundry.org/groups/pgestraier/htdocs/ && ssh pgfoundry.org ln -sf /home/pgfoundry.org/groups/pgestraier/htdocs/pgestraier.html /home/pgfoundry.org/groups/pgestraier/htdocs/index.html || true |
| 33 |
36 |
dpavlin |
|
| 34 |
|
|
%.o: %.c |
| 35 |
|
|
@echo $@ $< $^ |
| 36 |
56 |
dpavlin |
cc -Wall -I`pg_config --includedir-server` -fpic -c $< `estconfig --cflags || pkg-config hyperestraier --cflags` |
| 37 |
36 |
dpavlin |
|
| 38 |
|
|
%.so: %.o |
| 39 |
|
|
@echo $@ $< $^ |
| 40 |
|
|
cc -shared `estconfig --ldflags` `estconfig --libs` -o $@ $< |
| 41 |
|
|
|