diff --git a/INSTALL.md b/INSTALL.md index 66a51a5..9f5eafd 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -160,7 +160,7 @@ Notes ### Linking to an Existing BookmarkFS Utility Library If a BookmarkFS utility library is already installed, it can be - specified with `--with-bookmarkfs[=]` during configuration, + specified with `--with-bookmarkfs-util[=]` during configuration, in the same way as with other dependencies. In this case, the utility library will not be built from source, diff --git a/Makefile.am b/Makefile.am index 8f860fe..73d58cc 100644 --- a/Makefile.am +++ b/Makefile.am @@ -9,4 +9,4 @@ ACLOCAL_AMFLAGS = -I m4 SUBDIRS = doc src tests -pkgconfig_DATA = bookmarkfs.pc +pkgconfig_DATA = bookmarkfs_util.pc diff --git a/bookmarkfs.pc.in b/bookmarkfs_util.pc.in similarity index 89% rename from bookmarkfs.pc.in rename to bookmarkfs_util.pc.in index a6476bc..d27bf33 100644 --- a/bookmarkfs.pc.in +++ b/bookmarkfs_util.pc.in @@ -14,8 +14,8 @@ exec_prefix=@exec_prefix@ includedir=@includedir@ libdir=@libdir@ -Name: ${package} -Description: BookmarkFS +Name: ${package}_util +Description: BookmarkFS Utility Library Version: ${version} URL: https://www.nongnu.org/bookmarkfs/ Cflags: -I${includedir} diff --git a/configure.ac b/configure.ac index 24e5119..f21195b 100644 --- a/configure.ac +++ b/configure.ac @@ -9,7 +9,7 @@ dnl AC_PREREQ([2.70]) AC_INIT([bookmarkfs], [0.1.0], [bug-bookmarkfs@nongnu.org]) -AC_CONFIG_SRCDIR([bookmarkfs.pc.in]) +AC_CONFIG_SRCDIR([bookmarkfs_util.pc.in]) AC_CONFIG_HEADERS([config.h]) AC_CONFIG_MACRO_DIR([m4]) AC_CONFIG_TESTDIR([tests]) @@ -120,7 +120,7 @@ EX_FEAT([fsck-handler-tcl], [no], [Tcl-based fsck handler]) AX_PTHREAD -EX_DEP([bookmarkfs], [>= 0.1], [BookmarkFS utility library], [ +EX_DEP([bookmarkfs_util], [>= 0.1], [BookmarkFS utility library], [ AS_VAR_SET([enable_bookmarkfs_util], [no]) ]) @@ -219,6 +219,6 @@ AC_CONFIG_FILES([ doc/Makefile src/Makefile tests/Makefile tests/atlocal - bookmarkfs.pc + bookmarkfs_util.pc ]) AC_OUTPUT diff --git a/m4/configure_ext.m4 b/m4/configure_ext.m4 index 504337c..db585d4 100644 --- a/m4/configure_ext.m4 +++ b/m4/configure_ext.m4 @@ -42,19 +42,18 @@ dnl Check whether a package exists with `pkg-config`, dnl and provide an option to specify the package's custom install location. dnl AC_DEFUN([EX_DEP], [ - m4_pushdef([with_var_], [with_]m4_translit([$1], [-], [_])) AC_ARG_WITH([$1], m4_normalize([ - AS_HELP_STRING([--with-$1[[=PKGCONFIGDIR]]], + AS_HELP_STRING([--with-m4_translit([$1], [_], [-])[[=PKGCONFIGDIR]]], [pkg-config search path for $3]) ]), , [ - AS_VAR_SET([with_var_], [no]) + AS_VAR_SET([with_$1], [no]) m4_foreach([feat_name_], [m4_shiftn(4, $@)], [ AS_VAR_IF([enable_]m4_translit(feat_name_, [-], [_]), [yes], [ - AS_VAR_SET([with_var_], [yes]) + AS_VAR_SET([with_$1], [yes]) ]) ]) ]) - AS_VAR_IF([with_var_], [no], [ + AS_VAR_IF([with_$1], [no], [ m4_foreach([feat_name_], [m4_shiftn(4, $@)], [ AS_VAR_IF([enable_]m4_translit(feat_name_, [-], [_]), [yes], [ AC_MSG_ERROR(m4_normalize([ @@ -65,14 +64,13 @@ AC_DEFUN([EX_DEP], [ ]) ], [ AS_VAR_SET([old_pkg_config_path_], ["${PKG_CONFIG_PATH}"]) - AS_VAR_IF([with_var_], [yes], , [ - AS_VAR_SET([PKG_CONFIG_PATH], ["${with_var_}:${PKG_CONFIG_PATH}"]) + AS_VAR_IF([with_$1], [yes], , [ + AS_VAR_SET([PKG_CONFIG_PATH], ["${with_$1}:${PKG_CONFIG_PATH}"]) export PKG_CONFIG_PATH ]) PKG_CHECK_MODULES(m4_toupper([$1]), [$1 $2], [$4]) AS_VAR_SET([PKG_CONFIG_PATH], ["${old_pkg_config_path_}"]) ]) - m4_popdef([with_var_]) ]) dnl