summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorДилян Палаузов <dilyan.palauzov@aegee.org>2012-02-12 16:23:36 (GMT)
committerJunio C Hamano <gitster@pobox.com>2012-02-13 08:11:01 (GMT)
commitb5225286b226759262c0637058528af03226fba6 (patch)
tree527324aee510bb76384c1e7684951c8ba91e43c8 /Makefile
parent828ea97de486c1693d6e4f2c7347acb50235a85d (diff)
downloadgit-b5225286b226759262c0637058528af03226fba6.zip
git-b5225286b226759262c0637058528af03226fba6.tar.gz
git-b5225286b226759262c0637058528af03226fba6.tar.bz2
Makefile: introduce CHARSET_LIB to link with -lcharset
On some systems, the function locale_charset() may not be exported from libiconv but is available from libcharset, and we need -lcharset when linking. Introduce a make variable CHARSET_LIB that can be set to -lcharsetlib on such systems. Also autodetect this in the configure script by first looking for the symbol in libiconv, and then libcharset. Signed-off-by: Дилян Палаузов <dilyan.palauzov@aegee.org>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 5 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index a782409..3b2b804 100644
--- a/Makefile
+++ b/Makefile
@@ -53,6 +53,10 @@ all::
# FreeBSD can use either, but MinGW and some others need to use
# libcharset.h's locale_charset() instead.
#
+# Define CHARSET_LIB to you need to link with library other than -liconv to
+# use locale_charset() function. On some platforms this needs to set to
+# -lcharset
+#
# Define LIBC_CONTAINS_LIBINTL if your gettext implementation doesn't
# need -lintl when linking.
#
@@ -1692,6 +1696,7 @@ endif
ifdef HAVE_LIBCHARSET_H
BASIC_CFLAGS += -DHAVE_LIBCHARSET_H
+ EXTLIBS += $(CHARSET_LIB)
endif
ifdef HAVE_DEV_TTY