Subversion Repositories

?revision_form?Rev ?revision_input??revision_submit??revision_endform?

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
4 magnus 1
dnl ### Normal initialization. ######################################
2
AC_INIT([libtar], [1.2.11])
3
AC_PREREQ([2.57])
4
AC_CONFIG_AUX_DIR([autoconf])
5
AC_CONFIG_HEADERS([config.h])
6
AC_CONFIG_MACRO_DIR([m4])
7
AC_COPYRIGHT([[
8
Copyright (c) 1998-2003 University of Illinois Board of Trustees
9
Copyright (c) 1998-2003 Mark D. Roth
10
All rights reserved.
11
]])
12
AC_CONFIG_SRCDIR([lib/libtar.h])
13
ENCAP_PKG([], [postinstall-encap])
14
 
15
 
16
dnl ### Load subdirectory modules. ##################################
17
PSG_MODULE([compat])
18
PSG_MODULE([listhash], [libtar])
19
 
20
 
21
dnl ### Set some option defaults. ###################################
22
if test -z "$CFLAGS"; then
23
  CFLAGS="-O"
24
fi
25
MKDIR="mkdir -p -m 755"
26
AC_SUBST([MKDIR])
27
 
28
 
29
dnl ### Check for compiler et al. ###################################
30
AC_AIX
31
AC_PROG_CC
32
AC_PROG_LIBTOOL
33
AC_PROG_INSTALL
34
AC_PROG_LN_S
35
AC_PROG_MAKE_SET
36
 
37
 
38
dnl ### Compiler characteristics. ##################################
39
AC_C_CONST
40
 
41
 
42
dnl ### Checks for header files. ###################################
43
AC_HEADER_STDC
44
AC_CHECK_HEADERS([unistd.h])
45
AC_HEADER_MAJOR
46
PSG_REPLACE_TYPE([major_t], [unsigned int], [
47
  #include <sys/types.h>
48
  #ifdef MAJOR_IN_MKDEV
49
  # include <sys/mkdev.h>
50
  #else
51
  # ifdef MAJOR_IN_SYSMACROS
52
  #  include <sys/sysmacros.h>
53
  # endif
54
  #endif
55
])
56
PSG_REPLACE_TYPE([minor_t], [unsigned int], [
57
  #include <sys/types.h>
58
  #ifdef MAJOR_IN_MKDEV
59
  # include <sys/mkdev.h>
60
  #else
61
  # ifdef MAJOR_IN_SYSMACROS
62
  #  include <sys/sysmacros.h>
63
  # endif
64
  #endif
65
])
66
PSG_REPLACE_TYPE([dev_t], [unsigned long], [
67
  #include <sys/types.h>
68
  #ifdef MAJOR_IN_MKDEV
69
  # include <sys/mkdev.h>
70
  #else
71
  # ifdef MAJOR_IN_SYSMACROS
72
  #  include <sys/sysmacros.h>
73
  # endif
74
  #endif
75
])
76
PSG_REPLACE_TYPE([socklen_t], [unsigned long], [
77
  #include <sys/types.h>
78
  #include <sys/socket.h>
79
])
80
PSG_REPLACE_TYPE([uint64_t], [long long])
81
AC_TYPE_MODE_T
82
AC_TYPE_OFF_T
83
AC_TYPE_SIZE_T
84
AC_TYPE_UID_T
85
PSG_REPLACE_TYPE([nlink_t], [unsigned short])
86
 
87
 
88
dnl ### Check for needed functions. ################################
89
COMPAT_FUNC_BASENAME
90
COMPAT_FUNC_DIRNAME
91
COMPAT_FUNC_FNMATCH
92
AC_CHECK_FUNCS([lchown])
93
COMPAT_FUNC_MAKEDEV
94
COMPAT_FUNC_SNPRINTF
95
COMPAT_FUNC_STRDUP
96
AC_FUNC_STRFTIME
97
COMPAT_FUNC_STRMODE
98
dnl COMPAT_FUNC_STRLCPY converted by compat/modules.ac
99
dnl COMPAT_FUNC_STRSEP
100
 
101
 
102
dnl ### Check for libraries. #######################################
103
AC_ARG_WITH([zlib],
104
  [  --without-zlib          Use external gzip binary instead of zlib],
105
  [],
106
  [with_zlib=yes])
107
if test "$with_zlib" = "yes"; then
108
  AC_CHECK_LIB([z], [gzread])
109
fi
110
 
111
 
112
dnl ### Create output files. #######################################
113
AC_CONFIG_FILES([Makefile lib/Makefile libtar/Makefile doc/Makefile])
114
AC_OUTPUT
115