]> git.saurik.com Git - apple/icu.git/blob - icuSources/config/mh-solaris-gcc
ICU-6.2.16.tar.gz
[apple/icu.git] / icuSources / config / mh-solaris-gcc
1 ## -*-makefile-*-
2 ## Solaris-specific setup using gcc
3 ## Copyright (c) 1999-2004, International Business Machines Corporation and
4 ## others. All Rights Reserved.
5
6 ## Flags for position independent code
7 SHAREDLIBCFLAGS = -fPIC
8 SHAREDLIBCXXFLAGS = -fPIC
9 SHAREDLIBCPPFLAGS = -DPIC
10
11 ## Commands to generate dependency files
12 GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS)
13 GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS)
14
15 ## Compiler switch to embed a runtime search path
16 LD_RPATH= -R
17 LD_RPATH_PRE=
18
19 ## Compiler switch to embed a library name
20 LD_SONAME = -h $(notdir $(MIDDLE_SO_TARGET))
21
22 ## The type of assembly needed when pkgdata is used for generating shared libraries.
23 GENCCODE_ASSEMBLY=-a sun
24
25 ## Shared object suffix
26 SO= so
27 ## Non-shared intermediate object suffix
28 STATIC_O = ao
29
30 ## Compilation rules
31 %.$(STATIC_O): $(srcdir)/%.c
32 $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $<
33 %.o: $(srcdir)/%.c
34 $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $<
35
36 %.$(STATIC_O): $(srcdir)/%.cpp
37 $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $<
38 %.o: $(srcdir)/%.cpp
39 $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $<
40
41
42 ## Dependency rules
43 %.d : $(srcdir)/%.c
44 @echo "generating dependency information for $<"
45 @$(SHELL) -ec '$(GEN_DEPS.c) $< \
46 | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \
47 [ -s $@ ] || rm -f $@'
48
49 %.d : $(srcdir)/%.cpp
50 @echo "generating dependency information for $<"
51 @$(SHELL) -ec '$(GEN_DEPS.cc) $< \
52 | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \
53 [ -s $@ ] || rm -f $@'
54
55 ## Versioned libraries rules
56
57 %.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION)
58 $(RM) $@ && ln -s ${<F} $@
59 %.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR)
60 $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@
61
62 ## End Solaris-specific setup