diff options
author | Damien Miller <djm@mindrot.org> | 2002-01-23 11:20:59 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2002-01-23 11:20:59 +1100 |
commit | e996d72e025c7663df6fe985a9266eb45df08459 (patch) | |
tree | 654afb087ccd98edf4dc1ec266fd1ccd20f16af6 | |
parent | 7dc8197f8bd6ad7989781604efee4536a271a29a (diff) |
- (djm) Use case statements in autoconf to clean up some tests
-rw-r--r-- | ChangeLog | 3 | ||||
-rw-r--r-- | configure.ac | 36 |
2 files changed, 28 insertions, 11 deletions
@@ -2,6 +2,7 @@ | |||
2 | - (djm) Fix non-standard shell syntax in autoconf. Patch from | 2 | - (djm) Fix non-standard shell syntax in autoconf. Patch from |
3 | Dave Dykstra <dwd@bell-labs.com> | 3 | Dave Dykstra <dwd@bell-labs.com> |
4 | - (stevesk) fix --with-zlib= | 4 | - (stevesk) fix --with-zlib= |
5 | - (djm) Use case statements in autoconf to clean up some tests | ||
5 | 6 | ||
6 | 20020122 | 7 | 20020122 |
7 | - (djm) autoconf hacking: | 8 | - (djm) autoconf hacking: |
@@ -7383,4 +7384,4 @@ | |||
7383 | - Wrote replacements for strlcpy and mkdtemp | 7384 | - Wrote replacements for strlcpy and mkdtemp |
7384 | - Released 1.0pre1 | 7385 | - Released 1.0pre1 |
7385 | 7386 | ||
7386 | $Id: ChangeLog,v 1.1791 2002/01/22 21:59:31 stevesk Exp $ | 7387 | $Id: ChangeLog,v 1.1792 2002/01/23 00:20:59 djm Exp $ |
diff --git a/configure.ac b/configure.ac index 1081b6a37..a23d32497 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -1,4 +1,4 @@ | |||
1 | i# $Id: configure.ac,v 1.15 2002/01/22 21:59:32 stevesk Exp $ | 1 | # $Id: configure.ac,v 1.16 2002/01/23 00:21:01 djm Exp $ |
2 | 2 | ||
3 | AC_INIT | 3 | AC_INIT |
4 | AC_CONFIG_SRCDIR([ssh.c]) | 4 | AC_CONFIG_SRCDIR([ssh.c]) |
@@ -897,7 +897,17 @@ AC_SUBST(INSTALL_SSH_RAND_HELPER) | |||
897 | AC_ARG_WITH(prngd-port, | 897 | AC_ARG_WITH(prngd-port, |
898 | [ --with-prngd-port=PORT read entropy from PRNGD/EGD TCP localhost:PORT], | 898 | [ --with-prngd-port=PORT read entropy from PRNGD/EGD TCP localhost:PORT], |
899 | [ | 899 | [ |
900 | if test ! -z "$withval" -a "x$withval" != "xno" ; then | 900 | case "$withval" in |
901 | no) | ||
902 | withval="" | ||
903 | ;; | ||
904 | [[0-9]]*) | ||
905 | ;; | ||
906 | *) | ||
907 | AC_MSG_ERROR(You must specify a numeric port number for --with-prngd-port) | ||
908 | ;; | ||
909 | esac | ||
910 | if test ! -z "$withval" ; then | ||
901 | PRNGD_PORT="$withval" | 911 | PRNGD_PORT="$withval" |
902 | AC_DEFINE_UNQUOTED(PRNGD_PORT, $PRNGD_PORT) | 912 | AC_DEFINE_UNQUOTED(PRNGD_PORT, $PRNGD_PORT) |
903 | fi | 913 | fi |
@@ -908,18 +918,24 @@ AC_ARG_WITH(prngd-port, | |||
908 | AC_ARG_WITH(prngd-socket, | 918 | AC_ARG_WITH(prngd-socket, |
909 | [ --with-prngd-socket=FILE read entropy from PRNGD/EGD socket FILE (default=/var/run/egd-pool)], | 919 | [ --with-prngd-socket=FILE read entropy from PRNGD/EGD socket FILE (default=/var/run/egd-pool)], |
910 | [ | 920 | [ |
911 | if test -z "$withval" ; then | 921 | case "$withval" in |
922 | yes) | ||
912 | withval="/var/run/egd-pool" | 923 | withval="/var/run/egd-pool" |
913 | fi | 924 | ;; |
914 | if test "x$withval" != "xno" ; then | 925 | no) |
926 | withval="" | ||
927 | ;; | ||
928 | /*) | ||
929 | ;; | ||
930 | *) | ||
931 | AC_MSG_ERROR(You must specify an absolute path to the entropy socket) | ||
932 | ;; | ||
933 | esac | ||
934 | |||
935 | if test ! -z "$withval" ; then | ||
915 | if test ! -z "$PRNGD_PORT" ; then | 936 | if test ! -z "$PRNGD_PORT" ; then |
916 | AC_MSG_ERROR(You may not specify both a PRNGD/EGD port and socket) | 937 | AC_MSG_ERROR(You may not specify both a PRNGD/EGD port and socket) |
917 | fi | 938 | fi |
918 | if echo "$withval" | grep '^/' >/dev/null 2>&1 ; then | ||
919 | # Good | ||
920 | else | ||
921 | AC_MSG_ERROR(You must specify an absolute path to the entropy socket) | ||
922 | fi | ||
923 | if test ! -r "$withval" ; then | 939 | if test ! -r "$withval" ; then |
924 | AC_MSG_WARN(Entropy socket is not readable) | 940 | AC_MSG_WARN(Entropy socket is not readable) |
925 | fi | 941 | fi |