Legend:
- Unmodified
- Added
- Removed
-
trunk/DNSDB.pm
r218 r219 147 147 my $deferr = ''; # place to put error from default config file in case we can't find either one 148 148 149 my $configroot = '/etc/dnsdb';149 my $configroot = "/etc/dnsdb"; ##CFG_LEAF## 150 150 $configroot = '' if $basename =~ m|^/|; 151 151 $basename .= ".conf" if $basename !~ /\.conf$/; -
trunk/INSTALL
r218 r219 27 27 - NetAddr::IP >= 4.x. 3.x may work, however 4.x has been out for 28 28 more than 4 years. 29 - Frontier::Responder (only required if using dns-rpc.cgi) 29 30 - tinydns - support for other DNS server software is planned 30 31 … … 69 70 shell> psql -U dnsdb dnsdb <dns.sql 70 71 71 72 ##work73 72 4) Configure your webserver to call the DNS Administrator scripts 74 at an appropriate web path. A webroot pointing to the HTML files75 (first level under the dnsadmin-#VERSION#/ tarball directory, or 76 /usr/local/lib/dnsadmin-#VERSION#) should work fine; a server 77 alias under an existing virtual host shouldwork as well.73 at an appropriate web path. A webroot pointing to the unpacked tarball 74 directory or the default install location /usr/local/lib/dnsadmin-#VERSION# 75 should work fine; a directory alias under an existing virtual host should 76 work as well. 78 77 79 78 The directory containing the HTML and scripts must have at least the -
trunk/Makefile
r216 r219 28 28 DESTDIR = 29 29 30 # flag to indicate if we install in a version-numbered location to 31 # support parallel installs (packaged or otherwise) or if we're 32 # installing to .../dnsdb/ (overwrite whatever was there last) 33 PARA_VERSIONS = 0 34 35 # also set the leaf directories we'll be putting things in 36 PKG_LEAF = "dnsdb" 37 CFG_LEAF = "dnsdb" 38 39 # tweak the final leaf directories we install to if PARA_VERSIONS is set 40 ifeq "$(PARA_VERSIONS)" "1" 41 PKG_LEAF = "dnsdb-$(VERSION)" 42 CFG_LEAF = "dnsdb/$(VERSION)" 43 endif 44 30 45 MANIFEST = \ 31 INSTALL COPYING TODO Makefile new-dns.sql dns.sql dns.cgi dns-rpc.cgi DNSDB.pm \ 32 vega-import.pl \ 46 INSTALL COPYING TODO Makefile dnsadmin.spec \ 47 \ 48 new-dns.sql dns.sql dns.cgi dns-rpc.cgi DNSDB.pm vega-import.pl \ 33 49 \ 34 50 index.shtml \ … … 83 99 install: 84 100 @for i in $(IMAGES) $(TEMPLATES); do \ 85 $(INSTALL_DATA) -D $$i $(DESTDIR)${datadir}/ dnsdb-$(VERSION)/$$i ; \101 $(INSTALL_DATA) -D $$i $(DESTDIR)${datadir}/$(PKG_LEAF)/$$i ; \ 86 102 done 87 103 @# munge in necessary 'use lib ...' bits so scripts can find libs and config... 88 104 @# datadir is correct; no arch-specific files 89 105 @for i in $(SCRIPTS) $(MODULES); do \ 90 $(INSTALL_SCRIPT) -D $$i $(DESTDIR)${datadir}/ dnsdb-$(VERSION)/$$i ; \91 perl -pi -e 's|use lib '.'; ##uselib##|use lib "${datadir}/ dnsdb-$(VERSION)/";|;' $(DESTDIR)${datadir}/dnsdb-$(VERSION)/$$i ; \92 perl -pi -e 's|use lib '.'; ##uselib##|use lib "${datadir}/ dnsdb-$(VERSION)/";|;' $(DESTDIR)${datadir}/dnsdb-$(VERSION)/$$i ; \106 $(INSTALL_SCRIPT) -D $$i $(DESTDIR)${datadir}/$(PKG_LEAF)/$$i ; \ 107 perl -pi -e 's|use lib '.'; ##uselib##|use lib "${datadir}/$(PKG_LEAF)/";|;' $(DESTDIR)${datadir}/$(PKG_LEAF)/$$i ; \ 108 perl -pi -e 's|use lib '.'; ##uselib##|use lib "${datadir}/$(PKG_LEAF)/";|;' $(DESTDIR)${datadir}/$(PKG_LEAF)/$$i ; \ 93 109 done 94 @$(INSTALL) -d $(DESTDIR)${sysconfdir}/ dnsdb/110 @$(INSTALL) -d $(DESTDIR)${sysconfdir}/$(CFG_LEAF)/ 95 111 @# install an example config file with all known settings 96 112 @for i in $(CONFIGFILES) ; do \ 97 if [ -e $(DESTDIR)${sysconfdir}/ dnsdb/$$i ]; then \113 if [ -e $(DESTDIR)${sysconfdir}/$(CFG_LEAF)/$$i ]; then \ 98 114 echo "refusing to overwrite existing config file, created as $$i.new" ; \ 99 $(INSTALL_DATA) $$i $(DESTDIR)${sysconfdir}/ dnsdb/$$i.new ; \115 $(INSTALL_DATA) $$i $(DESTDIR)${sysconfdir}/$(CFG_LEAF)/$$i.new ; \ 100 116 else \ 101 $(INSTALL_DATA) $$i $(DESTDIR)${sysconfdir}/dnsdb/ ; \ 102 fi \ 117 $(INSTALL_DATA) $$i $(DESTDIR)${sysconfdir}/$(CFG_LEAF)/ ; \ 118 fi ; \ 119 perl -pi -e 's|"/etc/dnsdb"; ##CFG_LEAF##|"${sysconfdir}/$(CFG_LEAF)";|;' $(DESTDIR)${datadir}/$(PKG_LEAF)/DNSDB.pm ; \ 103 120 done 104 121 # # and now munge MyDNSDB.pm so it can find the core library … … 113 130 mkdir $(PKGNAME)-$(VERSION) 114 131 tar cf - $(MANIFEST) | (cd $(PKGNAME)-$(VERSION); tar xf -) 115 #/usr/bin/perl -p -e 's/#VERSION#/$(VERSION)/;s/#RELEASE#/$(RELEASE)/;s/#BETA#//g' < $(PKGNAME).spec > $(PKGNAME)-$(VERSION)/$(PKGNAME).spec132 /usr/bin/perl -p -e 's/#VERSION#/$(VERSION)/;s/#RELEASE#/$(RELEASE)/;s/#BETA#//g' < $(PKGNAME).spec > $(PKGNAME)-$(VERSION)/$(PKGNAME).spec 116 133 /usr/bin/perl -p -e 's/#VERSION#/$(VERSION)/;s/#RELEASE#/$(RELEASE)/;s/#BETA#//g' < INSTALL > $(PKGNAME)-$(VERSION)/INSTALL 117 134 perl -pi -e 's/[\d.]+;\s*##VERSION##/$(VERSION);/;' $(PKGNAME)-$(VERSION)/DNSDB.pm
Note:
See TracChangeset
for help on using the changeset viewer.