summaryrefslogtreecommitdiff
path: root/cpp/config/Make.rules.AIX
blob: 3dc3954da8fadfb696b0bf5ff51e5fe059a76c65 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# **********************************************************************
#
# Copyright (c) 2003-2004 ZeroC, Inc. All rights reserved.
#
# This copy of Ice is licensed to you under the terms described in the
# ICE_LICENSE file included in this distribution.
#
# **********************************************************************

#
# This file is included by Make.rules when uname is AIX.
#

CXX               	:= xlC_r
CC                      := xlc_r -qcpluscmt

# 
# -qstaticinline: make inline functions that were not inlined (typically 
# in debug mode or when the function is too big) static instead of
# extern (the default). This eliminates lots of "Duplicate symbol"
# warnings at link time, and surprisingly reduces the size of the
# libraries.
#
# -D_LARGE_FILES: By default, Berkeley DB is built with -D_LARGE_FILES,
# which moves a number of symbols from namespace std to namespace
# std::_LSF_ON. It would be nice to find a better solution, and get
# rid of this define.
#
# -qalign=natural: You should add this option if you plan to use or 
# build Ice with libraries built with GCC. The default alignment for GCC 
# is "natural", while the default for xlC is "power".
#

ifneq ($(OBJECT_MODE),64)
    CXXARCHFLAGS        := -D_LARGE_FILES 
endif

CXXFLAGS		= -brtl -qrtti=all -qstaticinline $(CXXARCHFLAGS)

ifeq ($(OPTIMIZE),yes)
     CXXFLAGS		:= -O2 -DNDEBUG $(CXXFLAGS) -qinline
else
     CXXFLAGS		:= -g $(CXXFLAGS)
endif


LDPLATFORMFLAGS         = -Wl,-blibpath:$(prefix)/lib:/usr/lpp/xlopt:/usr/lib/threads:/usr/vacpp/lib:/usr/lib:/lib

mklibfilename           = lib$(1).a
mklibname               = lib$(1).notused
mklibtargets            = $(1)

mkshlib                 = $(CXX) -qmkshrobj $(LDFLAGS) -o $(2) $(3) $(4) ; ar -rc $(1) $(2) ; rm $(2)

installlib              = $(INSTALL) $(2)/$(3) $(1)

BASELIBS		= -lIceUtil
LIBS			= -lIce $(BASELIBS)

ICEUTIL_OS_LIBS         :=
ICE_OS_LIBS             :=

export LIBPATH      := $(libdir):$(LIBPATH)