make binary exec path dynamic in scripts referring to it

Everything should just work out of the box without poking.  This change
makes that goal to be yet agian one step closer.  In same go make all
autotools related variable substitutions better.

Requested-by: Martijn van Brummelen <martijn@brumit.nl>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
Sami Kerola 2015-11-25 21:53:29 +00:00
parent c30c122027
commit 2528c4c9d6
No known key found for this signature in database
GPG key ID: A9553245FDE9B739
12 changed files with 45 additions and 13 deletions

2
contrib/.gitignore vendored Normal file
View file

@ -0,0 +1,2 @@
/dhcpd-pools.cgi
/nagios.conf

View file

@ -1,3 +1,5 @@
contribdir = $(datadir)/dhcpd-pools/
PATHFILES += contrib/dhcpd-pools.cgi contrib/nagios.conf
dist_contrib_SCRIPTS = contrib/dhcpd-pools.cgi contrib/snmptest.pl
EXTRA_DIST += contrib/nagios.conf contrib/munin_plugins
dist_contrib_DATA = contrib/nagios.conf
EXTRA_DIST += contrib/munin_plugins

View file

@ -1,4 +1,4 @@
#!/bin/sh
#!@SHELL@
#
# Simple CGI for dhcpd-pools.
@ -26,7 +26,7 @@ echo "<p>This was situation at "
date
echo "</p>"
/usr/local/bin/dhcpd-pools --format html
@bindir@/dhcpd-pools --format html
echo "</body>"
echo "</html>"

View file

@ -1 +0,0 @@
command[check_dhcpd_pools]=/usr/bin/dhcpd-pools --warning $ARG1$ --critical $ARG2$

1
contrib/nagios.conf.in Normal file
View file

@ -0,0 +1 @@
command[check_dhcpd_pools]=@bindir@/dhcpd-pools --warning $ARG1$ --critical $ARG2$