Files
harbour-core/harbour/config/linux/sunpro.cf
Viktor Szakats a26febda16 2009-08-11 01:52 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
* config/bsd/gcc.cf
  * config/wce/msvcarm.cf
  * config/wce/mingwarm.cf
  * config/wce/poccarm.cf
  * config/hpux/gcc.cf
  * config/darwin/gcc.cf
  * config/dos/watcom.cf
  * config/dos/djgpp.cf
  * config/win/watcom.cf
  * config/win/icc.cf
  * config/win/cygwin.cf
  * config/win/msvc.cf
  * config/win/xcc.cf
  * config/win/mingw.cf
  * config/win/pocc.cf
  * config/win/bcc.cf
  * config/linux/watcom.cf
  * config/linux/gcc.cf
  * config/linux/icc.cf
  * config/linux/sunpro.cf
  * config/os2/watcom.cf
  * config/os2/gcc.cf
  * config/sunos/gcc.cf
  * config/sunos/sunpro.cf
    + Indentation.
    * Minor cleanups (to GT dependency lib sections, deleted 
      check for hbrtl, it's enough to check for the gt name)
2009-08-10 23:53:56 +00:00

97 lines
2.0 KiB
CFEngine3

#
# $Id$
#
ifeq ($(HB_BUILD_MODE),cpp)
HB_CMP := sunCC
else
HB_CMP := suncc
endif
OBJ_EXT := .o
LIB_PREF := lib
LIB_EXT := .a
CC := $(HB_CCACHE) $(HB_CCPREFIX)$(HB_CMP)
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, )
CPPFLAGS = -I. -I$(HB_INC_COMPILE)
# 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.
# may inherit -m64 from sunpro64.cf, which supersedes -xarch=386
HB_ISAOPT ?= -xarch=386
LDFLAGS ?= $(HB_ISAOPT)
export HB_ISAOPT
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 $(HB_ISAOPT)
endif
CFLAGS += -KPIC
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_CCPREFIX)$(HB_CMP)
LD_OUT := -o$(subst x,x, )
# Add all libraries specified in LIBS.
LINKPATHS += -L$(LIB_DIR)
LINKLIBS += $(foreach lib,$(LIBS),-l$(lib))
# Add the specified GT driver library
ifneq ($(findstring gtcrs, $(LIBS)),)
ifeq ($(HB_CRS_LIB),)
HB_CRS_LIB := ncurses
endif
LINKLIBS += -l$(HB_CRS_LIB)
endif
ifneq ($(findstring gtsln, $(LIBS)),)
LINKLIBS += -lslang
endif
ifneq ($(findstring gtxwc, $(LIBS)),)
LINKLIBS += -lX11
LINKPATHS += -L/usr/X11R6/lib
endif
# HB_GPM_MOUSE: use gpm mouse driver
ifeq ($(HB_GPM_MOUSE),yes)
LINKLIBS += -lgpm
endif
ifneq ($(findstring -DHB_PCRE_REGEX, $(HB_USER_CFLAGS)),)
LINKLIBS += -lpcre
endif
ifneq ($(findstring -DHB_EXT_ZLIB, $(HB_USER_CFLAGS)),)
LINKLIBS += -lz
endif
LINKLIBS += -lm -lrt -ldl
LDFLAGS += $(LINKPATHS)
AR := $(HB_CCPREFIX)ar
ARFLAGS = $(HB_USER_AFLAGS)
AR_RULE = $(AR) $(ARFLAGS) crs $(LIB_DIR)/$@ $(^F) || ( $(RM) $(LIB_DIR)/$@ && false )
include $(TOP)$(ROOT)config/rules.cf