]> mj.ucw.cz Git - libucw.git/blob - xml/Makefile
Packages: Do not install picstatic version of libs.
[libucw.git] / xml / Makefile
1 # Makefile for the XML parser
2 # (c) 2007 Pavel Charvat <pchar@ucw.cz>
3
4 DIRS+=xml
5 PROGS+=$(o)/xml/xml-test
6
7 LIBXML_MODS=common source parse dtd
8 LIBXML_INCLUDES=xml.h dtd.h
9
10 LIBXML_MOD_PATHS=$(addprefix $(o)/xml/,$(LIBXML_MODS))
11
12 $(o)/xml/libucw-xml$(LV).a: $(addsuffix .o,$(LIBXML_MOD_PATHS))
13 $(o)/xml/libucw-xml$(LV)-pic.a: $(addsuffix .oo,$(LIBXML_MOD_PATHS))
14 $(o)/xml/libucw-xml$(LV).so: $(addsuffix .oo,$(LIBXML_MOD_PATHS))
15 $(o)/xml/libucw-xml$(LV).so: SONAME_SUFFIX=.$(UCW_ABI_MAJOR)
16 $(o)/xml/libucw-xml.pc: $(LIBCHARSET)
17
18 ifdef CONFIG_STATIC_PIC
19 $(o)/xml/libucw-xml.pc: $(o)/xml/libucw-xml$(LV)-pic.a
20 endif
21 ifdef CONFIG_INSTALL_API
22 $(o)/xml/libucw-xml.pc: $(addprefix $(o)/xml/libucw-xml$(LV),.a .so)
23 endif
24
25 $(o)/xml/common.o: $(o)/xml/unicat.h
26 $(o)/xml/common.oo: $(o)/xml/unicat.h
27 $(o)/xml/source.o: $(o)/xml/unicat.h
28 $(o)/xml/source.oo: $(o)/xml/unicat.h
29 $(o)/xml/dtd.o: $(o)/xml/unicat.h
30 $(o)/xml/dtd.oo: $(o)/xml/unicat.h
31 $(o)/xml/parse.o: $(o)/xml/unicat.h
32 $(o)/xml/parse.oo: $(o)/xml/unicat.h
33 $(o)/xml/unicat.h: $(s)/xml/unicat.pl
34         $(M)GEN $(addprefix $(o)/xml/unicat,.h .c)
35         $(Q)$< $(addprefix $(o)/xml/unicat,.h .c)
36         $(Q)touch $@
37
38 TESTS+=$(o)/xml/xml-test.test
39 $(o)/xml/xml-test: $(o)/xml/xml-test.o $(LIBXML)
40 $(o)/xml/xml-test.test: $(o)/xml/xml-test
41
42 API_LIBS+=libucw-xml
43 API_INCLUDES+=$(o)/xml/.include-stamp
44 $(o)/xml/.include-stamp: $(addprefix $(s)/xml/,$(LIBXML_INCLUDES))
45 $(o)/xml/.include-stamp: IDST=xml
46 run/lib/pkgconfig/libucw-xml.pc: $(o)/xml/libucw-xml.pc
47
48 INSTALL_TARGETS+=install-libucw-xml-lib
49 install-libucw-xml-lib:
50         install -d -m 755 $(DESTDIR)$(INSTALL_LIB_DIR)
51         install -m 644 run/lib/libucw-xml$(LV).so.$(UCW_ABI_MAJOR) $(DESTDIR)$(INSTALL_LIB_DIR)/libucw-xml$(LV).so.$(UCW_ABI_VERSION)
52 .PHONY: install-libucw-xml-lib
53
54 INSTALL_TARGETS+=install-libucw-xml-api
55 install-libucw-xml-api:
56         install -d -m 755 $(DESTDIR)$(INSTALL_INCLUDE_DIR)/xml $(DESTDIR)$(INSTALL_LIB_DIR) $(DESTDIR)$(INSTALL_PKGCONFIG_DIR)
57         install -m 644 run/lib/pkgconfig/libucw-xml.pc $(DESTDIR)$(INSTALL_PKGCONFIG_DIR)
58         install -m 644 $(addprefix run/include/xml/,$(LIBXML_INCLUDES)) $(DESTDIR)$(INSTALL_INCLUDE_DIR)/xml
59         ln -sf libucw-xml$(LV).so.$(UCW_ABI_VERSION) $(DESTDIR)$(INSTALL_LIB_DIR)/libucw-xml$(LV).so
60         install -m 644 run/lib/libucw-xml$(LV).a $(DESTDIR)$(INSTALL_LIB_DIR)
61 .PHONY: install-libucw-xml-api