1 ## Makefile.in for ICU - tools/icuinfo
2 ## Copyright (C) 2016 and later: Unicode, Inc. and others.
3 ## License & terms of use: http://www.unicode.org/copyright.html
4 ## Copyright (c) 1999-2015, International Business Machines Corporation and
5 ## others. All Rights Reserved.
8 ## Source directory information
10 top_srcdir = @top_srcdir@
14 include $(top_builddir)/icudefs.mk
16 ## Build directory information
17 subdir = tools/icuinfo
19 ## Extra files to remove for 'make clean'
20 CLEANFILES = *~ $(DEPS) $(PLUGIN_OBJECTS) $(PLUGINFILE) $(PLUGIN)
23 TARGET = icuinfo$(EXEEXT)
25 CPPFLAGS += -I$(top_srcdir)/common -I$(srcdir)/../toolutil -I$(top_srcdir)/tools/ctestfw
26 CPPFLAGS+= -I$(top_srcdir)/i18n
27 LIBS = $(LIBICUTOOLUTIL) $(LIBICUI18N) $(LIBICUUC) $(DEFAULT_LIBS) $(LIB_M)
30 @PLUGINS_TRUE@PLUGIN_OBJECTS = testplug.o
32 DEPS = $(OBJECTS:.o=.d)
34 # pass some information
36 ICUINFO_OPTS=-i ../../data/out/build/$(ICUDATA_PLATFORM_NAME) -x $(top_builddir)/config/icuinfo.xml -v -K
38 ## List of phony targets
39 .PHONY : all all-local install install-local clean clean-local \
40 distclean distclean-local dist dist-local check check-local plugin-check
45 ## List of standard targets
47 install: install-local
49 distclean : distclean-local
51 check: all check-local
55 install-local: all-local
56 $(MKINSTALLDIRS) $(DESTDIR)$(bindir)
57 $(INSTALL) $(TARGET) $(DESTDIR)$(bindir)
62 test -z "$(CLEANFILES)" || $(RMV) $(CLEANFILES)
63 $(RMV) $(TARGET) $(OBJECTS)
65 distclean-local: clean-local
68 check-local: $(TARGET)
69 $(INVOKE) ./$(TARGET) $(ICUINFO_OPTS)
71 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
73 && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
74 -include Makefile.local
76 $(TARGET) : $(OBJECTS)
77 $(LINK.cc) $(OUTOPT)$@ $^ $(LIBS)
80 PLUGIN=$(LIBPREFIX)plugin.$(SO)
83 PLUGINDIR=$(shell pwd)
85 PLUGINFILE=$(PLUGINDIR)/icuplugins$(SO_TARGET_VERSION_MAJOR).txt
87 CFLAGS+=$(SHAREDLIBCFLAGS)
89 @PLUGINS_TRUE@HAVE_PLUGINS=yes
91 ifeq ($(HAVE_PLUGINS),yes)
92 $(PLUGINFILE): Makefile
93 echo "$(CURR_FULL_DIR)/$(PLUGIN) myPlugin x=4" > $@
96 $(PLUGIN): $(PLUGIN_OBJECTS)
97 $(SHLIB.cc) $(SHAREDLIBCFLAGS) $(LD_SONAME) $(OUTOPT)$@ $^ $(LIBS)
101 plugin-check: $(PLUGIN) $(PLUGINFILE)
102 $(INVOKE) ICU_PLUGINS="$(CURR_FULL_DIR)" ./$(TARGET) -v -L
104 plugin plugin-check $(PLUGIN):
105 @echo "Plugins are disabled (use --enable-plugins to enable)"
108 ifeq (,$(MAKECMDGOALS))
111 ifneq ($(patsubst %clean,,$(MAKECMDGOALS)),)