]> mj.ucw.cz Git - libucw.git/blob - free/libs/Makefile
Fix DTD in libucw page
[libucw.git] / free / libs / Makefile
1 # Makefile for the stand-alone release of Sherlock libraries
2 # (c) 2007 Martin Mares <mj@ucw.cz>
3
4 # The default target
5 all: runtree libs api programs extras configs
6
7 # Include configuration
8 s=.
9 -include obj/config.mk
10 obj/config.mk:
11         @echo "You need to run configure first." && false
12
13 BUILDSYS=$(s)/build
14
15 # We will use the libucw build system
16 include $(BUILDSYS)/Maketop
17
18 # Install the build system
19 include $(BUILDSYS)/Makefile
20
21 # The UCW library
22 include $(s)/ucw/Makefile
23
24 # Stripped down version
25 ifndef CONFIG_UCW_ONLY
26
27 # Install config files
28 FREE_CONFIGS=sherlock local
29 CONFIGS+=$(FREE_CONFIGS)
30
31 INSTALL_TARGETS+=install-configs
32 install-configs:
33         install -d -m 755 $(DESTDIR)$(INSTALL_CONFIG_DIR)
34         install -m 644 $(addprefix run/$(CONFIG_DIR)/,$(FREE_CONFIGS)) $(DESTDIR)$(INSTALL_CONFIG_DIR)
35
36 # Set up names of common libraries (to avoid forward references in rules)
37 LIBCHARSET=$(o)/charset/libcharset.pc
38 LIBSH=$(o)/sherlock/libsh.pc
39 LIBSHXML=$(o)/sherlock/xml/libshxml.pc
40
41 # Include makefiles of libraries we wish to use
42 include $(s)/charset/Makefile
43 include $(s)/sherlock/Makefile
44
45 ifdef CONFIG_LANG
46 LIBLANG=$(o)/lang/liblang.pc
47 include $(s)/lang/Makefile
48 endif
49
50 ifdef CONFIG_IMAGES
51 LIBIMAGES=$(o)/images/libimages.pc
52 include $(s)/images/Makefile
53 endif
54
55 endif
56
57 # Build documentation by default?
58 ifdef CONFIG_DOC
59 all: docs
60 endif
61
62 libs: $(LIBUCW) $(LIBSH) $(LIBIMAGES) $(LIBCHARSET) $(LIBLANG)
63
64 # And finally the default rules of the build system
65 include $(BUILDSYS)/Makebottom
66
67 ifndef CONFIG_LOCAL
68 install: all $(INSTALL_TARGETS)
69 else
70 install:
71         @echo "Nothing to install, this is a local build." && false
72 endif
73 .PHONY: install