]> sourceware.org Git - lvm2.git/blame - configure.in
post-release
[lvm2.git] / configure.in
CommitLineData
d0191583 1###############################################################################
ad6254c5 2## Copyright (C) 2000-2004 Sistina Software, Inc. All rights reserved.
b6d7a484 3## Copyright (C) 2004-2012 Red Hat, Inc. All rights reserved.
795ca3e5 4##
ad6254c5
AK
5## This copyrighted material is made available to anyone wishing to use,
6## modify, copy, or redistribute it subject to the terms and conditions
7## of the GNU General Public License v.2.
795ca3e5 8##
ad6254c5
AK
9## You should have received a copy of the GNU General Public License
10## along with this program; if not, write to the Free Software Foundation,
11## Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
795ca3e5
AK
12################################################################################
13
e24fb506 14AC_PREREQ(2.61)
80992638 15################################################################################
8ce0cbda 16dnl -- Process this file with autoconf to produce a configure script.
7a197a62
AK
17AC_INIT
18AC_CONFIG_SRCDIR([lib/device/dev-cache.h])
d0191583 19AC_CONFIG_HEADERS([lib/misc/configure.h])
72b2cb61 20
80992638 21################################################################################
ad6254c5 22dnl -- Setup the directory where autoconf has auxilary files
d3a356b4 23AC_CONFIG_AUX_DIR(autoconf)
795ca3e5 24
80992638 25################################################################################
8ce0cbda 26dnl -- Get system type
7a197a62 27AC_CANONICAL_TARGET([])
b896caa1
AK
28
29case "$host_os" in
30 linux*)
7f54ef36 31 CFLAGS="$CFLAGS"
8ce0cbda 32 COPTIMISE_FLAG="-O2"
80992638 33 CLDFLAGS="$CLDFLAGS -Wl,--version-script,.export.sym"
bf09a320
AK
34 ELDFLAGS="-Wl,--export-dynamic"
35 # FIXME Generate list and use --dynamic-list=.dlopen.sym
8106cdd5
AK
36 CLDWHOLEARCHIVE="-Wl,-whole-archive"
37 CLDNOWHOLEARCHIVE="-Wl,-no-whole-archive"
80992638 38 LDDEPS="$LDDEPS .export.sym"
d0191583 39 LIB_SUFFIX=so
8106cdd5 40 DEVMAPPER=yes
615534d3 41 LVMETAD=no
1a9ea74d 42 ODIRECT=yes
d0191583 43 DM_IOCTLS=yes
80992638 44 SELINUX=yes
d3c8211f 45 CLUSTER=internal
f6fc418d 46 FSADM=yes
d0191583 47 ;;
8106cdd5 48 darwin*)
80992638 49 CFLAGS="$CFLAGS -no-cpp-precomp -fno-common"
8ce0cbda 50 COPTIMISE_FLAG="-O2"
80992638 51 CLDFLAGS="$CLDFLAGS"
bf09a320 52 ELDFLAGS=
8106cdd5
AK
53 CLDWHOLEARCHIVE="-all_load"
54 CLDNOWHOLEARCHIVE=
d0191583 55 LIB_SUFFIX=dylib
a653923f 56 DEVMAPPER=yes
1a9ea74d 57 ODIRECT=no
d0191583 58 DM_IOCTLS=no
80992638 59 SELINUX=no
d3c8211f 60 CLUSTER=none
d0191583
JM
61 FSADM=no
62 ;;
b896caa1
AK
63esac
64
80992638 65################################################################################
8ce0cbda 66dnl -- Checks for programs.
162aefe8 67AC_PROG_SED
8ce0cbda
AK
68AC_PROG_AWK
69AC_PROG_CC
d0191583
JM
70
71dnl probably no longer needed in 2008, but...
72AC_PROG_GCC_TRADITIONAL
8ce0cbda
AK
73AC_PROG_INSTALL
74AC_PROG_LN_S
75AC_PROG_MAKE_SET
162aefe8 76AC_PROG_MKDIR_P
5556819a 77AC_PROG_RANLIB
8a2fc586
AK
78AC_PATH_PROG(CFLOW_CMD, cflow)
79AC_PATH_PROG(CSCOPE_CMD, cscope)
8ce0cbda
AK
80
81################################################################################
d0191583 82dnl -- Check for header files.
80992638 83AC_HEADER_DIRENT
d911ec67 84AC_HEADER_MAJOR
80992638 85AC_HEADER_STDC
ad6254c5
AK
86AC_HEADER_SYS_WAIT
87AC_HEADER_TIME
88
d0191583 89AC_CHECK_HEADERS([locale.h stddef.h syslog.h sys/file.h sys/time.h assert.h \
d911ec67
AK
90 langinfo.h libgen.h signal.h sys/mman.h sys/resource.h sys/utsname.h \
91 sys/wait.h time.h], ,
d0191583 92 [AC_MSG_ERROR(bailing out)])
ad6254c5
AK
93
94case "$host_os" in
95 linux*)
96 AC_CHECK_HEADERS(asm/byteorder.h linux/fs.h malloc.h,,AC_MSG_ERROR(bailing out)) ;;
97 darwin*)
98 AC_CHECK_HEADERS(machine/endian.h sys/disk.h,,AC_MSG_ERROR(bailing out)) ;;
99esac
80992638 100
d0191583
JM
101AC_CHECK_HEADERS([ctype.h dirent.h errno.h fcntl.h getopt.h inttypes.h limits.h \
102 stdarg.h stdio.h stdlib.h string.h sys/ioctl.h sys/param.h sys/stat.h \
103 sys/types.h unistd.h], , [AC_MSG_ERROR(bailing out)])
104AC_CHECK_HEADERS(termios.h sys/statvfs.h)
105
80992638 106################################################################################
d0191583 107dnl -- Check for typedefs, structures, and compiler characteristics.
80992638
AK
108AC_C_CONST
109AC_C_INLINE
d0191583 110AC_CHECK_MEMBERS([struct stat.st_rdev])
80992638
AK
111AC_TYPE_OFF_T
112AC_TYPE_PID_T
d0191583 113AC_TYPE_SIGNAL
80992638 114AC_TYPE_SIZE_T
ad6254c5 115AC_TYPE_MODE_T
d911ec67
AK
116AC_TYPE_INT8_T
117AC_TYPE_INT16_T
118AC_TYPE_INT32_T
119AC_TYPE_INT64_T
120AC_TYPE_SSIZE_T
121AC_TYPE_UID_T
122AC_TYPE_UINT8_T
123AC_TYPE_UINT16_T
124AC_TYPE_UINT32_T
125AC_TYPE_UINT64_T
7a197a62 126AC_CHECK_MEMBERS([struct stat.st_rdev])
ad6254c5
AK
127AC_STRUCT_TM
128
129################################################################################
130dnl -- Check for functions
7c9fd3ea 131AC_CHECK_FUNCS([ftruncate gethostname getpagesize \
d911ec67
AK
132 gettimeofday memset mkdir mkfifo rmdir munmap nl_langinfo setenv setlocale \
133 strcasecmp strchr strcspn strspn strdup strncasecmp strerror strrchr \
134 strstr strtol strtoul uname], , [AC_MSG_ERROR(bailing out)])
a0f9708e 135AC_CHECK_FUNCS(siginterrupt)
ad6254c5
AK
136AC_FUNC_ALLOCA
137AC_FUNC_CLOSEDIR_VOID
d911ec67 138AC_FUNC_CHOWN
ad6254c5
AK
139AC_FUNC_FORK
140AC_FUNC_LSTAT
141AC_FUNC_MALLOC
142AC_FUNC_MEMCMP
143AC_FUNC_MMAP
d911ec67 144AC_FUNC_REALLOC
ad6254c5
AK
145AC_FUNC_STAT
146AC_FUNC_STRTOD
d0191583 147AC_FUNC_VPRINTF
80992638 148
9c961554
MB
149################################################################################
150dnl -- Enables statically-linked tools
151AC_MSG_CHECKING(whether to use static linking)
152AC_ARG_ENABLE(static_link,
71082be4
ZK
153 AC_HELP_STRING([--enable-static_link],
154 [use this to link the tools to their libraries
155 statically (default is dynamic linking]),
156 STATIC_LINK=$enableval, STATIC_LINK=no)
9c961554
MB
157AC_MSG_RESULT($STATIC_LINK)
158
80992638 159################################################################################
8ce0cbda 160dnl -- Prefix is /usr by default, the exec_prefix default is setup later
795ca3e5
AK
161AC_PREFIX_DEFAULT(/usr)
162
80992638 163################################################################################
8ce0cbda 164dnl -- Setup the ownership of the files
ad6254c5 165AC_MSG_CHECKING(file owner)
795ca3e5 166AC_ARG_WITH(user,
71082be4
ZK
167 AC_HELP_STRING([--with-user=USER],
168 [set the owner of installed files [[USER=]]]),
169 OWNER=$withval)
ad6254c5 170AC_MSG_RESULT($OWNER)
a38df97f
AK
171
172if test x$OWNER != x; then
23b059e7 173 INSTALL="$INSTALL -o $OWNER"
a38df97f 174fi
795ca3e5 175
80992638 176################################################################################
8ce0cbda 177dnl -- Setup the group ownership of the files
ad6254c5 178AC_MSG_CHECKING(group owner)
795ca3e5 179AC_ARG_WITH(group,
71082be4
ZK
180 AC_HELP_STRING([--with-group=GROUP],
181 [set the group owner of installed files [[GROUP=]]]),
182 GROUP=$withval)
ad6254c5 183AC_MSG_RESULT($GROUP)
a38df97f
AK
184
185if test x$GROUP != x; then
23b059e7 186 INSTALL="$INSTALL -g $GROUP"
a38df97f 187fi
795ca3e5 188
0782ad50
AK
189################################################################################
190dnl -- Setup device node ownership
191AC_MSG_CHECKING(device node uid)
192
193AC_ARG_WITH(device-uid,
71082be4
ZK
194 AC_HELP_STRING([--with-device-uid=UID],
195 [set the owner used for new device nodes [[UID=0]]]),
196 DM_DEVICE_UID=$withval, DM_DEVICE_UID=0)
0782ad50
AK
197AC_MSG_RESULT($DM_DEVICE_UID)
198
199################################################################################
200dnl -- Setup device group ownership
201AC_MSG_CHECKING(device node gid)
202
203AC_ARG_WITH(device-gid,
71082be4
ZK
204 AC_HELP_STRING([--with-device-gid=GID],
205 [set the group used for new device nodes [[GID=0]]]),
206 DM_DEVICE_GID=$withval, DM_DEVICE_GID=0)
0782ad50
AK
207AC_MSG_RESULT($DM_DEVICE_GID)
208
f6fc418d
AK
209################################################################################
210dnl -- Setup device mode
211AC_MSG_CHECKING(device node mode)
212
213AC_ARG_WITH(device-mode,
71082be4
ZK
214 AC_HELP_STRING([--with-device-mode=MODE],
215 [set the mode used for new device nodes [[MODE=0600]]]),
216 DM_DEVICE_MODE=$withval, DM_DEVICE_MODE=0600)
f6fc418d
AK
217AC_MSG_RESULT($DM_DEVICE_MODE)
218
d0df875d
ZK
219AC_MSG_CHECKING(when to create device nodes)
220AC_ARG_WITH(device-nodes-on,
221 AC_HELP_STRING([--with-device-nodes-on=ON],
222 [create nodes on resume or create [[ON=resume]]]),
223 ADD_NODE=$withval, ADD_NODE=resume)
224case "$ADD_NODE" in
225 resume) add_on=DM_ADD_NODE_ON_RESUME;;
226 create) add_on=DM_ADD_NODE_ON_CREATE;;
227 *) AC_MSG_ERROR([--with-device-nodes-on parameter invalid]);;
228esac
229AC_MSG_RESULT(on $ADD_NODE)
230AC_DEFINE_UNQUOTED([DEFAULT_DM_ADD_NODE], $add_on, [Define default node creation behavior with dmsetup create])
231
80992638 232################################################################################
7d1552c9 233dnl -- LVM1 tool fallback option
ad6254c5 234AC_MSG_CHECKING(whether to enable lvm1 fallback)
71082be4
ZK
235AC_ARG_ENABLE(lvm1_fallback,
236 AC_HELP_STRING([--enable-lvm1_fallback],
237 [use this to fall back and use LVM1 binaries if
238 device-mapper is missing from the kernel]),
239 LVM1_FALLBACK=$enableval, LVM1_FALLBACK=no)
ad6254c5 240AC_MSG_RESULT($LVM1_FALLBACK)
7d1552c9
AK
241
242if test x$LVM1_FALLBACK = xyes; then
72b2cb61 243 AC_DEFINE([LVM1_FALLBACK], 1, [Define to 1 if 'lvm' should fall back to using LVM1 binaries if device-mapper is missing from the kernel])
7d1552c9
AK
244fi
245
80992638 246################################################################################
5a52dca9 247dnl -- format1 inclusion type
ad6254c5 248AC_MSG_CHECKING(whether to include support for lvm1 metadata)
5a52dca9 249AC_ARG_WITH(lvm1,
71082be4
ZK
250 AC_HELP_STRING([--with-lvm1=TYPE],
251 [LVM1 metadata support: internal/shared/none
252 [[TYPE=internal]]]),
253 LVM1=$withval, LVM1=internal)
ad6254c5 254AC_MSG_RESULT($LVM1)
5a52dca9
AK
255
256if [[ "x$LVM1" != xnone -a "x$LVM1" != xinternal -a "x$LVM1" != xshared ]];
257 then AC_MSG_ERROR(
258--with-lvm1 parameter invalid
259)
5a52dca9
AK
260fi;
261
b896caa1 262if test x$LVM1 = xinternal; then
72b2cb61 263 AC_DEFINE([LVM1_INTERNAL], 1, [Define to 1 to include built-in support for LVM1 metadata.])
b896caa1
AK
264fi
265
80992638 266################################################################################
d8ac0fbc 267dnl -- format_pool inclusion type
ad6254c5 268AC_MSG_CHECKING(whether to include support for GFS pool metadata)
d8ac0fbc 269AC_ARG_WITH(pool,
71082be4
ZK
270 AC_HELP_STRING([--with-pool=TYPE],
271 [GFS pool read-only support: internal/shared/none
272 [[TYPE=internal]]]),
273 POOL=$withval, POOL=internal)
ad6254c5 274AC_MSG_RESULT($POOL)
d8ac0fbc
AK
275
276if [[ "x$POOL" != xnone -a "x$POOL" != xinternal -a "x$POOL" != xshared ]];
277 then AC_MSG_ERROR(
278--with-pool parameter invalid
279)
d8ac0fbc
AK
280fi;
281
282if test x$POOL = xinternal; then
72b2cb61 283 AC_DEFINE([POOL_INTERNAL], 1, [Define to 1 to include built-in support for GFS pool metadata.])
d8ac0fbc
AK
284fi
285
80992638 286################################################################################
d3c8211f 287dnl -- cluster_locking inclusion type
ad6254c5 288AC_MSG_CHECKING(whether to include support for cluster locking)
d3c8211f 289AC_ARG_WITH(cluster,
71082be4
ZK
290 AC_HELP_STRING([--with-cluster=TYPE],
291 [cluster LVM locking support: internal/shared/none
292 [[TYPE=internal]]]),
293 CLUSTER=$withval)
ad6254c5 294AC_MSG_RESULT($CLUSTER)
d3c8211f
AK
295
296if [[ "x$CLUSTER" != xnone -a "x$CLUSTER" != xinternal -a "x$CLUSTER" != xshared ]];
297 then AC_MSG_ERROR(
298--with-cluster parameter invalid
299)
d3c8211f
AK
300fi;
301
302if test x$CLUSTER = xinternal; then
72b2cb61 303 AC_DEFINE([CLUSTER_LOCKING_INTERNAL], 1, [Define to 1 to include built-in support for clustered LVM locking.])
d3c8211f 304fi
d8ac0fbc 305
80992638 306################################################################################
4922197a 307dnl -- snapshots inclusion type
ad6254c5 308AC_MSG_CHECKING(whether to include snapshots)
4922197a 309AC_ARG_WITH(snapshots,
71082be4
ZK
310 AC_HELP_STRING([--with-snapshots=TYPE],
311 [snapshot support: internal/shared/none
312 [[TYPE=internal]]]),
313 SNAPSHOTS=$withval, SNAPSHOTS=internal)
ad6254c5 314AC_MSG_RESULT($SNAPSHOTS)
4922197a
AK
315
316if [[ "x$SNAPSHOTS" != xnone -a "x$SNAPSHOTS" != xinternal -a "x$SNAPSHOTS" != xshared ]];
317 then AC_MSG_ERROR(
318--with-snapshots parameter invalid
319)
4922197a
AK
320fi;
321
322if test x$SNAPSHOTS = xinternal; then
72b2cb61 323 AC_DEFINE([SNAPSHOT_INTERNAL], 1, [Define to 1 to include built-in support for snapshots.])
4922197a
AK
324fi
325
80992638 326################################################################################
4922197a 327dnl -- mirrors inclusion type
ad6254c5 328AC_MSG_CHECKING(whether to include mirrors)
4922197a 329AC_ARG_WITH(mirrors,
71082be4
ZK
330 AC_HELP_STRING([--with-mirrors=TYPE],
331 [mirror support: internal/shared/none
332 [[TYPE=internal]]]),
333 MIRRORS=$withval, MIRRORS=internal)
ad6254c5 334AC_MSG_RESULT($MIRRORS)
4922197a
AK
335
336if [[ "x$MIRRORS" != xnone -a "x$MIRRORS" != xinternal -a "x$MIRRORS" != xshared ]];
337 then AC_MSG_ERROR(
338--with-mirrors parameter invalid
339)
4922197a
AK
340fi;
341
342if test x$MIRRORS = xinternal; then
72b2cb61 343 AC_DEFINE([MIRRORED_INTERNAL], 1, [Define to 1 to include built-in support for mirrors.])
4922197a
AK
344fi
345
cac52ca4
JEB
346################################################################################
347dnl -- raid inclusion type
348AC_MSG_CHECKING(whether to include raid)
349AC_ARG_WITH(raid,
350 AC_HELP_STRING([--with-raid=TYPE],
351 [mirror support: internal/shared/none
352 [[TYPE=internal]]]),
353 RAID=$withval, RAID=internal)
354AC_MSG_RESULT($RAID)
355
356if [[ "x$RAID" != xnone -a "x$RAID" != xinternal -a "x$RAID" != xshared ]];
357 then AC_MSG_ERROR(
358--with-raid parameter invalid
359)
360fi;
361
362if test x$RAID = xinternal; then
363 AC_DEFINE([RAID_INTERNAL], 1, [Define to 1 to include built-in support for raid.])
364fi
365
8fea97b7
ZK
366################################################################################
367dnl -- asynchronous volume replicator inclusion type
368AC_MSG_CHECKING(whether to include replicators)
71082be4
ZK
369AC_ARG_WITH(replicators,
370 AC_HELP_STRING([--with-replicators=TYPE],
371 [replicator support: internal/shared/none
372 [[TYPE=none]]]),
373 REPLICATORS=$withval, REPLICATORS=none)
8fea97b7
ZK
374AC_MSG_RESULT($REPLICATORS)
375
376case "$REPLICATORS" in
377 none|shared) ;;
378 internal) AC_DEFINE([REPLICATOR_INTERNAL], 1,
379 [Define to 1 to include built-in support for replicators.]) ;;
380 *) AC_MSG_ERROR([--with-replicators parameter invalid ($REPLICATORS)]) ;;
381esac
382
3ba4a195
ZK
383################################################################################
384dnl -- thin provisioning
385AC_MSG_CHECKING(whether to include thin provisioning)
386AC_ARG_WITH(thin,
387 AC_HELP_STRING([--with-thin=TYPE],
388 [thin provisioning support: internal/shared/none
389 [[TYPE=none]]]),
390 THIN=$withval, THIN=none)
391AC_MSG_RESULT($THIN)
392
393case "$THIN" in
394 none|shared) ;;
395 internal) AC_DEFINE([THIN_INTERNAL], 1,
396 [Define to 1 to include built-in support for thin provisioning.]) ;;
397 *) AC_MSG_ERROR([--with-thin parameter invalid ($THIN)]) ;;
398esac
399
80992638 400################################################################################
1b523347 401dnl -- Disable readline
ad6254c5 402AC_MSG_CHECKING(whether to enable readline)
2c189a57 403AC_ARG_ENABLE([readline],
71082be4
ZK
404 AC_HELP_STRING([--disable-readline], [disable readline support]),
405 READLINE=$enableval, READLINE=maybe)
ad6254c5 406AC_MSG_RESULT($READLINE)
795ca3e5 407
8b1a3214
AK
408################################################################################
409dnl -- Disable realtime clock support
410AC_MSG_CHECKING(whether to enable realtime support)
71082be4
ZK
411AC_ARG_ENABLE(realtime,
412 AC_HELP_STRING([--enable-realtime], [enable realtime clock support]),
413 REALTIME=$enableval)
8b1a3214
AK
414AC_MSG_RESULT($REALTIME)
415
e40d44be
ZK
416################################################################################
417dnl -- disable OCF resource agents
418AC_MSG_CHECKING(whether to enable OCF resource agents)
419AC_ARG_ENABLE(ocf,
420 AC_HELP_STRING([--enable-ocf],
421 [enable Open Cluster Framework (OCF) compliant resource agents]),
422 OCF=$enableval, OCF=no)
423AC_MSG_RESULT($OCF)
349da06c
ZK
424AC_ARG_WITH(ocfdir,
425 AC_HELP_STRING([--with-ocfdir=DIR],
426 [install OCF files in DIR [[PREFIX/lib/ocf/resource.d/lvm2]]]),
427 OCFDIR=$withval, OCFDIR='${prefix}/lib/ocf/resource.d/lvm2')
e40d44be 428
90c80887
AK
429################################################################################
430dnl -- Init pkg-config with dummy invokation:
431dnl -- this is required because PKG_CHECK_MODULES macro is expanded
432dnl -- to initialize the pkg-config environment only at the first invokation,
433dnl -- that would be conditional in this configure.in.
434pkg_config_init() {
435 PKG_CHECK_MODULES(PKGCONFIGINIT, pkgconfiginit, [],
436 [AC_MSG_RESULT([pkg-config initialized])])
437 PKGCONFIG_INIT=1
438}
439
80992638 440################################################################################
8ce0cbda 441dnl -- Build cluster LVM daemon
ad6254c5 442AC_MSG_CHECKING(whether to build cluster LVM daemon)
a266258f 443AC_ARG_WITH(clvmd,
71082be4 444 [ --with-clvmd=TYPE build cluster LVM Daemon
8c222979 445 The following cluster manager combinations are valid:
a946372e
AK
446 * cman (RHEL5 or equivalent)
447 * cman,corosync,openais (or selection of them)
649c4507 448 * singlenode (localhost only)
a946372e
AK
449 * all (autodetect)
450 * none (disable build)
71082be4
ZK
451 [[TYPE=none]]],
452 CLVMD=$withval, CLVMD=none)
a266258f 453if test x$CLVMD = xyes; then
5c7fc7c4 454 CLVMD=all
b1098701 455fi
ad6254c5 456AC_MSG_RESULT($CLVMD)
80992638 457
8ce0cbda 458dnl -- If clvmd enabled without cluster locking, automagically include it
a266258f 459if test x$CLVMD != xnone && test x$CLUSTER = xnone; then
d3c8211f
AK
460 CLUSTER=internal
461fi
d3c8211f 462
90c80887 463dnl -- init pkgconfig if required
34b6075d 464if test x$CLVMD != xnone && test x$PKGCONFIG_INIT != x1; then
90c80887
AK
465 pkg_config_init
466fi
467
34b6075d
FDN
468dnl -- Express clvmd init script Required-Start / Required-Stop
469CLVMD_CMANAGERS=""
470dnl -- On RHEL4/RHEL5, qdiskd is started from a separate init script.
7cf60770 471dnl -- Enable if we are build for cman.
34b6075d 472CLVMD_NEEDS_QDISKD=no
90c80887 473
a946372e
AK
474dnl -- define build types
475if [[ `expr x"$CLVMD" : '.*gulm.*'` != 0 ]]; then
7cf60770 476 AC_MSG_ERROR([Since version 2.02.87 GULM locking is no longer supported.]);
34b6075d
FDN
477fi
478if [[ `expr x"$CLVMD" : '.*cman.*'` != 0 ]]; then
479 BUILDCMAN=yes
480 CLVMD_CMANAGERS="$CLVMD_CMANAGERS cman"
481 CLVMD_NEEDS_QDISKD=yes
a946372e
AK
482fi
483if [[ `expr x"$CLVMD" : '.*corosync.*'` != 0 ]]; then
484 BUILDCOROSYNC=yes
34b6075d 485 CLVMD_CMANAGERS="$CLVMD_CMANAGERS corosync"
a946372e
AK
486fi
487if [[ `expr x"$CLVMD" : '.*openais.*'` != 0 ]]; then
488 BUILDOPENAIS=yes
34b6075d 489 CLVMD_CMANAGERS="$CLVMD_CMANAGERS openais"
a946372e 490fi
34b6075d
FDN
491if test x$CLVMD_NEEDS_QDISKD != xno; then
492 CLVMD_CMANAGERS="$CLVMD_CMANAGERS qdiskd"
a946372e
AK
493fi
494
a946372e
AK
495dnl -- define a soft bailout if we are autodetecting
496soft_bailout() {
497 NOTFOUND=1
498}
499
500hard_bailout() {
501 AC_MSG_ERROR([bailing out])
502}
503
504dnl -- if clvmd=all then set soft_bailout (we don't want to error)
505dnl -- and set all builds to yes. We need to do this here
7cf60770 506dnl -- to skip the openais|corosync sanity check above.
a946372e
AK
507if test x$CLVMD = xall; then
508 bailout=soft_bailout
a946372e
AK
509 BUILDCMAN=yes
510 BUILDCOROSYNC=yes
511 BUILDOPENAIS=yes
512else
513 bailout=hard_bailout
514fi
515
516dnl -- helper macro to check libs without adding them to LIBS
517check_lib_no_libs() {
518 lib_no_libs_arg1=$1
519 shift
520 lib_no_libs_arg2=$1
521 shift
522 lib_no_libs_args=$@
523 AC_CHECK_LIB([$lib_no_libs_arg1],
524 [$lib_no_libs_arg2],,
525 [$bailout],
526 [$lib_no_libs_args])
527 LIBS=$ac_check_lib_save_LIBS
528}
529
a946372e
AK
530dnl -- Look for cman libraries if required.
531if test x$BUILDCMAN = xyes; then
532 PKG_CHECK_MODULES(CMAN, libcman, [HAVE_CMAN=yes],
533 [NOTFOUND=0
534 AC_CHECK_HEADERS(libcman.h,,$bailout)
535 check_lib_no_libs cman cman_init
536 if test $NOTFOUND = 0; then
537 AC_MSG_RESULT([no pkg for libcman, using -lcman])
538 CMAN_LIBS="-lcman"
539 HAVE_CMAN=yes
540 fi])
541 CHECKCONFDB=yes
542 CHECKDLM=yes
543fi
544
545dnl -- Look for corosync that's required also for openais build
546dnl -- only enough recent version of corosync ship pkg-config files.
547dnl -- We can safely rely on that to detect the correct bits.
548if test x$BUILDCOROSYNC = xyes || \
549 test x$BUILDOPENAIS = xyes; then
550 PKG_CHECK_MODULES(COROSYNC, corosync, [HAVE_COROSYNC=yes], $bailout)
551 CHECKCONFDB=yes
b6d7a484 552 CHECKCMAP=yes
a946372e
AK
553fi
554
edf47283 555dnl -- Look for corosync libraries if required.
a946372e
AK
556if test x$BUILDCOROSYNC = xyes; then
557 PKG_CHECK_MODULES(QUORUM, libquorum, [HAVE_QUORUM=yes], $bailout)
558 CHECKCPG=yes
559 CHECKDLM=yes
560fi
561
562dnl -- Look for openais libraries if required.
563if test x$BUILDOPENAIS = xyes; then
564 PKG_CHECK_MODULES(SALCK, libSaLck, [HAVE_SALCK=yes], $bailout)
565 CHECKCPG=yes
566fi
567
568dnl -- Below are checks for libraries common to more than one build.
569
570dnl -- Check confdb library.
b6d7a484 571dnl -- mandatory for corosync < 2.0 build.
a946372e
AK
572dnl -- optional for openais/cman build.
573
574if test x$CHECKCONFDB = xyes; then
575 PKG_CHECK_MODULES(CONFDB, libconfdb,
576 [HAVE_CONFDB=yes],
577 [HAVE_CONFDB=no])
578
579 AC_CHECK_HEADERS(corosync/confdb.h,
580 [HAVE_CONFDB_H=yes],
581 [HAVE_CONFDB_H=no])
582
583 if test x$HAVE_CONFDB != xyes && \
584 test x$HAVE_CONFDB_H = xyes; then
585 check_lib_no_libs confdb confdb_initialize
586 AC_MSG_RESULT([no pkg for confdb, using -lconfdb])
587 CONFDB_LIBS="-lconfdb"
588 HAVE_CONFDB=yes
589 fi
b6d7a484
AK
590fi
591
592dnl -- Check cmap library
593dnl -- mandatory for corosync >= 2.0 build.
594
595if test x$CHECKCMAP = xyes; then
596 PKG_CHECK_MODULES(CMAP, libcmap,
597 [HAVE_CMAP=yes],
598 [HAVE_CMAP=no])
a946372e 599
b6d7a484
AK
600 AC_CHECK_HEADERS(corosync/cmap.h,
601 [HAVE_CMAP_H=yes],
602 [HAVE_CMAP_H=no])
603
604 if test x$HAVE_CMAP != xyes && \
605 test x$HAVE_CMAP_H = xyes; then
606 check_lib_no_libs cmap cmap_initialize
607 AC_MSG_RESULT([no pkg for cmap, using -lcmap])
608 CMAP_LIBS="-lcmap"
609 HAVE_CMAP=yes
610 fi
611fi
612
613if test x$BUILDCOROSYNC = xyes; then
614 if test x$HAVE_CMAP != xyes && \
615 test x$HAVE_CONFDB != xyes && \
a946372e 616 test x$CLVMD != xall; then
b6d7a484 617 AC_MSG_ERROR([bailing out... cmap (corosync >= 2.0) or confdb (corosync < 2.0) library is required])
a946372e
AK
618 fi
619fi
620
621dnl -- Check cpg library.
622if test x$CHECKCPG = xyes; then
623 PKG_CHECK_MODULES(CPG, libcpg, [HAVE_CPG=yes], $bailout)
624fi
625
626dnl -- Check dlm library.
627if test x$CHECKDLM = xyes; then
628 PKG_CHECK_MODULES(DLM, libdlm, [HAVE_DLM=yes],
629 [NOTFOUND=0
630 AC_CHECK_HEADERS(libdlm.h,,$bailout)
631 check_lib_no_libs dlm dlm_lock -lpthread
632 if test $NOTFOUND = 0; then
633 AC_MSG_RESULT([no pkg for libdlm, using -ldlm])
634 DLM_LIBS="-ldlm -lpthread"
635 HAVE_DLM=yes
636 fi])
637fi
638
639dnl -- If we are autodetecting, we need to re-create
34b6075d
FDN
640dnl -- the depedencies checks and set a proper CLVMD,
641dnl -- together with init script Required-Start/Stop entries.
a946372e 642if test x$CLVMD = xall; then
8c222979 643 CLVMD=none
34b6075d
FDN
644 CLVMD_CMANAGERS=""
645 CLVMD_NEEDS_QDISKD=no
a946372e
AK
646 if test x$HAVE_CMAN = xyes && \
647 test x$HAVE_DLM = xyes; then
8c222979
FDN
648 AC_MSG_RESULT([Enabling clvmd cman cluster manager])
649 CLVMD="$CLVMD,cman"
34b6075d
FDN
650 CLVMD_CMANAGERS="$CLVMD_CMANAGERS cman"
651 CLVMD_NEEDS_QDISKD=yes
a946372e
AK
652 fi
653 if test x$HAVE_COROSYNC = xyes && \
654 test x$HAVE_QUORUM = xyes && \
655 test x$HAVE_CPG = xyes && \
b6d7a484
AK
656 test x$HAVE_DLM = xyes; then
657 if test x$HAVE_CONFDB = xyes || test x$HAVE_CMAP = xyes; then
8c222979
FDN
658 AC_MSG_RESULT([Enabling clvmd corosync cluster manager])
659 CLVMD="$CLVMD,corosync"
34b6075d 660 CLVMD_CMANAGERS="$CLVMD_CMANAGERS corosync"
b6d7a484 661 fi
a946372e
AK
662 fi
663 if test x$HAVE_COROSYNC = xyes && \
664 test x$HAVE_CPG = xyes && \
665 test x$HAVE_SALCK = xyes; then
8c222979
FDN
666 AC_MSG_RESULT([Enabling clvmd openais cluster manager])
667 CLVMD="$CLVMD,openais"
34b6075d
FDN
668 CLVMD_CMANAGERS="$CLVMD_CMANAGERS openais"
669 fi
670 if test x$CLVMD_NEEDS_QDISKD != xno; then
671 CLVMD_CMANAGERS="$CLVMD_CMANAGERS qdiskd"
8c222979
FDN
672 fi
673 if test x$CLVMD = xnone; then
674 AC_MSG_RESULT([Disabling clvmd build. No cluster manager detected.])
a946372e 675 fi
edf47283
AK
676fi
677
8c4e8a18
FDN
678################################################################################
679dnl -- clvmd pidfile
680if test "x$CLVMD" != xnone; then
681 AC_ARG_WITH(clvmd-pidfile,
682 AC_HELP_STRING([--with-clvmd-pidfile=PATH],
683 [clvmd pidfile [[/var/run/clvmd.pid]]]),
684 CLVMD_PIDFILE=$withval,
685 CLVMD_PIDFILE="/var/run/clvmd.pid")
686 AC_DEFINE_UNQUOTED(CLVMD_PIDFILE, ["$CLVMD_PIDFILE"],
687 [Path to clvmd pidfile.])
688fi
689
3c14bcca 690################################################################################
66fd4529
AK
691dnl -- Build cluster mirror log daemon
692AC_MSG_CHECKING(whether to build cluster mirror log daemon)
71082be4
ZK
693AC_ARG_ENABLE(cmirrord,
694 AC_HELP_STRING([--enable-cmirrord],
695 [enable the cluster mirror log daemon]),
696 CMIRRORD=$enableval, CMIRRORD=no)
66fd4529 697AC_MSG_RESULT($CMIRRORD)
3c14bcca 698
66fd4529
AK
699BUILD_CMIRRORD=$CMIRRORD
700
701################################################################################
702dnl -- cmirrord pidfile
66fd4529
AK
703if test "x$BUILD_CMIRRORD" = xyes; then
704 AC_ARG_WITH(cmirrord-pidfile,
71082be4
ZK
705 AC_HELP_STRING([--with-cmirrord-pidfile=PATH],
706 [cmirrord pidfile [[/var/run/cmirrord.pid]]]),
707 CMIRRORD_PIDFILE=$withval,
708 CMIRRORD_PIDFILE="/var/run/cmirrord.pid")
709 AC_DEFINE_UNQUOTED(CMIRRORD_PIDFILE, ["$CMIRRORD_PIDFILE"],
710 [Path to cmirrord pidfile.])
66fd4529
AK
711fi
712
713################################################################################
3c14bcca 714dnl -- Look for corosync libraries if required.
66fd4529 715if [[ "x$BUILD_CMIRRORD" = xyes ]]; then
90c80887
AK
716 dnl -- init pkgconfig if required
717 if test x$PKGCONFIG_INIT != x1; then
718 pkg_config_init
719 fi
720 PKG_CHECK_MODULES(SACKPT, libSaCkpt)
721 if test x$HAVE_CPG != xyes; then
722 PKG_CHECK_MODULES(CPG, libcpg)
723 fi
3c14bcca
JEB
724fi
725
80992638 726################################################################################
8ce0cbda 727dnl -- Enable debugging
ad6254c5 728AC_MSG_CHECKING(whether to enable debugging)
71082be4
ZK
729AC_ARG_ENABLE(debug, AC_HELP_STRING([--enable-debug], [enable debugging]),
730 DEBUG=$enableval, DEBUG=no)
ad6254c5 731AC_MSG_RESULT($DEBUG)
8ef2b021 732
8ce0cbda
AK
733dnl -- Normally turn off optimisation for debug builds
734if test x$DEBUG = xyes; then
735 COPTIMISE_FLAG=
8a2fc586
AK
736else
737 CSCOPE_CMD=
8ce0cbda
AK
738fi
739
740################################################################################
741dnl -- Override optimisation
ad6254c5 742AC_MSG_CHECKING(for C optimisation flag)
8ce0cbda 743AC_ARG_WITH(optimisation,
71082be4
ZK
744 AC_HELP_STRING([--with-optimisation=OPT],
745 [C optimisation flag [[OPT=-O2]]]),
746 COPTIMISE_FLAG=$withval)
ad6254c5 747AC_MSG_RESULT($COPTIMISE_FLAG)
8ce0cbda 748
fddafd51
ZK
749################################################################################
750dnl -- Enable profiling
5556819a 751AC_MSG_CHECKING(whether to gather gcov profiling data)
fddafd51 752AC_ARG_ENABLE(profiling,
71082be4
ZK
753 AC_HELP_STRING(--enable-profiling, [gather gcov profiling data]),
754 PROFILING=$enableval, PROFILING=no)
5556819a
AK
755AC_MSG_RESULT($PROFILING)
756
757if test "x$PROFILING" = xyes; then
758 COPTIMISE_FLAG="$COPTIMISE_FLAG -fprofile-arcs -ftest-coverage"
fd4728e1
ZK
759 AC_PATH_PROG(LCOV, lcov)
760 AC_PATH_PROG(GENHTML, genhtml)
761 if test -z "$LCOV" -o -z "$GENHTML"; then
b145d876
ZK
762 AC_MSG_ERROR([lcov and genhtml are required for profiling])
763 fi
fd4728e1
ZK
764 AC_PATH_PROG(GENPNG, genpng)
765 if test -n "$GENPNG"; then
766 AC_MSG_CHECKING([whether $GENPNG has all required modules])
767 if $GENPNG --help > /dev/null 2>&1 ; then
768 AC_MSG_RESULT(ok)
769 GENHTML="$GENHTML --frames"
770 else
771 AC_MSG_RESULT(not supported)
772 AC_MSG_WARN([GD.pm perl module is not installed])
773 GENPNG=
774 fi
775 fi
5556819a 776fi
fddafd51 777
1033d120
JT
778################################################################################
779dnl -- Enable testing
780AC_MSG_CHECKING(whether to enable unit testing)
781AC_ARG_ENABLE(testing,
782 AC_HELP_STRING(--enable-testing, [enable testing targets in the makefile]),
783 TESTING=$enableval, TESTING=no)
784AC_MSG_RESULT($TESTING)
785
786if test "$TESTING" = yes; then
5da88e5b 787 PKG_CHECK_MODULES(CUNIT, cunit >= 2.0)
1033d120
JT
788fi
789
52e1564f
JT
790################################################################################
791dnl -- Enable valgrind awareness of memory pools
792AC_MSG_CHECKING(whether to enable valgrind awareness of pools)
793AC_ARG_ENABLE(valgrind_pool,
794 AC_HELP_STRING(--enable-valgrind-pool, [enable valgrind awareness of pools]),
795 VALGRIND_POOL=$enableval, VALGRIND_POOL=no)
796AC_MSG_RESULT($VALGRIND_POOL)
797
798if test "$VALGRIND_POOL" = yes; then
799 AC_CHECK_HEADERS([valgrind/memcheck.h], , [AC_MSG_ERROR(bailing out)])
800 AC_DEFINE([VALGRIND_POOL], 1, [Enable a valgrind aware build of pool])
801fi
802
80992638 803################################################################################
8ce0cbda 804dnl -- Disable devmapper
ad6254c5 805AC_MSG_CHECKING(whether to use device-mapper)
71082be4
ZK
806AC_ARG_ENABLE(devmapper,
807 AC_HELP_STRING([--disable-devmapper],
808 [disable LVM2 device-mapper interaction]),
809 DEVMAPPER=$enableval)
ad6254c5 810AC_MSG_RESULT($DEVMAPPER)
199e490e 811
b896caa1 812if test x$DEVMAPPER = xyes; then
f6fc418d 813 AC_DEFINE([DEVMAPPER_SUPPORT], 1, [Define to 1 to enable LVM2 device-mapper interaction.])
b896caa1
AK
814fi
815
615534d3
PR
816################################################################################
817dnl -- Build lvmetad
818AC_MSG_CHECKING(whether to build LVMetaD)
819AC_ARG_ENABLE(lvmetad,
d38de32b
AK
820 AC_HELP_STRING([--enable-lvmetad],
821 [enable the LVM Metadata Daemon]),
615534d3
PR
822 LVMETAD=$enableval)
823AC_MSG_RESULT($LVMETAD)
824
825BUILD_LVMETAD=$LVMETAD
826
5d518f1f
AK
827################################################################################
828dnl -- Enable udev synchronisation
829AC_MSG_CHECKING(whether to enable synchronisation with udev processing)
71082be4
ZK
830AC_ARG_ENABLE(udev_sync,
831 AC_HELP_STRING([--enable-udev_sync],
832 [enable synchronisation with udev processing]),
833 UDEV_SYNC=$enableval, UDEV_SYNC=no)
5d518f1f
AK
834AC_MSG_RESULT($UDEV_SYNC)
835
836if test x$UDEV_SYNC = xyes; then
86ba564a
AK
837 dnl -- init pkgconfig if required
838 if test x$PKGCONFIG_INIT != x1; then
839 pkg_config_init
840 fi
71b29ddc 841 PKG_CHECK_MODULES(UDEV, libudev >= 143, [UDEV_PC="libudev"])
5d518f1f
AK
842 AC_DEFINE([UDEV_SYNC_SUPPORT], 1, [Define to 1 to enable synchronisation with udev processing.])
843fi
844
845dnl -- Enable udev rules
846AC_MSG_CHECKING(whether to enable installation of udev rules required for synchronisation)
71082be4
ZK
847AC_ARG_ENABLE(udev_rules,
848 AC_HELP_STRING([--enable-udev_rules],
849 [install rule files needed for udev synchronisation]),
850 UDEV_RULES=$enableval, UDEV_RULES=$UDEV_SYNC)
5d518f1f
AK
851AC_MSG_RESULT($UDEV_RULES)
852
f6fc418d
AK
853################################################################################
854dnl -- Compatibility mode
71082be4
ZK
855AC_ARG_ENABLE(compat,
856 AC_HELP_STRING([--enable-compat],
857 [enable support for old device-mapper versions]),
858 DM_COMPAT=$enableval, DM_COMPAT=no)
f6fc418d 859
2061c0ec
AK
860if test x$DM_COMPAT = xyes; then
861 AC_MSG_ERROR(
862 [--enable-compat is not currently supported.
863Since device-mapper version 1.02.66, only one version (4) of the device-mapper
864ioctl protocol is supported.]
865 )
866fi
867
95eaa683
AK
868################################################################################
869dnl -- Compatible units suffix mode
870AC_ARG_ENABLE(units-compat,
71082be4
ZK
871 AC_HELP_STRING([--enable-units-compat],
872 [enable output compatibility with old versions that
873 that do not use KiB-style unit suffixes]),
874 UNITS_COMPAT=$enableval, UNITS_COMPAT=no)
95eaa683
AK
875
876if test x$UNITS_COMPAT = xyes; then
877 AC_DEFINE([DEFAULT_SI_UNIT_CONSISTENCY], 0, [Define to 0 to reinstate the pre-2.02.54 handling of unit suffixes.])
878fi
879
f6fc418d
AK
880################################################################################
881dnl -- Disable ioctl
71082be4
ZK
882AC_ARG_ENABLE(ioctl,
883 AC_HELP_STRING([--disable-driver],
884 [disable calls to device-mapper in the kernel]),
885 DM_IOCTLS=$enableval)
f6fc418d 886
80992638 887################################################################################
8ce0cbda 888dnl -- Disable O_DIRECT
ad6254c5 889AC_MSG_CHECKING(whether to enable O_DIRECT)
71082be4
ZK
890AC_ARG_ENABLE(o_direct,
891 AC_HELP_STRING([--disable-o_direct], [disable O_DIRECT]),
892 ODIRECT=$enableval)
ad6254c5 893AC_MSG_RESULT($ODIRECT)
2dc95e1c
AK
894
895if test x$ODIRECT = xyes; then
72b2cb61 896 AC_DEFINE([O_DIRECT_SUPPORT], 1, [Define to 1 to enable O_DIRECT support.])
2dc95e1c
AK
897fi
898
572fefeb
AK
899################################################################################
900dnl -- Enable liblvm2app.so
901AC_MSG_CHECKING(whether to build liblvm2app.so application library)
902AC_ARG_ENABLE(applib,
71082be4
ZK
903 AC_HELP_STRING([--enable-applib], [build application library]),
904 APPLIB=$enableval, APPLIB=no)
572fefeb
AK
905AC_MSG_RESULT($APPLIB)
906AC_SUBST([LVM2APP_LIB])
907test x$APPLIB = xyes \
908 && LVM2APP_LIB=-llvm2app \
909 || LVM2APP_LIB=
910
80992638 911################################################################################
8ce0cbda 912dnl -- Enable cmdlib
ad6254c5 913AC_MSG_CHECKING(whether to compile liblvm2cmd.so)
71082be4
ZK
914AC_ARG_ENABLE(cmdlib,
915 AC_HELP_STRING([--enable-cmdlib], [build shared command library]),
916 CMDLIB=$enableval, CMDLIB=no)
ad6254c5 917AC_MSG_RESULT($CMDLIB)
aa4d1e31 918AC_SUBST([LVM2CMD_LIB])
2a9a80c9 919test x$CMDLIB = xyes \
aa4d1e31
JM
920 && LVM2CMD_LIB=-llvm2cmd \
921 || LVM2CMD_LIB=
8106cdd5 922
f6fc418d
AK
923################################################################################
924dnl -- Enable pkg-config
71082be4
ZK
925AC_ARG_ENABLE(pkgconfig,
926 AC_HELP_STRING([--enable-pkgconfig], [install pkgconfig support]),
927 PKGCONFIG=$enableval, PKGCONFIG=no)
2a9a80c9 928
23b059e7
ZK
929################################################################################
930dnl -- Enable installation of writable files by user
71082be4
ZK
931AC_ARG_ENABLE(write_install,
932 AC_HELP_STRING([--enable-write_install],
933 [install user writable files]),
934 WRITE_INSTALL=$enableval, WRITE_INSTALL=no)
23b059e7 935
80992638 936################################################################################
8ce0cbda 937dnl -- Enable fsadm
1995c9ff 938AC_MSG_CHECKING(whether to install fsadm)
71082be4
ZK
939AC_ARG_ENABLE(fsadm, AC_HELP_STRING([--disable-fsadm], [disable fsadm]),
940 FSADM=$enableval)
ad6254c5 941AC_MSG_RESULT($FSADM)
809fae91 942
06f62ad1
AK
943################################################################################
944dnl -- enable dmeventd handling
945AC_MSG_CHECKING(whether to use dmeventd)
71082be4
ZK
946AC_ARG_ENABLE(dmeventd, AC_HELP_STRING([--enable-dmeventd],
947 [enable the device-mapper event daemon]),
948 DMEVENTD=$enableval)
06f62ad1
AK
949AC_MSG_RESULT($DMEVENTD)
950
f6fc418d
AK
951BUILD_DMEVENTD=$DMEVENTD
952
06f62ad1 953dnl -- dmeventd currently requires internal mirror support
2a9a80c9
PR
954if test x$DMEVENTD = xyes; then
955 if test x$MIRRORS != xinternal; then
956 AC_MSG_ERROR(
957 --enable-dmeventd currently requires --with-mirrors=internal
958 )
959 fi
960 if test x$CMDLIB = xno; then
961 AC_MSG_ERROR(
962 --enable-dmeventd requires --enable-cmdlib to be used as well
963 )
964 fi
06f62ad1
AK
965fi
966
15d91f5a 967if test x$DMEVENTD = xyes; then
72b2cb61 968 AC_DEFINE([DMEVENTD], 1, [Define to 1 to enable the device-mapper event daemon.])
15d91f5a 969fi
f6fc418d
AK
970
971################################################################################
972dnl -- getline included in recent libc
973
974AC_CHECK_LIB(c, getline, AC_DEFINE([HAVE_GETLINE], 1,
975 [Define to 1 if getline is available.]))
976
977################################################################################
978dnl -- canonicalize_file_name included in recent libc
979
980AC_CHECK_LIB(c, canonicalize_file_name,
981 AC_DEFINE([HAVE_CANONICALIZE_FILE_NAME], 1,
982 [Define to 1 if canonicalize_file_name is available.]))
983
80992638 984################################################################################
d0191583 985dnl -- Clear default exec_prefix - install into /sbin rather than /usr/sbin
795ca3e5
AK
986if [[ "x$exec_prefix" = xNONE -a "x$prefix" = xNONE ]];
987 then exec_prefix="";
988fi;
989
80992638 990################################################################################
8ce0cbda 991dnl -- Check for dlopen
19a2c6e0 992AC_CHECK_LIB(dl, dlopen, [
72b2cb61 993 AC_DEFINE([HAVE_LIBDL], 1, [Define to 1 if dynamic libraries are available.])
19a2c6e0
ZK
994 DL_LIBS="-ldl"
995 HAVE_LIBDL=yes ], [
996 DL_LIBS=
997 HAVE_LIBDL=no ])
26e7f2e0 998
80992638 999################################################################################
8ce0cbda 1000dnl -- Check for shared/static conflicts
80992638
AK
1001if [[ \( "x$LVM1" = xshared -o "x$POOL" = xshared -o "x$CLUSTER" = xshared \
1002 -o "x$SNAPSHOTS" = xshared -o "x$MIRRORS" = xshared \
cac52ca4 1003 -o "x$RAID" = xshared \
4922197a 1004 \) -a "x$STATIC_LINK" = xyes ]];
d68a82ec 1005 then AC_MSG_ERROR(
036f273a 1006Features cannot be 'shared' when building statically
d68a82ec 1007)
036f273a
AK
1008fi
1009
f30875db
ZK
1010################################################################################
1011if [[ "$DMEVENTD" = yes -o "$CLVMD" != none ]] ; then
1012 AC_CHECK_LIB([pthread], [pthread_mutex_lock],
1013 [PTHREAD_LIBS="-lpthread"], hard_bailout)
1014fi
1015
d0191583
JM
1016################################################################################
1017dnl -- Disable selinux
1018AC_MSG_CHECKING(whether to enable selinux support)
71082be4
ZK
1019AC_ARG_ENABLE(selinux,
1020 AC_HELP_STRING([--disable-selinux], [disable selinux support]),
1021 SELINUX=$enableval)
d0191583
JM
1022AC_MSG_RESULT($SELINUX)
1023
80992638 1024################################################################################
8a2fc586 1025dnl -- Check for selinux
80992638 1026if test x$SELINUX = xyes; then
f8f6ec92
ZK
1027 AC_CHECK_LIB([sepol], [sepol_check_context], [
1028 AC_DEFINE([HAVE_SEPOL], 1, [Define to 1 if sepol_check_context is available.])
1029 SELINUX_LIBS="-lsepol"])
8a2fc586 1030
f8f6ec92
ZK
1031 AC_CHECK_LIB([selinux], [is_selinux_enabled], [
1032 AC_CHECK_HEADERS([selinux/selinux.h],, hard_bailout)
7dfce0e4 1033 AC_CHECK_HEADERS([selinux/label.h])
72b2cb61 1034 AC_DEFINE([HAVE_SELINUX], 1, [Define to 1 to include support for selinux.])
e1b8a236 1035 SELINUX_LIBS="-lselinux $SELINUX_LIBS"
f7f0854e 1036 SELINUX_PC="libselinux"
f8f6ec92 1037 HAVE_SELINUX=yes ], [
ad6254c5 1038 AC_MSG_WARN(Disabling selinux)
f8f6ec92 1039 SELINUX_LIBS=
f7f0854e 1040 SELINUX_PC=
f8f6ec92 1041 HAVE_SELINUX=no ])
036f273a 1042fi
d68a82ec 1043
8b1a3214
AK
1044################################################################################
1045dnl -- Check for realtime clock support
1046if test x$REALTIME = xyes; then
8b1a3214 1047 AC_CHECK_LIB(rt, clock_gettime, HAVE_REALTIME=yes, HAVE_REALTIME=no)
8b1a3214
AK
1048
1049 if test x$HAVE_REALTIME = xyes; then
1050 AC_DEFINE([HAVE_REALTIME], 1, [Define to 1 to include support for realtime clock.])
1051 LIBS="-lrt $LIBS"
1052 else
1053 AC_MSG_WARN(Disabling realtime clock)
1054 fi
1055fi
1056
80992638 1057################################################################################
8ce0cbda 1058dnl -- Check for getopt
d0191583 1059AC_CHECK_HEADERS(getopt.h, AC_DEFINE([HAVE_GETOPTLONG], 1, [Define to 1 if getopt_long is available.]))
b896caa1 1060
80992638 1061################################################################################
8ce0cbda 1062dnl -- Check for readline (Shamelessly copied from parted 1.4.17)
ea7cfb00 1063if test x$READLINE != xno; then
539f4a77
ZK
1064 lvm_saved_libs=$LIBS
1065 AC_SEARCH_LIBS([tgetent], [tinfo ncurses curses termcap termlib],
1066 READLINE_LIBS=$ac_cv_search_tgetent, [
1067 if test "$READLINE" = yes; then
1068 AC_MSG_ERROR(
1069[termcap could not be found which is required for the
1070--enable-readline option (which is enabled by default). Either disable readline
1071support with --disable-readline or download and install termcap from:
1072 ftp.gnu.org/gnu/termcap
1073Note: if you are using precompiled packages you will also need the development
1074 package as well (which may be called termcap-devel or something similar).
1075Note: (n)curses also seems to work as a substitute for termcap. This was
1076 not found either - but you could try installing that as well.])
1077 fi])
1078 dnl -- Old systems may need extra termcap dependency explicitly in LIBS
1079 AC_CHECK_LIB([readline], [readline], [
1080 AC_DEFINE([READLINE_SUPPORT], 1,
1081 [Define to 1 to include the LVM readline shell.])
1082 dnl -- Try only with -lreadline and check for different symbol
1083 LIBS=$lvm_saved_libs
1084 AC_CHECK_LIB([readline], [rl_line_buffer],
1085 [ READLINE_LIBS="-lreadline" ], [
1086 AC_MSG_RESULT([linking -lreadline with $READLINE_LIBS needed])
1087 READLINE_LIBS="-lreadline $READLINE_LIBS"
1088 ]) ], [
1089 READLINE_LIBS=
1090 if test "$READLINE" = yes; then
1091 AC_MSG_ERROR(
1092[GNU Readline could not be found which is required for the
795ca3e5
AK
1093--enable-readline option (which is enabled by default). Either disable readline
1094support with --disable-readline or download and install readline from:
1095 ftp.gnu.org/gnu/readline
1096Note: if you are using precompiled packages you will also need the development
539f4a77
ZK
1097package as well (which may be called readline-devel or something similar).])
1098 fi ])
1099 LIBS="$READLINE_LIBS $lvm_saved_libs"
1100 AC_CHECK_FUNCS([rl_completion_matches])
1101 LIBS=$lvm_saved_libs
795ca3e5
AK
1102fi
1103
80992638 1104################################################################################
8ce0cbda 1105dnl -- Internationalisation stuff
ad6254c5 1106AC_MSG_CHECKING(whether to enable internationalisation)
71082be4
ZK
1107AC_ARG_ENABLE(nls,
1108 AC_HELP_STRING([--enable-nls], [enable Native Language Support]),
1109 INTL=$enableval, INTL=no)
ad6254c5 1110AC_MSG_RESULT($INTL)
69792976
AK
1111
1112if test x$INTL = xyes; then
f6fc418d 1113# FIXME - Move this - can be device-mapper too
69792976
AK
1114 INTL_PACKAGE="lvm2"
1115 AC_PATH_PROG(MSGFMT, msgfmt)
1116 if [[ "x$MSGFMT" == x ]];
1117 then AC_MSG_ERROR(
1118 msgfmt not found in path $PATH
1119 )
69792976
AK
1120 fi;
1121
1122 AC_ARG_WITH(localedir,
71082be4
ZK
1123 AC_HELP_STRING([--with-localedir=DIR],
1124 [translation files in DIR
1125 [[PREFIX/share/locale]]]),
1126 LOCALEDIR=$withval, LOCALEDIR='${prefix}/share/locale')
69792976
AK
1127fi
1128
80992638 1129################################################################################
4a7f3eb2 1130AC_ARG_WITH(confdir,
71082be4
ZK
1131 AC_HELP_STRING([--with-confdir=DIR],
1132 [configuration files in DIR [[/etc]]]),
1133 CONFDIR=$withval, CONFDIR="/etc")
0a62c911
AK
1134
1135AC_ARG_WITH(staticdir,
71082be4
ZK
1136 AC_HELP_STRING([--with-staticdir=DIR],
1137 [static binaries in DIR [[EPREFIX/sbin]]]),
1138 STATICDIR=$withval, STATICDIR='${exec_prefix}/sbin')
0a62c911 1139
68f2de6d 1140AC_ARG_WITH(usrlibdir,
71082be4
ZK
1141 AC_HELP_STRING([--with-usrlibdir=DIR],
1142 [usrlib in DIR [[PREFIX/lib]]]),
1143 usrlibdir=$withval, usrlibdir='${prefix}/lib')
68f2de6d
AK
1144
1145AC_ARG_WITH(usrsbindir,
71082be4
ZK
1146 AC_HELP_STRING([--with-usrsbindir=DIR],
1147 [usrsbin executables in DIR [[PREFIX/sbin]]]),
1148 usrsbindir=$withval, usrsbindir='${prefix}/sbin')
68f2de6d 1149
5d518f1f
AK
1150################################################################################
1151AC_ARG_WITH(udev_prefix,
71082be4
ZK
1152 AC_HELP_STRING([--with-udev-prefix=UPREFIX],
1153 [install udev rule files in UPREFIX [[EPREFIX]]]),
1154 udev_prefix=$withval, udev_prefix='${exec_prefix}')
5d518f1f 1155
78ce7acc 1156AC_ARG_WITH(udevdir,
71082be4
ZK
1157 AC_HELP_STRING([--with-udevdir=DIR],
1158 [udev rules in DIR [[UPREFIX/lib/udev/rules.d]]]),
1159 udevdir=$withval, udevdir='${udev_prefix}/lib/udev/rules.d')
5d518f1f 1160
ad6254c5
AK
1161################################################################################
1162dnl -- Ensure additional headers required
1163if test x$READLINE = xyes; then
1164 AC_CHECK_HEADERS(readline/readline.h readline/history.h,,AC_MSG_ERROR(bailing out))
1165fi
1166
5c7fc7c4 1167if test x$CLVMD != xnone; then
ad6254c5
AK
1168 AC_CHECK_HEADERS(mntent.h netdb.h netinet/in.h pthread.h search.h sys/mount.h sys/socket.h sys/uio.h sys/un.h utmpx.h,,AC_MSG_ERROR(bailing out))
1169 AC_CHECK_FUNCS(dup2 getmntent memmove select socket,,AC_MSG_ERROR(bailing out))
1170 AC_FUNC_GETMNTENT
ad6254c5
AK
1171 AC_FUNC_SELECT_ARGTYPES
1172fi
1173
ad6254c5
AK
1174if test x$CLUSTER != xnone; then
1175 AC_CHECK_HEADERS(sys/socket.h sys/un.h,,AC_MSG_ERROR(bailing out))
1176 AC_CHECK_FUNCS(socket,,AC_MSG_ERROR(bailing out))
1177fi
1178
d911ec67
AK
1179if test x$DMEVENTD = xyes; then
1180 AC_CHECK_HEADERS(arpa/inet.h,,AC_MSG_ERROR(bailing out))
1181fi
1182
ad6254c5
AK
1183if test x$HAVE_LIBDL = xyes; then
1184 AC_CHECK_HEADERS(dlfcn.h,,AC_MSG_ERROR(bailing out))
1185fi
1186
1187if test x$INTL = xyes; then
1188 AC_CHECK_HEADERS(libintl.h,,AC_MSG_ERROR(bailing out))
1189fi
1190
5d518f1f
AK
1191if test x$UDEV_SYNC = xyes; then
1192 AC_CHECK_HEADERS(sys/ipc.h sys/sem.h,,AC_MSG_ERROR(bailing out))
1193fi
1194
a653923f
AK
1195################################################################################
1196AC_PATH_PROG(MODPROBE_CMD, modprobe)
1197
1198if test x$MODPROBE_CMD != x; then
72b2cb61 1199 AC_DEFINE_UNQUOTED([MODPROBE_CMD], ["$MODPROBE_CMD"], [The path to 'modprobe', if available.])
a653923f
AK
1200fi
1201
a9b601e2
ZK
1202
1203lvm_exec_prefix=$exec_prefix
1204test "$lvm_exec_prefix" = NONE && lvm_exec_prefix=$prefix
1205test "$lvm_exec_prefix" = NONE && lvm_exec_prefix=$ac_default_prefix
d2c11605
ZK
1206LVM_PATH="$lvm_exec_prefix/sbin/lvm"
1207AC_DEFINE_UNQUOTED(LVM_PATH, ["$LVM_PATH"], [Path to lvm binary.])
b5c2529b
ZK
1208
1209if test "$CLVMD" != none; then
1210 clvmd_prefix=$ac_default_prefix
d2c11605 1211 CLVMD_PATH="$clvmd_prefix/sbin/clvmd"
b5c2529b 1212 test "$prefix" != NONE && clvmd_prefix=$prefix
d2c11605 1213 AC_DEFINE_UNQUOTED(CLVMD_PATH, ["$CLVMD_PATH"], [Path to clvmd binary.])
b5c2529b
ZK
1214fi
1215
80992638 1216################################################################################
f6fc418d 1217dnl -- dmeventd pidfile and executable path
f6fc418d
AK
1218if test "$BUILD_DMEVENTD" = yes; then
1219 AC_ARG_WITH(dmeventd-pidfile,
71082be4
ZK
1220 AC_HELP_STRING([--with-dmeventd-pidfile=PATH],
1221 [dmeventd pidfile [[/var/run/dmeventd.pid]]]),
1222 DMEVENTD_PIDFILE=$withval,
1223 DMEVENTD_PIDFILE="/var/run/dmeventd.pid")
1224 AC_DEFINE_UNQUOTED(DMEVENTD_PIDFILE, ["$DMEVENTD_PIDFILE"],
1225 [Path to dmeventd pidfile.])
f6fc418d
AK
1226fi
1227
f6fc418d 1228if test "$BUILD_DMEVENTD" = yes; then
f6fc418d 1229 AC_ARG_WITH(dmeventd-path,
71082be4
ZK
1230 AC_HELP_STRING([--with-dmeventd-path=PATH],
1231 [dmeventd path [[EPREFIX/sbin/dmeventd]]]),
1232 DMEVENTD_PATH=$withval,
1233 DMEVENTD_PATH="$lvm_exec_prefix/sbin/dmeventd")
1234 AC_DEFINE_UNQUOTED(DMEVENTD_PATH, ["$DMEVENTD_PATH"],
1235 [Path to dmeventd binary.])
f6fc418d
AK
1236fi
1237
8bae0a1e
AK
1238AH_TEMPLATE(DEFAULT_RUN_DIR, [Name of default run directory.])
1239AC_ARG_WITH(default-run-dir,
1240 [ --with-default-run-dir=DIR Default run directory [[/var/run/lvm]] ],
1241 [ DEFAULT_RUN_DIR="$withval" ],
1242 [ DEFAULT_RUN_DIR="/var/run/lvm" ])
1243AC_DEFINE_UNQUOTED(DEFAULT_RUN_DIR,["$DEFAULT_RUN_DIR"] )
1244
3399ae32
AK
1245################################################################################
1246dnl -- various defaults
3399ae32 1247AC_ARG_WITH(default-system-dir,
71082be4
ZK
1248 AC_HELP_STRING([--with-default-system-dir=DIR],
1249 [default LVM system directory [[/etc/lvm]]]),
1250 DEFAULT_SYS_DIR=$withval, DEFAULT_SYS_DIR="/etc/lvm")
1251AC_DEFINE_UNQUOTED(DEFAULT_SYS_DIR, ["$DEFAULT_SYS_DIR"],
1252 [Path to LVM system directory.])
3399ae32 1253
3399ae32 1254AC_ARG_WITH(default-archive-subdir,
71082be4
ZK
1255 AC_HELP_STRING([--with-default-archive-subdir=SUBDIR],
1256 [default metadata archive subdir [[archive]]]),
1257 DEFAULT_ARCHIVE_SUBDIR=$withval, DEFAULT_ARCHIVE_SUBDIR=archive)
1258AC_DEFINE_UNQUOTED(DEFAULT_ARCHIVE_SUBDIR, ["$DEFAULT_ARCHIVE_SUBDIR"],
1259 [Name of default metadata archive subdirectory.])
3399ae32 1260
3399ae32 1261AC_ARG_WITH(default-backup-subdir,
71082be4
ZK
1262 AC_HELP_STRING([--with-default-backup-subdir=SUBDIR],
1263 [default metadata backup subdir [[backup]]]),
1264 DEFAULT_BACKUP_SUBDIR=$withval, DEFAULT_BACKUP_SUBDIR=backup)
1265AC_DEFINE_UNQUOTED(DEFAULT_BACKUP_SUBDIR, ["$DEFAULT_BACKUP_SUBDIR"],
1266 [Name of default metadata backup subdirectory.])
3399ae32 1267
3399ae32 1268AC_ARG_WITH(default-cache-subdir,
71082be4
ZK
1269 AC_HELP_STRING([--with-default-cache-subdir=SUBDIR],
1270 [default metadata cache subdir [[cache]]]),
1271 DEFAULT_CACHE_SUBDIR=$withval, DEFAULT_CACHE_SUBDIR=cache)
1272AC_DEFINE_UNQUOTED(DEFAULT_CACHE_SUBDIR, ["$DEFAULT_CACHE_SUBDIR"],
1273 [Name of default metadata cache subdirectory.])
3399ae32 1274
3399ae32 1275AC_ARG_WITH(default-locking-dir,
71082be4
ZK
1276 AC_HELP_STRING([--with-default-locking-dir=DIR],
1277 [default locking directory [[/var/lock/lvm]]]),
1278 DEFAULT_LOCK_DIR=$withval, DEFAULT_LOCK_DIR="/var/lock/lvm")
1279AC_DEFINE_UNQUOTED(DEFAULT_LOCK_DIR, ["$DEFAULT_LOCK_DIR"],
1280 [Name of default locking directory.])
3399ae32 1281
7063efe1
MS
1282################################################################################
1283dnl -- Setup default data alignment
1284AC_ARG_WITH(default-data-alignment,
1285 AC_HELP_STRING([--with-default-data-alignment=NUM],
1286 [set the default data alignment in MiB [[1]]]),
1287 DEFAULT_DATA_ALIGNMENT=$withval, DEFAULT_DATA_ALIGNMENT=1)
1288AC_DEFINE_UNQUOTED(DEFAULT_DATA_ALIGNMENT, [$DEFAULT_DATA_ALIGNMENT],
1289 [Default data alignment.])
1290
f6fc418d
AK
1291################################################################################
1292dnl -- which kernel interface to use (ioctl only)
1293AC_MSG_CHECKING(for kernel interface choice)
1294AC_ARG_WITH(interface,
71082be4
ZK
1295 AC_HELP_STRING([--with-interface=IFACE],
1296 [choose kernel interface (ioctl) [[ioctl]]]),
1297 interface=$withval, interface=ioctl)
f6fc418d
AK
1298if [[ "x$interface" != xioctl ]];
1299then
1300 AC_MSG_ERROR(--with-interface=ioctl required. fs no longer supported.)
1301fi
1302AC_MSG_RESULT($interface)
1303
1304################################################################################
db8b5af9 1305DM_LIB_VERSION="\"`cat "$srcdir"/VERSION_DM 2>/dev/null || echo Unknown`\""
f58b35b5
AK
1306AC_DEFINE_UNQUOTED(DM_LIB_VERSION, $DM_LIB_VERSION, [Library version])
1307
db8b5af9 1308DM_LIB_PATCHLEVEL=`cat "$srcdir"/VERSION_DM | $AWK -F '[[-. ]]' '{printf "%s.%s.%s",$1,$2,$3}'`
597c3f8e 1309
db8b5af9 1310LVM_VERSION="\"`cat "$srcdir"/VERSION 2>/dev/null || echo Unknown`\""
fae0c576 1311
db8b5af9 1312VER=`cat "$srcdir"/VERSION`
bf456146 1313LVM_RELEASE_DATE="\"`echo $VER | $SED 's/.* (//;s/).*//'`\""
ec6a6fbe
AK
1314VER=`echo "$VER" | $AWK '{print $1}'`
1315LVM_RELEASE="\"`echo "$VER" | $AWK -F '-' '{print $2}'`\""
1316VER=`echo "$VER" | $AWK -F '-' '{print $1}'`
1317LVM_MAJOR=`echo "$VER" | $AWK -F '.' '{print $1}'`
1318LVM_MINOR=`echo "$VER" | $AWK -F '.' '{print $2}'`
bf456146
AK
1319LVM_PATCHLEVEL=`echo "$VER" | $AWK -F '[[(.]]' '{print $3}'`
1320LVM_LIBAPI=`echo "$VER" | $AWK -F '[[()]]' '{print $2}'`
ec6a6fbe 1321
80992638 1322################################################################################
572fefeb 1323AC_SUBST(APPLIB)
aaa2e046 1324AC_SUBST(AWK)
66fd4529 1325AC_SUBST(BUILD_CMIRRORD)
d0191583 1326AC_SUBST(BUILD_DMEVENTD)
615534d3 1327AC_SUBST(BUILD_LVMETAD)
b896caa1 1328AC_SUBST(CFLAGS)
d0191583 1329AC_SUBST(CFLOW_CMD)
8106cdd5 1330AC_SUBST(CLDFLAGS)
8106cdd5 1331AC_SUBST(CLDNOWHOLEARCHIVE)
d0191583
JM
1332AC_SUBST(CLDWHOLEARCHIVE)
1333AC_SUBST(CLUSTER)
1334AC_SUBST(CLVMD)
34b6075d 1335AC_SUBST(CLVMD_CMANAGERS)
d2c11605 1336AC_SUBST(CLVMD_PATH)
a946372e
AK
1337AC_SUBST(CMAN_CFLAGS)
1338AC_SUBST(CMAN_LIBS)
b6d7a484
AK
1339AC_SUBST(CMAP_CFLAGS)
1340AC_SUBST(CMAP_LIBS)
d0191583 1341AC_SUBST(CMDLIB)
edf47283
AK
1342AC_SUBST(CONFDB_CFLAGS)
1343AC_SUBST(CONFDB_LIBS)
1344AC_SUBST(CONFDIR)
d0191583 1345AC_SUBST(COPTIMISE_FLAG)
edf47283
AK
1346AC_SUBST(CPG_CFLAGS)
1347AC_SUBST(CPG_LIBS)
d0191583 1348AC_SUBST(CSCOPE_CMD)
8ef2b021 1349AC_SUBST(DEBUG)
3399ae32
AK
1350AC_SUBST(DEFAULT_SYS_DIR)
1351AC_SUBST(DEFAULT_ARCHIVE_SUBDIR)
1352AC_SUBST(DEFAULT_BACKUP_SUBDIR)
1353AC_SUBST(DEFAULT_CACHE_SUBDIR)
7063efe1 1354AC_SUBST(DEFAULT_DATA_ALIGNMENT)
3399ae32 1355AC_SUBST(DEFAULT_LOCK_DIR)
b1f08e51 1356AC_SUBST(DEFAULT_RUN_DIR)
199e490e 1357AC_SUBST(DEVMAPPER)
a946372e
AK
1358AC_SUBST(DLM_CFLAGS)
1359AC_SUBST(DLM_LIBS)
19a2c6e0 1360AC_SUBST(DL_LIBS)
d0191583 1361AC_SUBST(DMEVENTD)
d1e8046f 1362AC_SUBST(DMEVENTD_PATH)
d0191583
JM
1363AC_SUBST(DM_COMPAT)
1364AC_SUBST(DM_DEVICE_GID)
1365AC_SUBST(DM_DEVICE_MODE)
1366AC_SUBST(DM_DEVICE_UID)
1367AC_SUBST(DM_IOCTLS)
1368AC_SUBST(DM_LIB_VERSION)
597c3f8e 1369AC_SUBST(DM_LIB_PATCHLEVEL)
bf09a320 1370AC_SUBST(ELDFLAGS)
d0191583 1371AC_SUBST(FSADM)
26e7f2e0 1372AC_SUBST(HAVE_LIBDL)
8b1a3214 1373AC_SUBST(HAVE_REALTIME)
d0191583
JM
1374AC_SUBST(INTL)
1375AC_SUBST(INTL_PACKAGE)
1376AC_SUBST(JOBS)
1377AC_SUBST(LDDEPS)
1378AC_SUBST(LIBS)
1379AC_SUBST(LIB_SUFFIX)
69792976 1380AC_SUBST(LOCALEDIR)
d0191583
JM
1381AC_SUBST(LVM1)
1382AC_SUBST(LVM1_FALLBACK)
d0191583 1383AC_SUBST(LVM_VERSION)
bf456146 1384AC_SUBST(LVM_LIBAPI)
ec6a6fbe
AK
1385AC_SUBST(LVM_MAJOR)
1386AC_SUBST(LVM_MINOR)
1387AC_SUBST(LVM_PATCHLEVEL)
d2c11605 1388AC_SUBST(LVM_PATH)
ec6a6fbe
AK
1389AC_SUBST(LVM_RELEASE)
1390AC_SUBST(LVM_RELEASE_DATE)
d0191583 1391AC_SUBST(MIRRORS)
cac52ca4 1392AC_SUBST(MSGFMT)
e40d44be 1393AC_SUBST(OCF)
349da06c 1394AC_SUBST(OCFDIR)
d0191583
JM
1395AC_SUBST(PKGCONFIG)
1396AC_SUBST(POOL)
f30875db 1397AC_SUBST(PTHREAD_LIBS)
edf47283
AK
1398AC_SUBST(QUORUM_CFLAGS)
1399AC_SUBST(QUORUM_LIBS)
cac52ca4 1400AC_SUBST(RAID)
539f4a77 1401AC_SUBST(READLINE_LIBS)
cac52ca4 1402AC_SUBST(REPLICATORS)
90c80887
AK
1403AC_SUBST(SACKPT_CFLAGS)
1404AC_SUBST(SACKPT_LIBS)
a946372e
AK
1405AC_SUBST(SALCK_CFLAGS)
1406AC_SUBST(SALCK_LIBS)
e1b8a236 1407AC_SUBST(SELINUX_LIBS)
f7f0854e 1408AC_SUBST(SELINUX_PC)
d0191583 1409AC_SUBST(SNAPSHOTS)
0a62c911 1410AC_SUBST(STATICDIR)
d0191583 1411AC_SUBST(STATIC_LINK)
1033d120 1412AC_SUBST(TESTING)
3ba4a195 1413AC_SUBST(THIN)
db724a44 1414AC_SUBST(UDEV_LIBS)
f7f0854e 1415AC_SUBST(UDEV_PC)
5d518f1f 1416AC_SUBST(UDEV_RULES)
4df024c4 1417AC_SUBST(UDEV_SYNC)
5da88e5b
PR
1418AC_SUBST(CUNIT_LIBS)
1419AC_SUBST(CUNIT_CFLAGS)
23b059e7 1420AC_SUBST(WRITE_INSTALL)
395d204d 1421AC_SUBST(DMEVENTD_PIDFILE)
f6fc418d
AK
1422AC_SUBST(interface)
1423AC_SUBST(kerneldir)
1424AC_SUBST(missingkernel)
1425AC_SUBST(kernelvsn)
1426AC_SUBST(tmpdir)
5d518f1f
AK
1427AC_SUBST(udev_prefix)
1428AC_SUBST(udevdir)
68f2de6d
AK
1429AC_SUBST(usrlibdir)
1430AC_SUBST(usrsbindir)
8106cdd5 1431
80992638 1432################################################################################
d3a356b4 1433dnl -- First and last lines should not contain files to generate in order to
8ce0cbda 1434dnl -- keep utility scripts running properly
d3a356b4
JM
1435AC_CONFIG_FILES([
1436Makefile
1437make.tmpl
1438daemons/Makefile
1439daemons/clvmd/Makefile
5d311afb 1440daemons/cmirrord/Makefile
13dd3138 1441daemons/common/Makefile
f6fc418d
AK
1442daemons/dmeventd/Makefile
1443daemons/dmeventd/libdevmapper-event.pc
b7edb5bf 1444daemons/dmeventd/plugins/Makefile
d3d98fdc 1445daemons/dmeventd/plugins/lvm2/Makefile
3041b72f 1446daemons/dmeventd/plugins/raid/Makefile
f6fc418d
AK
1447daemons/dmeventd/plugins/mirror/Makefile
1448daemons/dmeventd/plugins/snapshot/Makefile
2bc1d759 1449daemons/dmeventd/plugins/thin/Makefile
615534d3 1450daemons/lvmetad/Makefile
d3a356b4 1451doc/Makefile
da05c479 1452doc/example.conf
db8b5af9 1453include/.symlinks
f6fc418d
AK
1454include/Makefile
1455lib/Makefile
d3a356b4
JM
1456lib/format1/Makefile
1457lib/format_pool/Makefile
1458lib/locking/Makefile
1459lib/mirror/Makefile
8fea97b7 1460lib/replicator/Makefile
ec6a6fbe 1461lib/misc/lvm-version.h
40dbaac8 1462lib/raid/Makefile
d3a356b4 1463lib/snapshot/Makefile
3ba4a195 1464lib/thin/Makefile
f6fc418d
AK
1465libdm/Makefile
1466libdm/libdevmapper.pc
e0c64c6c 1467liblvm/Makefile
70046623 1468liblvm/liblvm2app.pc
f6fc418d
AK
1469man/Makefile
1470po/Makefile
2de38033 1471scripts/clvmd_init_red_hat
81410c8f 1472scripts/cmirrord_init_red_hat
595eaf92 1473scripts/lvm2_monitoring_init_red_hat
395d204d
PR
1474scripts/dm_event_systemd_red_hat.service
1475scripts/lvm2_monitoring_systemd_red_hat.service
d3a356b4 1476scripts/Makefile
f6fc418d 1477test/Makefile
c7e363f9 1478test/api/Makefile
d4fed285 1479test/unit/Makefile
d3a356b4 1480tools/Makefile
5d518f1f 1481udev/Makefile
66392e66 1482unit-tests/datastruct/Makefile
15106c50 1483unit-tests/regex/Makefile
52e1564f 1484unit-tests/mm/Makefile
7a197a62
AK
1485])
1486AC_OUTPUT
2dc95e1c
AK
1487
1488if test x$ODIRECT != xyes; then
ad6254c5 1489 AC_MSG_WARN(Warning: O_DIRECT disabled: low-memory pvmove may lock up)
2dc95e1c 1490fi
This page took 0.273686 seconds and 5 git commands to generate.