source: trunk/Makefile@ 920

Last change on this file since 920 was 910, checked in by Kris Deugau, 7 years ago

/trunk

Start adding POD semi-automatic documentation for APIs

  • Property svn:keywords set to Id
File size: 4.9 KB
RevLine 
[417]1# $Id: Makefile 910 2017-08-17 21:46:33Z kdeugau $
2# IPDB makefile
3
4PKGNAME=ipdb
[894]5VERSION=3.0
[417]6RELEASE=1
7
8# Include some boilerplate Gnu makefile definitions.
9prefix = /usr/local
10
11exec_prefix = ${prefix}
12bindir = ${exec_prefix}/bin
13libdir = ${exec_prefix}/lib
14infodir = ${prefix}/info
15includedir = ${prefix}/include
16datadir = ${prefix}/share
17localedir = $(datadir)/locale
18sysconfdir = ${prefix}/etc
19mandir = ${prefix}/man
20
21INSTALL = /usr/bin/install -c
22INSTALL_PROGRAM = ${INSTALL}
23INSTALL_SCRIPT = ${INSTALL}
24INSTALL_DATA = ${INSTALL} -m 644
25INSTALLMODE= -m 0755
26INSTALLMODE2 = -m 0555
27
28DESTDIR =
29
[910]30GENDOCS = \
31 docs/search-rpc.html
32
[417]33HTML = \
[861]34 alloctypes.html help.html index.shtml ipdb.css rDNS.html
[417]35
[517]36JS = templates/widgets.js
37
[848]38IMAGES = images/logo.png images/tree_closed.png images/tree_open.png
[417]39
[517]40TEMPLATES = \
[843]41 templates/aclerror.tmpl templates/addmaster.tmpl templates/addvrf.tmpl templates/assign.tmpl \
42 templates/confirm.tmpl templates/confmerge.tmpl templates/dberr.tmpl templates/delete.tmpl \
43 templates/delvrf.tmpl templates/domerge.tmpl templates/dosplit.tmpl templates/dunno.tmpl \
44 templates/edit.tmpl templates/finaldelete.tmpl templates/finaldelvrf.tmpl templates/footer.tmpl \
45 templates/header.tmpl templates/index2.tmpl templates/index.tmpl templates/insert.tmpl \
46 templates/listpool.tmpl templates/merge.tmpl templates/newcity.tmpl templates/newmaster.tmpl \
47 templates/newnode.tmpl templates/newvrf.tmpl templates/nodesearch.tmpl templates/showsubs2.tmpl \
48 templates/showsubs.tmpl templates/showvrf.tmpl templates/split.tmpl templates/subnet-calc.tmpl \
49 templates/update.tmpl templates/utilbar.tmpl \
[517]50 \
51 templates/admin/aclerr.tmpl templates/admin/addnotice.tmpl templates/admin/alloc.tmpl \
52 templates/admin/alloctweak.tmpl templates/admin/confirm.tmpl templates/admin/dberr.tmpl \
53 templates/admin/delnotice.tmpl templates/admin/deluser.tmpl templates/admin/dunno.tmpl \
54 templates/admin/edcust.tmpl templates/admin/ednotice.tmpl templates/admin/emailnotice.tmpl \
55 templates/admin/header.tmpl templates/admin/listcust.tmpl templates/admin/main.tmpl \
56 templates/admin/newuser.tmpl templates/admin/showallocs.tmpl templates/admin/showpools.tmpl \
57 templates/admin/showusers.tmpl templates/admin/touch.tmpl templates/admin/tweakpool.tmpl \
58 templates/admin/updacl.tmpl templates/admin/updatepool.tmpl templates/admin/update.tmpl \
59 templates/admin/updcust.tmpl templates/admin/updnotice.tmpl \
60 \
61 templates/search/compsearch.tmpl templates/search/sresults.tmpl
62
[417]63SCRIPTS = \
[846]64 cgi-bin/access-pwd-update.pl cgi-bin/allocate.pl cgi-bin/combineblocks.pl \
65 cgi-bin/consistency-check.pl cgi-bin/db-update.pl cgi-bin/freespace.pl \
66 \
67 cgi-bin/admin.cgi cgi-bin/ipdb-rpc.cgi cgi-bin/main.cgi cgi-bin/newcity.cgi cgi-bin/newnode.cgi \
[904]68 cgi-bin/search-rpc.cgi cgi-bin/search.cgi cgi-bin/snCalc.cgi \
[846]69 \
70 cgi-bin/extras/db2rwhois.pl
[417]71
[843]72SQL = cgi-bin/ipdb.psql cgi-bin/ipdb-2.7-3.0.sql
73
[417]74MODULES = cgi-bin/IPDB.pm
75
76CONFIGMODULES = cgi-bin/MyIPDB.pm cgi-bin/CustIDCK.pm
77
78RWHOIS = \
[517]79 cgi-bin/extras/rwhois-net-skel.tar.gz cgi-bin/extras/rwhois-config \
[417]80 cgi-bin/extras/network.tmpl
81
[910]82DIRS = docs images templates cgi-bin cgi-bin/extras
[417]83
[897]84MANIFEST = Makefile COPYING \
[910]85 $(GENDOCS) \
[517]86 $(HTML) \
87 $(JS) \
88 $(IMAGES) \
89 $(TEMPLATES) \
90 $(SCRIPTS) \
[843]91 $(SQL) \
[517]92 $(MODULES) \
93 $(CONFIGMODULES) \
94 $(RWHOIS)
[417]95
96all:
97 # nullop
98
[894]99list:
[910]100 echo Makefile COPYING \
101 $(GENDOCS) \
[894]102 $(HTML) \
103 $(JS) \
104 $(IMAGES) \
105 $(TEMPLATES) \
106 $(SCRIPTS) \
107 $(SQL) \
108 $(MODULES) \
109 $(CONFIGMODULES) \
110 $(RWHOIS)
111
[417]112install:
[517]113 @for i in $(HTML) $(IMAGES) $(JS) $(TEMPLATES); do \
[433]114 $(INSTALL_DATA) -D $$i $(DESTDIR)${libdir}/ipdb-$(VERSION)/$$i ; \
[417]115 done
116 # munge in necessary 'use lib ...' bits so scripts can find MyIPDB.pm...
117 @for i in $(SCRIPTS) $(MODULES) $(RWHOIS); do \
[433]118 $(INSTALL_SCRIPT) -D $$i $(DESTDIR)${libdir}/ipdb-$(VERSION)/$$i ; \
119 perl -pi -e 's|##uselib##|use lib "${sysconfdir}/ipdb-$(VERSION)/";|;' $(DESTDIR)${libdir}/ipdb-$(VERSION)/$$i ; \
[417]120 done
[433]121 $(INSTALL) -d $(DESTDIR)${sysconfdir}/ipdb-$(VERSION)/
[417]122 @for i in $(CONFIGMODULES) ; do \
[433]123 $(INSTALL_DATA) $$i $(DESTDIR)${sysconfdir}/ipdb-$(VERSION)/ ; \
[417]124 done
125 # and now munge MyIPDB.pm so it can find the core library
[433]126 perl -pi -e 's|##uselib##|use lib "${libdir}/ipdb-$(VERSION)";|;' $(DESTDIR)${sysconfdir}/ipdb-$(VERSION)/MyIPDB.pm
[417]127
128#clean:
129# @for i in $(DIRS) ; do \
130# $(MAKE) -C $$i clean ; \
131# done
132
133dist:
134 mkdir $(PKGNAME)-$(VERSION)
[910]135 pod2html cgi-bin/search-rpc.cgi > docs/search-rpc.html
[417]136 tar cf - $(MANIFEST) | (cd $(PKGNAME)-$(VERSION); tar xf -)
[607]137 /usr/bin/perl -p -e 's/#VERSION#/$(VERSION)/g;s/#RELEASE#/$(RELEASE)/g;s/#BETA#//g' < $(PKGNAME).spec > $(PKGNAME)-$(VERSION)/$(PKGNAME).spec
138 /usr/bin/perl -p -e 's/#VERSION#/$(VERSION)/g;s/#RELEASE#/$(RELEASE)/g;s/#BETA#//g' < INSTALL > $(PKGNAME)-$(VERSION)/INSTALL
139 perl -pi -e 's/[\d.]+;\s*##VERSION##/"$(VERSION)";/;' $(PKGNAME)-$(VERSION)/cgi-bin/IPDB.pm
[417]140 tar cf $(PKGNAME)-$(VERSION).tar $(PKGNAME)-$(VERSION)
141 gzip -v -f -9 $(PKGNAME)-$(VERSION).tar
142 rm -rf $(PKGNAME)-$(VERSION)
143 # gpg --detach-sign $(PKGNAME)-$(VERSION).tar.gz
Note: See TracBrowser for help on using the repository browser.