c3e99358f0a028de0306fee966df533d8ef1a01b
[debian/amanda] / config / amanda / syshacks.m4
1 # SYNOPSIS
2 #
3 #   AMANDA_SYSHACKS
4 #
5 # OVERVIEW
6 #
7 #   This macro encapsulates any system-specific hacks required to make Amanda
8 #   compile that don't fit neatly into any other macro.  It is implemented as a 
9 #   big 'case' statement based on the canonical target architecture.
10 #
11 #   It also serves as a list of the "supported" architectures, represented by 
12 #   case statements with empty bodies.  If no architecture matches, the user
13 #   is presented with a warning.
14 #
15 AC_DEFUN([AMANDA_SYSHACKS], [
16     AC_REQUIRE([AC_CANONICAL_TARGET])
17     case "$target" in
18         *-dec-osf*)
19                     ;;
20         *-dg-*)
21                     ;;
22         *-netbsd*)
23                     ;;
24         *-freebsd*)
25                     ;;
26         *-openbsd*)
27                     ;;
28         *-hp-*)
29                     case "$CC" in
30                         *gcc*)
31                             AMANDA_ADD_CPPFLAGS([-D__STDC_EXT__])
32                             ;;
33                         *cc*)
34                             AMANDA_ADD_CFLAGS([-Ae])
35                             ;;
36                     esac
37                     ;;
38         *-ibm-aix*)
39                     ;;
40         m88k-motorola-sysv4)
41                     ;;
42         *-nextstep3)
43                     ;;
44         *-pc-bsdi*)
45                     ;;
46         *-pc-linux-*)
47                     ;;
48         *-redhat-linux-*)
49                     ;;
50         *-suse-linux-*)
51                     ;;
52         x86_64-*-linux-*)
53                     ;;
54         alpha*-*-linux-*)
55                     ;;
56         sparc*-*-linux-*)
57                     ;;
58         powerpc-*-linux-*)
59                     ;;
60         *-sgi-irix3*)
61                     # The old cc won't work!
62                     if test "x$GCC" != "xyes"; then
63                         AC_MSG_ERROR([The old SGI IRIX compiler ($CC) will not compile Amanda; use CC=gcc])
64                     fi
65                     ;;
66         *-sgi-irix4*)
67                     ;;
68         *-sgi-irix5*)
69                     ;;
70         *-sgi-irix6*)
71                     ;;
72         *-solaris2*)
73                     ;;
74         *-sun-sunos4.1*)
75                     ;;
76         *-ultrix*)
77                     ;;
78         *-sysv4.2uw2*)
79                     ;;
80         *-sco3.2v5*)
81                     ;;
82         i386-pc-isc4*)
83                     ;;
84         *-sni-sysv4)
85                     ;;
86         *-pc-cygwin)
87                     AC_DEFINE(IGNORE_TAR_ERRORS,1,[Define on Cygwin. ])
88                     # Cygwin needs PATH to find cygwin1.dll
89                     AC_DEFINE(NEED_PATH_ENV,1,[Define on Cygwin. ])
90                     AC_DEFINE(IGNORE_FSTAB,1,[Define on Cygwin. ])
91                     AMANDA_ADD_LDFLAGS([-Wl,-enable-runtime-pseudo-reloc -no-undefined])
92                     ;;
93         *-apple-darwin7*) # MacOS X 10.3.* (Panther)
94                     ;;
95         *-apple-darwin8*) # MacOS X 10.4.* (Tiger)
96                     ;;
97       *)
98                 AMANDA_ADD_WARNING(
99 [*****
100 This machine, target type $target, is not known to be fully supported
101 by this configure script.  If the installation of Amanda on this system
102 succeeds or needed any patches, please email amanda-hackers@amanda.org
103 with the patches or an indication of the sucess or failure of the
104 Amanda installation on your system.
105 *****])
106                     ;;
107     esac
108 ])