summaryrefslogtreecommitdiff
path: root/archivers/arj/patches/patch-ab
blob: 39ce4b95d5bcb20e9277325d88911771f8373304 (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
$NetBSD: patch-ab,v 1.3.2.1 2004/07/13 14:12:03 agc Exp $

--- gnu/configure.in.orig	Sat Apr 17 13:28:06 2004
+++ gnu/configure.in	Sat Jul 10 19:24:37 2004
@@ -12,7 +12,7 @@
 AC_PROG_INSTALL([e:/os2apps/autoconf/install-sh])
 
 dnl Configuration parameters
-AC_CONFIG_HEADER([../c_defs.h:config.h.in])
+AC_CONFIG_HEADER([c_defs.h:config.h.in])
 
 dnl Checks for the canonical system name
 AC_CANONICAL_HOST
@@ -19,6 +19,16 @@
 
 dnl Checks for programs.
 AC_PROG_CC
+AC_DEFUN(AC_PROG_LD_GNU,
+[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], ac_cv_prog_gnu_ld,
+[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
+if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
+  ac_cv_prog_gnu_ld=yes
+else
+  ac_cv_prog_gnu_ld=no
+fi])
+])
+AC_PROG_LD_GNU
 
 dnl Checks for header files.
 AC_HEADER_STDC
@@ -36,6 +46,7 @@
 AC_TYPE_SIGNAL
 AC_FUNC_VPRINTF
 AC_CHECK_FUNCS([getcwd min max mkdir mkdtemp rmdir fcloseall strcasecmp setpriority strdup strerror strstr strupr strlwr strtol strtoul])
+AC_SEARCH_LIBS([dlsym], [dl])
 
 dnl Platform-specific tuning
 PROG_EXT=
@@ -68,7 +79,9 @@
         CFLAGS="-DSUNOS -D_UNIX"
         DLL_FLAGS="-shared -fPIC"
         DLL_CFLAGS="-shared -fPIC"
+	if test X"$ac_cv_prog_gnu_ld" = X"yes"; then
         LD_STRIP="gnu/stripgcc.lnk"
+	fi
 	;;
 os2*)
 	PROG_EXT=".exe"
@@ -115,7 +128,7 @@
 
 test -z "$CONFIG_SHELL" && CONFIG_SHELL=/bin/sh
 AC_SUBST(CONFIG_SHELL)
-
+AC_OUTPUT(makefile.gnu:makefile.in)
 AC_MSG_CHECKING([if dynamic C library may be used])
 AC_ARG_ENABLE(libc,
 [  --disable-libc          Disable linking with dynamic C library],