-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathconfigure.ac
127 lines (106 loc) · 2.56 KB
/
configure.ac
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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
AC_PREREQ(2.59)
AC_INIT([vbackup], [1.1.0~pre1], [[email protected]])
AM_INIT_AUTOMAKE
AC_ARG_WITH( tar,
[AC_HELP_STRING([--with-tar=PATH],
[Full path to GNU tar]) ],
[GTAR="$with_tar"])
AC_ARG_WITH( find,
[AC_HELP_STRING([--with-find=PATH],
[Full path to GNU find])],
[GFIND="$with_find"])
# Checks for programs.
AC_PROG_MKDIR_P
# Check for GNU tar
if test -z "$GTAR" ; then
AC_PATH_PROG([GTAR], [tar], [])
fi
if test -z "$GTAR" ; then
AC_MSG_ERROR([GNU tar was not found. vbackup cannot work.])
fi
if test -z "$GFIND" ; then
AC_PATH_PROG([GFIND], [find], [])
fi
if test -z "$GFIND" ; then
AC_MSG_ERROR([GNU find was not found. vbackup cannot work.])
fi
AC_CACHE_CHECK(
[for GNU tar],
[vbackup_cv_gtar],
[
if test -z "$GTAR" ; then
vbackup_cv_gtar="no"
else
T=`$GTAR --version 2>&1 |grep 'GNU'`
if test -z "$T" ; then
vbackup_cv_gtar="no"
else
vbackup_cv_gtar="$GTAR"
fi
fi
])
if test "$vbackup_cv_gtar" = "no" ; then
GTAR=""
else
GTAR="$vbackup_cv_gtar"
fi
# Check for GNU find
AC_CACHE_CHECK(
[for GNU find],
[vbackup_cv_gfind],
[
if test -z "$GFIND" ; then
vbackup_cv_gfind="no"
else
T=`$GFIND --version 2>&1 |grep 'GNU'`
if test -z "$T" ; then
vbackup_cv_gfind="no"
else
vbackup_cv_gfind="$GFIND"
fi
fi
])
if test "$vbackup_cv_gfind" = "no" ; then
GFIND=""
else
GFIND="$vbackup_cv_gfind"
fi
# Check for echo that accepts newlines
T=`echo -e ""`
if test -z "$T" ; then
ECHO_E="echo -e"
else
ECHO_E="echo"
fi
# Checks for libraries.
# Checks for header files.
# Checks for typedefs, structures, and compiler characteristics.
AC_SUBST([mybindir], [${datadir}/vbackup/bin])
AC_SUBST([myhelperdir], [${datadir}/vbackup/helpers])
AC_SUBST([myscriptdir], [${datadir}/vbackup/scripts])
AC_SUBST([myconfdir], [${sysconfdir}/vbackup])
AC_SUBST([mystatedir], [${localstatedir}/lib/vbackup/state])
AC_SUBST([sampledir], [${datadir}/vbackup/samples])
AC_SUBST([wizdir], [${datadir}/vbackup/wizard])
AC_SUBST([ECHO_E])
# Checks for library functions.
AC_CONFIG_FILES([Makefile
scripts/Makefile
scripts/bin/Makefile
scripts/bin/run
scripts/bin/vbackup
scripts/bin/common
scripts/bin/vbackup-wizard
scripts/scripts/Makefile
scripts/scripts/mount/Makefile
scripts/scripts/db/Makefile
scripts/scripts/misc/Makefile
scripts/scripts/fs/Makefile
scripts/scripts/pkg/Makefile
scripts/scripts/netcp/Makefile
scripts/scripts/encrypt/Makefile
scripts/wizard/Makefile
])
AC_OUTPUT