1 # Makefile for the stand-alone release of Sherlock libraries
2 # (c) 2007 Martin Mares <mj@ucw.cz>
5 all: runtree libs api programs extras configs
7 # Include configuration
11 @echo "You need to run configure first." && false
15 # We will use the libucw build system
16 include $(BUILDSYS)/Maketop
18 # Install the build system
19 include $(BUILDSYS)/Makefile
21 # Set up names of common libraries (to avoid forward references in rules)
23 LIBCHARSET=$(o)/charset/libcharset.pc
25 ifdef CONFIG_SHERLOCK_LIB
26 LIBSH=$(o)/sherlock/libsh.pc
27 LIBSHXML=$(o)/sherlock/xml/libshxml.pc
30 TESTING_DEPS=$(LIBUCW)
34 include $(s)/ucw/Makefile
36 # Install config files
37 ifdef CONFIG_SHERLOCK_LIB
38 FREE_CONFIGS=sherlock local
39 CONFIGS+=$(FREE_CONFIGS)
41 INSTALL_TARGETS+=install-configs
43 install -d -m 755 $(DESTDIR)$(INSTALL_CONFIG_DIR)
44 install -m 644 $(addprefix run/$(CONFIG_DIR)/,$(FREE_CONFIGS)) $(DESTDIR)$(INSTALL_CONFIG_DIR)
47 # Include submakefiles of requested libraries
48 ifdef CONFIG_SHERLOCK_LIB
49 include $(s)/sherlock/Makefile
53 include $(s)/charset/Makefile
57 LIBLANG=$(o)/lang/liblang.pc
58 include $(s)/lang/Makefile
62 LIBIMAGES=$(o)/images/libimages.pc
63 include $(s)/images/Makefile
66 # Build documentation by default?
71 libs: $(LIBUCW) $(LIBSH) $(LIBIMAGES) $(LIBCHARSET) $(LIBLANG)
73 # And finally the default rules of the build system
74 include $(BUILDSYS)/Makebottom
77 install: all $(INSTALL_TARGETS)
80 @echo "Nothing to install, this is a local build." && false