summaryrefslogtreecommitdiff
path: root/security/sudo/patches/patch-ag
blob: db65fb85e4ec5f29577ef48895812405cc861ec8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
$NetBSD: patch-ag,v 1.2 2001/11/19 17:27:24 jlam Exp $

--- configure.orig	Fri Mar 24 15:14:00 2000
+++ configure
@@ -28,6 +28,8 @@
 ac_help="$ac_help
   --with-csops            add CSOps standard options"
 ac_help="$ac_help
+  --with-nbsdops          add NetBSD standard options"
+ac_help="$ac_help
   --without-passwd        don't use passwd/shadow file for authentication"
 ac_help="$ac_help
   --with-skey             enable S/Key support "
@@ -292,7 +294,7 @@
   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
   --datadir=DIR           read-only architecture-independent data in DIR
                           [PREFIX/share]
-  --sysconfdir=DIR        read-only single-machine data in DIR [/etc]
+  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
                           [PREFIX/com]
   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
@@ -679,7 +681,6 @@
 test "$mandir" = '${prefix}/man' && mandir='$(prefix)/man'
 test "$bindir" = '${exec_prefix}/bin' && bindir='$(exec_prefix)/bin'
 test "$sbindir" = '${exec_prefix}/sbin' && sbindir='$(exec_prefix)/sbin'
-test "$sysconfdir" = '${prefix}/etc' && sysconfdir='/etc'
 
 
 # Check whether --with-otp-only or --without-otp-only was given.
@@ -819,6 +820,23 @@
 fi
 
 
+# Check whether --with-nbsdops or --without-nbsdops was given.
+if test "${with_nbsdops+set}" = set; then
+  withval="$with_nbsdops"
+  case $with_nbsdops in
+    yes)	echo 'Adding NetBSD standard options'
+		CHECKSIA=false
+		with_ignore_dot=yes
+		with_env_editor=yes
+		with_tty_tickets=yes
+		;;
+    no)		;;
+    *)		echo "Ignoring unknown argument to --with-nbsdops: $with_nbsdops"
+		;;
+esac
+fi
+
+
 # Check whether --with-passwd or --without-passwd was given.
 if test "${with_passwd+set}" = set; then
   withval="$with_passwd"
@@ -7712,7 +7730,9 @@
 #define HAVE_KERB5 1
 EOF
 
-    if test -f "/usr/local/include/krb5.h"; then
+    if test -f "/usr/include/krb5/krb5.h"; then
+	CPPFLAGS="$CPPFLAGS -I/usr/include/krb5";
+    elif test -f "/usr/local/include/krb5.h"; then
 	CPPFLAGS="$CPPFLAGS -I/usr/local/include"
     elif test -f "/usr/local/kerberos/include/krb5.h"; then
 	CPPFLAGS="$CPPFLAGS -I/usr/local/kerberos/include"
@@ -7722,7 +7742,9 @@
 	echo 'Unable to locate kerberos 5 include files, you will have to edit the Makefile and add -I/path/to/krb/includes to CPPFLAGS'
     fi
 
-    if test -f "/usr/local/lib/libkrb5.a"; then
+    if test -f "/usr/lib/libkrb5.a"; then
+	SUDO_LDFLAGS="${SUDO_LDFLAGS}";
+    elif test -f "/usr/local/lib/libkrb5.a"; then
 	SUDO_LDFLAGS="${SUDO_LDFLAGS} -L/usr/local/lib"
     elif test -f "/usr/local/kerberos/lib/libkrb5.a"; then
 	SUDO_LDFLAGS="${SUDO_LDFLAGS} -L/usr/local/kerberos/lib"
@@ -7732,7 +7754,7 @@
 	echo 'Unable to locate kerberos 5 libraries, you will have to edit the Makefile and add -L/path/to/krb/libs to SUDO_LDFLAGS'
     fi
 
-    SUDO_LIBS="${SUDO_LIBS} -lkrb5 -lk5crypto -lcom_err"
+    SUDO_LIBS="${SUDO_LIBS} -lkrb5 -lasn1 -lcrypto -lroken -lcom_err"
     AUTH_OBJS="${AUTH_OBJS} kerb5.o"
 fi