summaryrefslogtreecommitdiff
path: root/security/amap/patches/patch-aa
blob: 674ac8e6f2c66d7e27e7f12910d3b07d798b7645 (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
$NetBSD: patch-aa,v 1.3 2006/10/27 10:35:47 adrianp Exp $

--- configure.orig	2005-06-03 14:34:19.000000000 +0100
+++ configure
@@ -13,10 +13,6 @@ if [ "$1" = "--help" ]; then
   exit 0
 fi
 
-cd pcre-3.9 || exit 1
-./configure || exit 1
-cd ..
-
 echo
 echo
 echo "Starting amap auto configuration ..."
@@ -29,13 +25,14 @@ NSL_PATH=""
 SOCKET_PATH=""
 MANDIR=""
 LIBDIRS=`cat /etc/ld.so.conf 2> /dev/null`
-PREFIX=`echo "$1"|grep prefix=|sed 's/.*prefix=//i'`
+PREFIX=`echo "$1"|@GREP@ prefix=|@SED@ 's/.*prefix=//'`
 echo
 
 echo "Checking for openssl ..."
 for i in  $LIBDIRS /lib  /usr/lib /usr/local/lib /opt/local/lib \
 /*ssl /usr/*ssl /opt/*ssl /usr/local/*ssl /opt/local/*ssl \
-/*ssl/lib /usr/*ssl/lib /opt/*ssl/lib /usr/local/*ssl/lib /opt/local/*ssl/lib .
+/*ssl/lib /usr/*ssl/lib /opt/*ssl/lib /usr/local/*ssl/lib /opt/local/*ssl/lib \
+@SSLBASE@/lib .
 do
     if [ "X" = "X$SSL_PATH" ]; then
         if [ -f "$i/libssl.so" -o -f "$i/libssl.dylib" ]; then
@@ -62,7 +59,7 @@ do
 done
 
 for i in /usr/local/include /*ssl/include /usr/include \
-/opt/*ssl/include /usr/*ssl/include /usr/local/*ssl/include .
+/opt/*ssl/include /usr/*ssl/include /usr/local/*ssl/include @SSLBASE@/include .
 do
     if [ "X" = "X$SSL_IPATH" ]; then
         if [ -f "$i/openssl/ssl.h" ]; then
@@ -89,7 +86,7 @@ if [ "$SSL_IPATH" = "/usr/include" ]; th
     SSL_IPATH=""
 fi
 
-SYS=`uname -s`
+SYS=`@UNAME@ -s`
 if [ "$SYS" = "SunOS" ]; then
     echo "Checking for Solaris libraries ..."
     for i in  /lib /usr/lib /usr/local/lib $LIBDIRS
@@ -152,7 +149,7 @@ if [ -n "$RESOLV_PATH" ]; then
     XLIBS="$XLIBS -lresolv"
 fi
 
-for i in /usr/man /usr/share/man /usr/local/man /usr/local/share/man ; do
+for i in /usr/man /usr/share/man /usr/local/man /usr/local/share/man @MANDIR@ ; do
   if [ -d $i ]; then
     MANDIR=$i
   fi
@@ -168,9 +165,9 @@ if [ -d /usr/kerberos/include ]; then
 fi
 
 if [ -n "$PREFIX" ]; then
-    XDEFINES="$XDEFINES -DAMAP_PREFIX='\"$PREFIX\"'"
+    XDEFINES="$XDEFINES -DAMAP_PREFIX=\"\\\"$PREFIX/\\\"\""
 else
-    PREFIX="/usr/local"
+    PREFIX="@PREFIX@"
 fi
 echo "Amap will be installed into .../bin and .../etc of: $PREFIX"
 echo "  (change this by running ./configure --prefix=path)"
@@ -178,7 +175,7 @@ echo
 
 echo "Writing Makefile.in ..."
 echo "XDEFINES=$XDEFINES" >> Makefile.in
-echo "XLIBS=$XLIBS" >> Makefile.in
+echo "XLIBS=$XLIBS @COMPILER_RPATH_FLAG@@PREFIX@/lib -L@PREFIX@/lib" >> Makefile.in
 echo "XLIBPATHS=$XLIBPATHS" >> Makefile.in
 echo "XIPATHS=$XIPATHS" >> Makefile.in
 echo "MANDIR=$MANDIR/man1/" >> Makefile.in