diff options
author | Peter Pentchev <roam@ringlet.net> | 2022-12-29 00:04:40 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-28 23:04:40 +0100 |
commit | 1f35c466aaa9444335a1b854b0b7223b0d2346c2 (patch) | |
tree | d8f76a98ec6d1d21000b178c63d6f9c1d8cf28c1 | |
parent | 8e47e56c9d629d26dee7d949836e2b87dc219351 (diff) | |
download | libarchive-1f35c466aaa9444335a1b854b0b7223b0d2346c2.tar.gz |
Only add "iconv" to the .pc file if needed (#1825)
Hi,
Thanks for writing and maintaining libarchive!
What do you think about this trivial change that does not add "iconv" to
the pkg-config file's list of required packages unless it is actually
needed? On at least Debian GNU/Linux systems, the iconv(3) function is
part of the system C library and there is no Debian package that
installs an iconv.pc file, so I had to make this change to the Debian
package of libarchive.
Thanks again, and keep up the great work!
G'luck,
Peter
-rw-r--r-- | configure.ac | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac index 99bff20d..e2715cfd 100644 --- a/configure.ac +++ b/configure.ac @@ -378,7 +378,9 @@ if test "x$with_iconv" != "xno"; then AC_CHECK_HEADERS([localcharset.h]) am_save_LIBS="$LIBS" LIBS="${LIBS} ${LIBICONV}" - LIBSREQUIRED="$LIBSREQUIRED${LIBSREQUIRED:+ }iconv" + if test -n "$LIBICONV"; then + LIBSREQUIRED="$LIBSREQUIRED${LIBSREQUIRED:+ }iconv" + fi AC_CHECK_FUNCS([locale_charset]) LIBS="${am_save_LIBS}" if test "x$ac_cv_func_locale_charset" != "xyes"; then |