* INSTALL
+ Minor tuning here and there.
* external/libhpdf/Makefile
+ Enabled libpng detection on darwin.
* config/linux/icc.mk
* config/linux/sunpro.mk
+ Implemented PIC compilation phase.
* config/linux/global.mk
* Deleted hacks dealing with PIC. Notice that now
we use -fpic on gcc/icc, while it was previously
set to -fPIC. The old hacks enabled PIC only for
Intel x86/x86_64 ABIs, which is now removed. Pls
speak up if we need to readd them on compiler
level. This way it'd be possible to optimize out second
compilation pass for ABIs which don't need special
PIC code generation. To make this useful in a generic
way, IMO we should fix ABI (CPU) HB_HOST_CPU/HB_CPU
detection in global.mk for *nix systems, and do
compiler level decisions based on HB_CPU value.
* config/linux/gcc.mk
* Minor option reordering.
80 lines
1.8 KiB
Makefile
80 lines
1.8 KiB
Makefile
#
|
|
# $Id$
|
|
#
|
|
|
|
ifeq ($(HB_BUILD_MODE),cpp)
|
|
HB_CMP := sunCC
|
|
else
|
|
HB_CMP := suncc
|
|
endif
|
|
|
|
OBJ_EXT := .o
|
|
LIB_PREF := lib
|
|
LIB_EXT := .a
|
|
|
|
HB_DYN_COPT := -DHB_DYNLIB -KPIC
|
|
|
|
CC := $(HB_CCACHE) $(HB_CCPATH)$(HB_CCPREFIX)$(HB_CMP)$(HB_CCPOSTFIX)
|
|
CC_IN := -c
|
|
# NOTE: The ending space after -o is important, please preserve it.
|
|
# Now solved with '$(subst x,x, )' expression.
|
|
CC_OUT := -o$(subst x,x, )
|
|
|
|
CXX := $(HB_CCACHE) $(HB_CCPATH)$(HB_CCPREFIX)sunCC$(HB_CCPOSTFIX)
|
|
|
|
CPPFLAGS := -I. -I$(HB_INC_COMPILE)
|
|
CFLAGS :=
|
|
LDFLAGS :=
|
|
|
|
# try to keep `-fast' as left as possible, as later optim
|
|
# flags may override values set by `-fast', and this way
|
|
# no warnings are generated.
|
|
|
|
ifneq ($(HB_BUILD_OPTIM),no)
|
|
# Together with $(HB_ISAOPT) above, these are supposed to (somewhat)
|
|
# conform to the Blastwave build standards, see
|
|
# http://wiki.blastwave.org/mediawiki/index.php/Build_Standards
|
|
# Try to keep them this way.
|
|
CFLAGS += -fast
|
|
CFLAGS += -xnolibmopt
|
|
endif
|
|
|
|
export HB_ISAOPT
|
|
|
|
CFLAGS += $(HB_ISAOPT)
|
|
LDFLAGS += $(HB_ISAOPT)
|
|
|
|
ifneq ($(HB_BUILD_WARN),no)
|
|
CFLAGS += -erroff=%none
|
|
else
|
|
CFLAGS += -erroff=%all
|
|
endif
|
|
|
|
ifeq ($(HB_BUILD_DEBUG),yes)
|
|
CFLAGS += -g
|
|
endif
|
|
|
|
LD := $(HB_CCACHE) $(HB_CCPATH)$(HB_CCPREFIX)$(HB_CMP)$(HB_CCPOSTFIX)
|
|
LD_OUT := -o$(subst x,x, )
|
|
|
|
LIBPATHS := $(foreach dir,$(LIB_DIR) $(SYSLIBPATHS),-L$(dir))
|
|
LDLIBS := $(foreach lib,$(LIBS) $(SYSLIBS),-l$(lib))
|
|
|
|
LDFLAGS += $(LIBPATHS)
|
|
|
|
AR := ar
|
|
ARFLAGS :=
|
|
AR_RULE = $(AR) $(ARFLAGS) $(HB_USER_AFLAGS) rcs $(LIB_DIR)/$@ $(^F) || ( $(RM) $(LIB_DIR)/$@ && false )
|
|
|
|
DY := $(CC)
|
|
DFLAGS := -G $(HB_ISAOPT) $(LIBPATHS)
|
|
ifneq ($(HB_BUILD_OPTIM),no)
|
|
DFLAGS += -fast -xnolibmopt
|
|
endif
|
|
DY_OUT := -o$(subst x,x, )
|
|
DLIBS := $(foreach lib,$(SYSLIBS),-l$(lib))
|
|
|
|
DY_RULE = $(DY) $(DFLAGS) $(HB_USER_DFLAGS) $(DY_OUT)$(DYN_DIR)/$@ $^ $(DLIBS)
|
|
|
|
include $(TOP)$(ROOT)config/rules.mk
|