build-sys: cleanup BUILD_MOUNT
Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
parent
16ba8d5893
commit
9ead6701a1
41
configure.ac
41
configure.ac
|
@ -355,9 +355,6 @@ AC_DEFINE_UNQUOTED(LIBBLKID_DATE, "$LIBBLKID_DATE", [libblkid date string])
|
|||
if test "x$enable_libblkid" = xyes; then
|
||||
AC_DEFINE(HAVE_LIBBLKID, 1, [Define to 1 if you have the -lblkid.])
|
||||
else
|
||||
if test "x$build_mount" = xyes; then
|
||||
AC_MSG_ERROR([libblkid is needed to build util-linux mount])
|
||||
fi
|
||||
if test "x$enable_fsck" = xyes; then
|
||||
AC_MSG_ERROR([libblkid is needed to build util-linux fsck])
|
||||
fi
|
||||
|
@ -437,17 +434,24 @@ AC_ARG_ENABLE([mount],
|
|||
[], enable_mount=check
|
||||
)
|
||||
build_mount=yes
|
||||
if test "x$enable_mount" = xcheck; then
|
||||
if test "x$linux_os" = xno; then
|
||||
AC_MSG_WARN([non-linux system; do not build mount utilities])
|
||||
build_mount=no
|
||||
fi
|
||||
elif test "x$enable_mount" = xno; then
|
||||
build_mount=no
|
||||
fi
|
||||
UL_REQUIRES_LINUX([mount])
|
||||
UL_REQUIRES_BUILD([mount], [libblkid])
|
||||
AM_CONDITIONAL(BUILD_MOUNT, test "x$build_mount" = xyes)
|
||||
|
||||
|
||||
AC_ARG_ENABLE([libmount-mount],
|
||||
AS_HELP_STRING([--enable-libmount-mount], [link mount(8) with libmount (EXPERIMENTAL)]),
|
||||
[], enable_libmount_mount=no
|
||||
)
|
||||
build_libmount_mount=yes
|
||||
UL_REQUIRES_BUILD([libmount_mount], [mount])
|
||||
UL_REQUIRES_BUILD([libmount_mount], [libmount])
|
||||
if test "x$build_libmount_mount" = xyes; then
|
||||
AC_DEFINE(HAVE_LIBMOUNT_MOUNT, 1, [use libmount for mount(8)])
|
||||
fi
|
||||
AM_CONDITIONAL(BUILD_LIBMOUNT_MOUNT, test "x$build_libmount_mount" = xyes)
|
||||
|
||||
|
||||
AC_ARG_ENABLE([fsck],
|
||||
AS_HELP_STRING([--disable-fsck], [do not build fsck]),
|
||||
[], enable_fsck=yes
|
||||
|
@ -490,21 +494,6 @@ AM_CONDITIONAL(BUILD_UUIDD, test "x$enable_uuidd" = xyes)
|
|||
|
||||
|
||||
|
||||
|
||||
AC_ARG_ENABLE([libmount-mount],
|
||||
AS_HELP_STRING([--enable-libmount-mount], [link mount(8) with libmount (EXPERIMENTAL)]),
|
||||
[], enable_libmount_mount=no
|
||||
)
|
||||
|
||||
case "$build_libmount:$enable_libmount_mount" in
|
||||
no:yes)
|
||||
AC_MSG_ERROR([cannot link mount(8) with libmount when libmount is disabled]) ;;
|
||||
yes:yes)
|
||||
AC_DEFINE(HAVE_LIBMOUNT_MOUNT, 1, [use libmount for mount(8)])
|
||||
esac
|
||||
AM_CONDITIONAL(BUILD_LIBMOUNT_MOUNT, test "x$enable_libmount_mount" = xyes)
|
||||
|
||||
|
||||
AC_ARG_ENABLE([mountpoint],
|
||||
AS_HELP_STRING([--disable-mountpoint], [do not build mountpoint]),
|
||||
[], enable_mountpoint=check
|
||||
|
|
|
@ -29,9 +29,9 @@ srcs_mount = $(srcs_common) $(hdrs_mount) \
|
|||
# generic flags for all programs (except losetup)
|
||||
# -- note that pkg-config autoconf macros (pkg.m4) does not differentiate
|
||||
# between CFLAGS and CPPFLAGS, we follow this behaviour and use CFLAGS only.
|
||||
ldadd_common =
|
||||
ldadd_static =
|
||||
cflags_common = $(AM_CFLAGS)
|
||||
ldadd_common = $(ul_libblkid_la)
|
||||
ldadd_static = $(ul_libblkid_la)
|
||||
cflags_common = $(AM_CFLAGS) -I$(ul_libblkid_incdir)
|
||||
ldflags_static = -all-static
|
||||
|
||||
mount_SOURCES = mount.c $(srcs_mount) $(top_srcdir)/lib/setproctitle.c
|
||||
|
@ -79,11 +79,6 @@ losetup_static_LDFLAGS = $(ldflags_static)
|
|||
losetup_static_CPPFLAGS = -DMAIN $(AM_CPPFLAGS)
|
||||
endif
|
||||
|
||||
if BUILD_LIBBLKID
|
||||
ldadd_common += $(ul_libblkid_la)
|
||||
ldadd_static += $(ul_libblkid_la)
|
||||
cflags_common += -I$(ul_libblkid_incdir)
|
||||
endif
|
||||
|
||||
if HAVE_SELINUX
|
||||
mount_LDADD += $(SELINUX_LIBS)
|
||||
|
|
Loading…
Reference in New Issue