]> git.ipfire.org Git - thirdparty/ntp.git/commitdiff
[Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir.
authorDave Hart <hart@ntp.org>
Wed, 16 Dec 2009 21:26:45 +0000 (21:26 +0000)
committerDave Hart <hart@ntp.org>
Wed, 16 Dec 2009 21:26:45 +0000 (21:26 +0000)
bk: 4b295095NaUvS_snVXVSBcBkfOf--w

13 files changed:
ChangeLog
adjtimed/Makefile.am
bincheck.mf
configure.ac
ntpd/Makefile.am
ntpdate/Makefile.am
ntpdc/Makefile.am
ntpq/Makefile.am
ntpsnmpd/Makefile.am
scripts/Makefile.am
sntp/Makefile.am
sntp/configure.ac
util/Makefile.am

index 6d7fc017e4d7633757ef1d291c35d89b591dd7e8..d562840691ff11038f8fe7ff4dfcf338bfed448c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+---
+
+* [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir.
+
 ---
 (4.2.6) 2009/12/09 Released by Harlan Stenn <stenn@ntp.org>
 * Include (4.2.4p8) - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563.
index cad9dd02eb44a2db9a8eb09f9fe3a267d147bd63..c97a08a7dfa5f34c1fbd5d1fc0c4ad0bd8c94447 100644 (file)
@@ -1,7 +1,11 @@
 AUTOMAKE_OPTIONS=      
 
-bindir=                ${exec_prefix}/${BINSUBDIR}
+if NTP_BINSUBDIR_IS_BIN
 bin_PROGRAMS=  @MAKE_ADJTIMED@
+else
+sbin_PROGRAMS= @MAKE_ADJTIMED@
+endif
+
 BUILT_SOURCES=
 CLEANFILES=
 EXTRA_PROGRAMS=        adjtimed
index c67827dde860018c829703c40baeb503eecbf963..326b7adedf6ac916b727ea232c75a7514a1e2e8e 100644 (file)
@@ -3,11 +3,11 @@
 # subdir to warn folks if there is another version there.
 
 install-exec-hook:
-       @case ${BINSUBDIR} in                                   \
-        bin) ODIR=${exec_prefix}/sbin ;;                       \
-        sbin) ODIR=${exec_prefix}/bin ;;                       \
-       esac;                                                   \
-       test -z "${bin_PROGRAMS}${bin_SCRIPTS}"                 \
+       @case ${BINSUBDIR} in                                           \
+        bin) ODIR=${sbindir} ;;                                        \
+        sbin) ODIR=${bindir} ;;                                        \
+       esac;                                                           \
+       test -z "${bin_PROGRAMS}${bin_SCRIPTS}"                         \
        || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do              \
           test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!";   \
        done
index 636b195b44fd80f96c1ed540658b672785d2bc56..5f328357e69f26574098401e4fa81382fad0ac1c 100644 (file)
@@ -222,8 +222,10 @@ case "$use_binsubdir" in
     ;;
 esac
 AC_MSG_RESULT($use_binsubdir)
+
 BINSUBDIR=$use_binsubdir
 AC_SUBST(BINSUBDIR)
