1 # Makefile for the UCW Charset Library (c) 1997--2007 Martin Mares <mj@ucw.cz>
5 LIBCHARSET_MODS=toupper tolower tocat toligatures unaccent charconv setnames fb-charconv stk-charconv mp-charconv
6 LIBCHARSET_INCLUDES=charconv.h unicat.h fb-charconv.h stk-charconv.h mp-charconv.h
8 $(o)/charset/libcharset.a: $(addsuffix .o,$(addprefix $(o)/charset/,$(LIBCHARSET_MODS)))
9 $(o)/charset/libcharset-pic.a: $(addsuffix .oo,$(addprefix $(o)/charset/,$(LIBCHARSET_MODS)))
10 $(o)/charset/libcharset.so: $(addsuffix .oo,$(addprefix $(o)/charset/,$(LIBCHARSET_MODS)))
11 $(o)/charset/libcharset.pc: $(LIBUCW)
13 ifdef CONFIG_STATIC_PIC
14 $(o)/charset/libcharset.pc: $(o)/charset/libcharset-pic.a
18 API_INCLUDES+=$(o)/charset/.include-stamp
19 $(o)/charset/.include-stamp: $(addprefix $(s)/charset/,$(LIBCHARSET_INCLUDES))
20 $(o)/charset/.include-stamp: IDST=charset
21 run/lib/pkgconfig/libcharset.pc: $(o)/charset/libcharset.pc
23 ifdef CONFIG_CHARSET_UTILS
24 PROGS+=$(o)/charset/cs2cs
27 $(o)/charset/cs2cs: $(o)/charset/cs2cs.o $(LIBUCW) $(o)/charset/libcharset.pc
30 cd $(s)/charset && sh misc/generate
33 rm -f $(s)/charset/misc/u-*
35 INSTALL_TARGETS+=install-libcharset
37 install -d -m 755 $(DESTDIR)$(INSTALL_INCLUDE_DIR)/charset $(DESTDIR)$(INSTALL_LIB_DIR) $(DESTDIR)$(INSTALL_PKGCONFIG_DIR)
38 install -m 644 $(addprefix run/include/charset/,$(LIBCHARSET_INCLUDES)) $(DESTDIR)$(INSTALL_INCLUDE_DIR)/charset
39 install -m 644 run/lib/libcharset.$(LS) $(DESTDIR)$(INSTALL_LIB_DIR)
40 install -m 644 run/lib/pkgconfig/libcharset.pc $(DESTDIR)$(INSTALL_PKGCONFIG_DIR)
41 ifdef CONFIG_STATIC_PIC
42 install -m 644 run/lib/libcharset-pic.$(LS) $(DESTDIR)$(INSTALL_LIB_DIR)
45 .PHONY: install-libcharset