]> git.saurik.com Git - apple/icu.git/blame - icuSources/config/mh-linux-va
ICU-461.12.tar.gz
[apple/icu.git] / icuSources / config / mh-linux-va
CommitLineData
374ca955
A
1## -*-makefile-*-
2## Linux-specific setup for Visual Age
729e4ab9 3## Copyright (c) 2003-2010, International Business Machines Corporation and
374ca955
A
4## others. All Rights Reserved.
5
6## Commands to generate dependency files
7GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS)
8GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS)
9
10# -qroconst make the strings readonly, which is usually the default.
11# This helps in the data library,
12# -qproto assumes all functions are prototyped (for optimization)
13CFLAGS += -qproto -qroconst
14CXXFLAGS += -qproto -qroconst
15
16GENCCODE_ASSEMBLY=-a gcc
17## Flags for position independent code
18SHAREDLIBCFLAGS = -qpic=large
19SHAREDLIBCXXFLAGS = -qpic=large
20SHAREDLIBCPPFLAGS = -DPIC
21
22## Additional flags when building libraries and with threads
374ca955 23THREADSCPPFLAGS = -D_REENTRANT
73c04bcf 24LIBCPPFLAGS =
374ca955
A
25
26## Compiler switch to embed a runtime search path
729e4ab9 27LD_RPATH= -Wl,-zorigin,-rpath,'$$'ORIGIN
374ca955
A
28#LD_RPATH_PRE = -Wl,-rpath,
29
73c04bcf
A
30## Compiler switch to embed a library name
31# The initial tab in the next line is to prevent icu-config from reading it.
32 LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET))
33#SH# # We can't depend on MIDDLE_SO_TARGET being set.
34#SH# LD_SONAME=
374ca955
A
35
36## The type of assembly needed when pkgdata is used for generating shared libraries.
37GENCCODE_ASSEMBLY=-a gcc
38
39## Shared object suffix
40SO = so
41## Non-shared intermediate object suffix
42STATIC_O = ao
43
44## Override the default mechanism for building shared objects
45SHLIB.c= $(CC) $(CFLAGS) -qmkshrobj -qpic=large -G $(LDFLAGS)
46SHLIB.cc= $(CXX) $(CXXFLAGS) -qmkshrobj -qpic=large -G $(LDFLAGS)
47
48## Compilation rules
49%.$(STATIC_O): $(srcdir)/%.c
50 $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $<
51%.o: $(srcdir)/%.c
52 $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $<
53
54%.$(STATIC_O): $(srcdir)/%.cpp
55 $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $<
56%.o: $(srcdir)/%.cpp
57 $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $<
58
59
60## Dependency rules
61%.d: $(srcdir)/%.c
62 @echo "generating dependency information for $<"
63 @$(SHELL) -ec '$(GEN_DEPS.c) $< > /dev/null'
64
65%.d: $(srcdir)/%.cpp
66 @echo "generating dependency information for $<"
67 @$(SHELL) -ec '$(GEN_DEPS.cc) $< > /dev/null'
68
69## Versioned libraries rules
70
71%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION)
72 $(RM) $@ && ln -s ${<F} $@
73%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR)
74 $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@
75
76## End Linux-specific setup
77