+AM_CONDITIONAL(NTP_BINSUBDIR_IS_BIN, test "bin" = "$BINSUBDIR")
 
 AC_MSG_CHECKING([if we want to use arlib])
 AC_ARG_WITH(arlib,
index 37d4c30e9a1a9b0c0c46299e6113b4d7305cd917..9b1fa44f95305e6196937fc25d1edf662e5c93eb 100644 (file)
@@ -1,9 +1,11 @@
 NULL=
 AUTOMAKE_OPTIONS= 
 
-bindir=        ${exec_prefix}/${BINSUBDIR}
-
+if NTP_BINSUBDIR_IS_BIN
 bin_PROGRAMS=  ntpd @MAKE_NTPDSIM@
+else
+sbin_PROGRAMS= ntpd @MAKE_NTPDSIM@
+endif
 
 noinst_LIBRARIES=      libntpd.a
 
index b162637d9fe8258fc90a28adf7300d8b93421c73..ea760af9bb77bc9224ae5b4cdf202ce41640b4c0 100644 (file)
@@ -3,9 +3,13 @@ AUTOMAKE_OPTIONS=
 
 BUILT_SOURCES=
 CLEANFILES=
-bindir=                ${exec_prefix}/${BINSUBDIR}
-#bin_PROGRAMS= ntpdate ntptimeset
+
+if NTP_BINSUBDIR_IS_BIN
 bin_PROGRAMS=  ntpdate
+else
+sbin_PROGRAMS= ntpdate
+endif
+
 EXTRA_PROGRAMS=        ntptimeset
 
 ntptimeset_SOURCES=    ntptimeset.c ntptime_config.c
index 19eec3ddc1071a4c9f0ec3bca2894ea67041a8c3..64a056949be338123da04511c4b3ddb400845517 100644 (file)
@@ -1,8 +1,12 @@
 NULL=
 AUTOMAKE_OPTIONS=      
 
-bindir=                ${exec_prefix}/${BINSUBDIR}
+if NTP_BINSUBDIR_IS_BIN
 bin_PROGRAMS=  ntpdc
+else
+sbin_PROGRAMS= ntpdc
+endif
+
 EXTRA_PROGRAMS=        ntpdc-layout
 EXTRA_DATA=    check-layout
 BUILT_SOURCES= @MAKE_CHECK_LAYOUT@
index a4771a6d732e20920134e21a2a2082d39c841a8c..c847a9345827d76ba776141e8f93661d494a7831 100644 (file)
@@ -1,7 +1,11 @@
 NULL=
 AUTOMAKE_OPTIONS=      
 
+if NTP_BINSUBDIR_IS_BIN
 bin_PROGRAMS=  ntpq
+else
+sbin_PROGRAMS= ntpq
+endif
 
 AM_CPPFLAGS= -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \
        -I$(top_srcdir)/lib/isc/nothreads/include \
index ede645205bee7022db23d85f870e249ad3eb0eaf..0d3f15f7cf9f2f35332114816fe5556c2c134ac8 100644 (file)
@@ -1,7 +1,12 @@
 NULL=
 AUTOMAKE_OPTIONS= 
 
+if NTP_BINSUBDIR_IS_BIN
+bin_PROGRAMS=  @MAKE_NTPSNMPD@
+else
 sbin_PROGRAMS= @MAKE_NTPSNMPD@
+endif
+
 EXTRA_PROGRAMS=        ntpsnmpd
 ntpsnmpd_SOURCES= netsnmp_daemonize.c ntpsnmpd.c ntpSnmpSubagentObject.c \
                        ntpsnmpd-opts.c ntpsnmpd-opts.h
index 649b7c12d13a857dd316259793a8f88af0bb627f..a00adc646759d6984db6e6f1053e23986a791c3f 100644 (file)
@@ -1,4 +1,8 @@
+if NTP_BINSUBDIR_IS_BIN
 bin_SCRIPTS=   ntp-wait ntptrace
+else
+sbin_SCRIPTS=  ntp-wait ntptrace
+endif
 noinst_SCRIPTS=        calc_tickadj checktime freq_adj html2man mkver ntpsweep ntpver plot_summary summary
 EXTRA_DIST = VersionName cvo.sh fixautomakedepsmagic genCommitLog      \
        genver hpadjtime.sh monitoring ntp-close ntp-groper ntp-restart \
index 9575f41b30034f8e717c5914c1eeb0d03f0be563..5c8af8ec07cc60c5a1e961dc103f8fc95804e23c 100644 (file)
@@ -16,8 +16,12 @@ run_ag=      cd $(srcdir) &&                         \
        env PATH="$(abs_builddir):$(PATH)"      \
        autogen -L ../include --writable
 
-bindir=        ${exec_prefix}/${BINSUBDIR}
+if NTP_BINSUBDIR_IS_BIN
 bin_PROGRAMS=  sntp
+else
+sbin_PROGRAMS= sntp
+endif
+
 CLEANFILES=    libopts-subdir
 
 SUBDIRS=
index 6a4c26e25947c8df38901cf57d1c696e36c349de..348ad48772546efdd213f2734504004b65e83602 100644 (file)
@@ -706,8 +706,10 @@ case "$use_binsubdir" in
     ;;
 esac
 AC_MSG_RESULT($use_binsubdir)
+
 BINSUBDIR=$use_binsubdir
 AC_SUBST(BINSUBDIR)
+AM_CONDITIONAL(NTP_BINSUBDIR_IS_BIN, test "bin" = "$BINSUBDIR")
 
 AC_CONFIG_FILES([Makefile])
 AC_OUTPUT
index f546abea7ff8d35e2397b3e98b522654d663eed9..329160f364a45aecfb17e009abcb12fbad14d51c 100644 (file)
@@ -2,8 +2,14 @@ NULL=
 #AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies
 AUTOMAKE_OPTIONS=      
 
+if NTP_BINSUBDIR_IS_BIN
 bin_PROGRAMS=  @MAKE_NTPTIME@ @MAKE_TICKADJ@ @MAKE_TIMETRIM@ \
                ntp-keygen
+else
+sbin_PROGRAMS= @MAKE_NTPTIME@ @MAKE_TICKADJ@ @MAKE_TIMETRIM@ \
+               ntp-keygen
+endif
+
 EXTRA_PROGRAMS=        audio-pcm byteorder hist jitter kern longsize \
        ntptime pps-api precision sht testrs6000 tg tickadj timetrim