• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1## Makefile.in for ICU - tools/icuinfo
2## Copyright (c) 1999-2011, International Business Machines Corporation and
3## others. All Rights Reserved.
4## Madhu Katragadda
5
6## Source directory information
7srcdir = @srcdir@
8top_srcdir = @top_srcdir@
9
10top_builddir = ../..
11
12include $(top_builddir)/icudefs.mk
13
14## Build directory information
15subdir = tools/icuinfo
16
17## Extra files to remove for 'make clean'
18CLEANFILES = *~ $(DEPS) $(PLUGIN_OBJECTS) $(PLUGINFILE) $(PLUGIN)
19
20## Target information
21TARGET = icuinfo$(EXEEXT)
22
23ifneq ($(top_builddir),$(top_srcdir))
24CPPFLAGS += -I$(top_builddir)/common
25endif
26CPPFLAGS += -I$(top_srcdir)/common -I$(srcdir)/../toolutil -I$(top_srcdir)/tools/ctestfw
27CPPFLAGS+= -I$(top_srcdir)/i18n
28LIBS = $(LIBICUTOOLUTIL) $(LIBICUI18N) $(LIBICUUC) $(DEFAULT_LIBS) $(LIB_M)
29
30OBJECTS = icuinfo.o
31PLUGIN_OBJECTS = testplug.o
32
33DEPS = $(OBJECTS:.o=.d)
34
35# pass some information
36
37ICUINFO_OPTS=-i ../../data/out/build/$(ICUDATA_PLATFORM_NAME)
38
39CPPFLAGS+=  "-DU_PLATFORM=\"@platform@\""  "-DU_BUILD=\"@build@\"" "-DU_HOST=\"@host@\"" "-DU_CC=\"@CC@\"" "-DU_CXX=\"@CXX@\""
40
41## List of phony targets
42.PHONY : all all-local install install-local clean clean-local		\
43distclean distclean-local dist dist-local check check-local plugin-check
44
45## Clear suffix list
46.SUFFIXES :
47
48## List of standard targets
49all: all-local
50install: install-local
51clean: clean-local
52distclean : distclean-local
53dist: dist-local
54check: all check-local
55
56all-local: $(TARGET)
57
58install-local: all-local
59	$(MKINSTALLDIRS) $(DESTDIR)$(bindir)
60	$(INSTALL) $(TARGET) $(DESTDIR)$(bindir)
61
62dist-local:
63
64clean-local:
65	test -z "$(CLEANFILES)" || $(RMV) $(CLEANFILES)
66	$(RMV) $(TARGET) $(OBJECTS)
67
68distclean-local: clean-local
69	$(RMV) Makefile
70
71check-local: $(TARGET)
72	$(INVOKE) ./$(TARGET) $(ICUINFO_OPTS)
73
74Makefile: $(srcdir)/Makefile.in  $(top_builddir)/config.status
75	cd $(top_builddir) \
76	 && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
77-include Makefile.local
78
79$(TARGET) : $(OBJECTS)
80	$(LINK.cc) $(OUTOPT)$@ $^ $(LIBS)
81	$(POST_BUILD_STEP)
82
83PLUGIN=$(LIBPREFIX)plugin.$(SO)
84SO_TARGET=$(PLUGIN)
85
86PLUGINDIR=$(shell pwd)
87
88PLUGINFILE=$(PLUGINDIR)/icuplugins$(SO_TARGET_VERSION_MAJOR).txt
89
90$(PLUGINFILE): Makefile
91	echo "$(CURR_FULL_DIR)/$(PLUGIN)	myPlugin	x=4" > $@
92
93CFLAGS+=$(SHAREDLIBCFLAGS)
94
95$(PLUGIN): $(PLUGIN_OBJECTS)
96	$(SHLIB.cc) $(SHAREDLIBCFLAGS) $(LD_SONAME) $(OUTOPT)$@ $^ $(LIBS)
97
98plugin: $(PLUGIN)
99
100plugin-check: $(PLUGIN) $(PLUGINFILE)
101	$(INVOKE) ICU_PLUGINS="$(CURR_FULL_DIR)" ./$(TARGET) -v -L
102
103
104ifeq (,$(MAKECMDGOALS))
105-include $(DEPS)
106else
107ifneq ($(patsubst %clean,,$(MAKECMDGOALS)),)
108-include $(DEPS)
109endif
110endif
111
112