diff --git a/config/CONFIG.Host.solaris b/config/CONFIG.Host.solaris index 8f922cfdf..88e9bff23 100644 --- a/config/CONFIG.Host.solaris +++ b/config/CONFIG.Host.solaris @@ -36,7 +36,6 @@ ACC_ANSI = $(ACC) -Xa -v ACC_STRICT = $(ACC) -Xc -v ACC_TRAD = $(ACC) -Xs ACC_DEP_CFLAGS = -KPIC - ACC_WARN_YES = ACC_WARN_NO = -w ACC_OPT_YES = -O @@ -66,18 +65,15 @@ CCC_DEPENDS_FLAG = -xM1 CCC_SHRLIB_CFLAGS_YES = CCC_SHRLIB_LDFLAGS_YES = -G -h $@ -z ignore -z combreloc -z lazyload - -ARCH_DEP_CFLAGS = -DSOLARIS=$(subst 5.,,$(shell uname -r)) +SOLARIS_VERSION = $(subst 5.,,$(shell uname -r)) +ARCH_DEP_CPPFLAGS += -DSOLARIS=$(SOLARIS_VERSION) POSIX_CPPFLAGS_YES += -D__EXTENSIONS__ # socket and nsl needed by libca.a ARCH_DEP_LDLIBS += -lsocket -lnsl ARCH_DEP_LDLIBS += -lposix4 -lpthread +ARCH_DEP_LDLIBS_8 = -lCrun +ARCH_DEP_LDLIBS += $(ARCH_DEP_LDLIBS_$(SOLARIS_VERSION)) #Allows R3.13 built extensions to load R3.14 shared libs -SYS_DLL_LIBS_solaris += posix4 pthread -ifeq ($(subst 5.,,$(shell uname -r)),8) -SYS_DLL_LIBS_solaris += Crun -endif - - +SYS_DLL_LIBS_solaris += posix4 pthread $(ARCH_DEP_LDLIBS_$(SOLARIS_VERSION)) diff --git a/config/CONFIG.Host.solaris-sparc-gnu b/config/CONFIG.Host.solaris-sparc-gnu index 563015385..4cb318585 100644 --- a/config/CONFIG.Host.solaris-sparc-gnu +++ b/config/CONFIG.Host.solaris-sparc-gnu @@ -10,8 +10,5 @@ # $Id$ # solaris-sparc is the new name for solaris --include $(EPICS_BASE)/config/CONFIG.Host.solaris - -ANSI=GCC -CPLUSPLUS=G++ +-include $(EPICS_BASE)/config/CONFIG.Host.solarisGnu diff --git a/config/CONFIG.Host.solaris-x86 b/config/CONFIG.Host.solaris-x86 index 5d1ce5ece..4ee29a35e 100644 --- a/config/CONFIG.Host.solaris-x86 +++ b/config/CONFIG.Host.solaris-x86 @@ -15,8 +15,5 @@ -include $(EPICS_BASE)/config/CONFIG.Host.solaris # Solaris on x86 -ARCH_DEP_CFLAGS = -DSOLARIS=$(subst 5.,,$(shell uname -r)) -D_X86_ -D__EXTENSIONS__ - -GCC = gcc -G++ = g++ +ARCH_DEP_CPPFLAGS += -D_X86_ diff --git a/config/CONFIG.Host.solaris-x86-gnu b/config/CONFIG.Host.solaris-x86-gnu index 64c8884e9..303470891 100644 --- a/config/CONFIG.Host.solaris-x86-gnu +++ b/config/CONFIG.Host.solaris-x86-gnu @@ -12,14 +12,8 @@ # This file is maintained by the EPICS community. # Sites may override these definitions in CONFIG_SITE.Host.solaris-x86 --include $(EPICS_BASE)/config/CONFIG.Host.solaris +-include $(EPICS_BASE)/config/CONFIG.Host.solarisGnu # Solaris on x86 -ARCH_DEP_CFLAGS = -DSOLARIS -D_X86_ - -GCC = gcc -G++ = g++ - -ANSI=GCC -CPLUSPLUS=G++ +ARCH_DEP_CPPFLAGS += -D_X86_ diff --git a/config/CONFIG.Host.solarisGnu b/config/CONFIG.Host.solarisGnu new file mode 100644 index 000000000..558ca1961 --- /dev/null +++ b/config/CONFIG.Host.solarisGnu @@ -0,0 +1,48 @@ +#************************************************************************* +# Copyright (c) 2002 The University of Chicago, as Operator of Argonne +# National Laboratory. +# Copyright (c) 2002 The Regents of the University of California, as +# Operator of Los Alamos National Laboratory. +# EPICS BASE Versions 3.13.7 +# and higher are distributed subject to a Software License Agreement found +# in file LICENSE that is included with this distribution. +#************************************************************************* +# CONFIG.Host.solarisGnu +# +# This file is maintained by the EPICS community. +# Sites may override these definitions in CONFIG_SITE.Host.solarisGnu + +ARCH_CLASS = solaris + +# Include definitions common to all Unix archs +include $(EPICS_BASE)/config/CONFIG.Host.UnixCommon + +# +# required by sun's C++ compiler +# +AR = ar +_AR = $(AR) $(ARFLAGS) +G++_AR = $(_AR) +CCC_AR = $(CCC) -xar -o +ARCMD = $($(CPLUSPLUS)_AR) $@ +RANLIB = + +#========================== +# These are overrides of ANSI and CPLUSPLUS values in CONFIG_SITE +ANSI=GCC +CPLUSPLUS=G++ +#========================== + +SOLARIS_VERSION = $(subst 5.,,$(shell uname -r)) +ARCH_DEP_CPPFLAGS += -DSOLARIS=$(SOLARIS_VERSION) +POSIX_CPPFLAGS_YES += -D__EXTENSIONS__ + +# socket and nsl needed by libca.a +ARCH_DEP_LDLIBS += -lsocket -lnsl +ARCH_DEP_LDLIBS += -lposix4 -lpthread +ARCH_DEP_LDLIBS_8 = -lCrun +ARCH_DEP_LDLIBS += $(ARCH_DEP_LDLIBS_$(SOLARIS_VERSION)) + +#Allows R3.13 built extensions to load R3.14 shared libs +SYS_DLL_LIBS_solaris += posix4 pthread $(ARCH_DEP_LDLIBS_$(SOLARIS_VERSION)) + diff --git a/config/CONFIG.Vx.ppc603 b/config/CONFIG.Vx.ppc603 index 5d8b59d28..ddc2d9a97 100644 --- a/config/CONFIG.Vx.ppc603 +++ b/config/CONFIG.Vx.ppc603 @@ -22,4 +22,4 @@ ARCH_CLASS = ppc ARCH_DEP_CPPFLAGS = -DCPU=PPC603 -DTRUE=1 ARCH_DEP_CFLAGS = -mcpu=603 --no-builtin -mstrict-align -# ARCH_DEP_CFLAGS== -fsigned-char #May need for calcPerform.c +# ARCH_DEP_CFLAGS+= -fsigned-char #May need for calcPerform.c diff --git a/config/CONFIG.Vx.ppc603_long b/config/CONFIG.Vx.ppc603_long new file mode 100644 index 000000000..bfc82da60 --- /dev/null +++ b/config/CONFIG.Vx.ppc603_long @@ -0,0 +1,16 @@ +# $Id$ +# +# This file is maintained by the EPICS community. + +# Vx GNU cross compiler suffix +CMPLR_SUFFIX = ppc + +# For Vx directories of form: +# $(VX_DIR)/$(HOST_ARCH).$(ARCH_CLASS)/bin +ARCH_CLASS = ppc + +# Architecture specific build flags +ARCH_DEP_CPPFLAGS = -DCPU=PPC603 -DTRUE=1 +ARCH_DEP_CFLAGS = -mcpu=603 --no-builtin -mstrict-align -mlongcall + +# ARCH_DEP_CFLAGS+= -fsigned-char #May need for calcPerform.c diff --git a/config/CONFIG.Vx.ppc604 b/config/CONFIG.Vx.ppc604 index dd003975f..653a5df7d 100644 --- a/config/CONFIG.Vx.ppc604 +++ b/config/CONFIG.Vx.ppc604 @@ -22,5 +22,5 @@ ARCH_CLASS = ppc ARCH_DEP_CPPFLAGS = -DCPU=PPC604 -D_GNU_TOOL -DTRUE=1 ARCH_DEP_CFLAGS = -mcpu=604 --no-builtin -mstrict-align -# ARCH_DEP_CFLAGS== -fsigned-char #May need for calcPerform.c +# ARCH_DEP_CFLAGS+= -fsigned-char #May need for calcPerform.c diff --git a/config/CONFIG.Vx.ppc604_long b/config/CONFIG.Vx.ppc604_long new file mode 100644 index 000000000..86a1cf561 --- /dev/null +++ b/config/CONFIG.Vx.ppc604_long @@ -0,0 +1,17 @@ +# $Id$ +# +# This file is maintained by the EPICS community. + +# Vx GNU cross compiler suffix +CMPLR_SUFFIX = ppc + +# For Vx directories of form: +# $(VX_DIR)/$(HOST_ARCH).$(ARCH_CLASS)/bin +ARCH_CLASS = ppc + +# Architecture specific build flags +ARCH_DEP_CPPFLAGS = -DCPU=PPC604 -D_GNU_TOOL -DTRUE=1 +ARCH_DEP_CFLAGS = -mcpu=604 --no-builtin -mstrict-align -mlongcall + +# ARCH_DEP_CFLAGS+= -fsigned-char #May need for calcPerform.c + diff --git a/config/CONFIG.Vx.sbs_pc6 b/config/CONFIG.Vx.sbs_pc6 new file mode 100644 index 000000000..0a9d7ddfe --- /dev/null +++ b/config/CONFIG.Vx.sbs_pc6 @@ -0,0 +1,16 @@ +# Created by Korobov for SBS PC6 +# CONFIG.Vx.sbs_pc6 +# +# This file is maintained by the EPICS community. + +# Vx GNU cross compiler suffix +CMPLR_SUFFIX = 386 + +# For Vx directories of form: +# $(VX_DIR)/$(HOST_ARCH).$(ARCH_CLASS)/bin +ARCH_CLASS = sbs_pc6 + +ARCH_DEP_CPPFLAGS = -DCPU=PENTIUM -DCPU_VARIANT=PENTIUM -D_X86_ +ARCH_DEP_CFLAGS = -mpentium +ARCH_DEP_CXXFLAGS += -x 'c++' +ARCH_DEP_CFLAGS += -fno-builtin -fno-defer-pop diff --git a/config/CONFIG_HOST_ARCH.solarisGnu b/config/CONFIG_HOST_ARCH.solarisGnu new file mode 100644 index 000000000..df0a6d1f8 --- /dev/null +++ b/config/CONFIG_HOST_ARCH.solarisGnu @@ -0,0 +1,9 @@ +# CONFIG_HOST_ARCH.solaris +# +# Override values in CONFIG.Vx + +# Include definitions common to all Unix archs +include $(EPICS_BASE)/config/CONFIG_HOST_ARCH.UnixCommon + +WIND_HOST_TYPE = sun4-solaris2 + diff --git a/config/CONFIG_SITE b/config/CONFIG_SITE index 66c42f2d7..e18ce63c0 100644 --- a/config/CONFIG_SITE +++ b/config/CONFIG_SITE @@ -21,6 +21,7 @@ # hp700 # sgi # solaris +# solarisGnu (GNU compiler) # solaris-x86 # sun4 # @@ -46,10 +47,14 @@ endif # mv2700 # niCpu030 # pc486 +# ppc603 # ppc604 +# ppc603_long (over 32MB) +# ppc604_long (over 32MB) +# sbs_pc6 # vxipc # -CROSS_COMPILER_TARGET_ARCHS=vxWorks-68040 +CROSS_COMPILER_TARGET_ARCHS= # If only a subset of the host architectures perform diff --git a/config/RULES.Host b/config/RULES.Host index 230ad2cb2..a7de590c6 100644 --- a/config/RULES.Host +++ b/config/RULES.Host @@ -364,7 +364,7 @@ buildInstall :: build $(TARGETS) \ clean:: @echo "Cleaning" @$(RM) *.i *$(OBJ) *.a $(PROD) $(TESTPROD) $(LIBNAME) $(SHRLIBNAME) $(INC) \ - *$(RES) $(TARGETS) $(DBDINSTALL) $(MENUS) $(RECTYPES) $(BPTS) + *$(RES) $(TARGETS) *.dbd $(MENUS) $(RECTYPES) $(BPTS) ifdef DBDEXPAND @$(RM) $(DBDNAME) endif @@ -389,6 +389,14 @@ PRODNAME_SRCS += $(PRODNAME_SRCS_DEFAULT) endif endif +ifneq ($(strip $(PRODNAME_OBJS_$(ARCH_CLASS))),) +PRODNAME_OBJS += $(subst -nil-,,$(PRODNAME_OBJS_$(ARCH_CLASS))) +else +ifdef PRODNAME_OBJS_DEFAULT +PRODNAME_OBJS += $(PRODNAME_OBJS_DEFAULT) +endif +endif + ifneq ($(strip $(PRODNAME_RCS_$(ARCH_CLASS))),) PRODNAME_RCS += $(subst -nil-,,$(PRODNAME_RCS_$(ARCH_CLASS))) else @@ -407,8 +415,8 @@ else PRODNAME_LINKER = $(LINK.c) endif -PRODNAME_OBJS=$(addsuffix $(OBJ), $(basename $(PRODNAME_SRCS))) -PRODNAME_RESS=$(addsuffix $(RES), $(basename $(PRODNAME_RCS))) +PRODNAME_OBJS+=$(addsuffix $(OBJ), $(basename $(PRODNAME_SRCS))) +PRODNAME_RESS+=$(addsuffix $(RES), $(basename $(PRODNAME_RCS))) ifdef BORLANDC $(PRODNAME): $(PRODNAME_OBJS) $(PRODNAME_RESS)