diff options
author | Adam Mitz <mitza@ociweb.com> | 2015-06-10 09:03:52 -0500 |
---|---|---|
committer | Adam Mitz <mitza@ociweb.com> | 2015-06-10 09:03:52 -0500 |
commit | 71e98e68b0ef66bc7f31a79630bedad3df01e372 (patch) | |
tree | 91c34c3386e3bdc723f3e3ec61bbd43bd3ac873f | |
parent | a55702deb13d46252c09f57677abe91e47ec6357 (diff) | |
parent | 8de0874bd988aaf3989cc1ac27584b4d88d1ceff (diff) | |
download | ATCD-71e98e68b0ef66bc7f31a79630bedad3df01e372.tar.gz |
Merge pull request #93 from mitza-oci/VxWorks7
VxWorks7 initial support in config files
-rw-r--r-- | ACE/ace/config-vxworks.h | 6 | ||||
-rw-r--r-- | ACE/ace/config-vxworks7.0.h | 19 | ||||
-rw-r--r-- | ACE/ace/os_include/sys/os_types.h | 2 | ||||
-rw-r--r-- | ACE/include/makeinclude/platform_linux.GNU | 9 | ||||
-rw-r--r-- | ACE/include/makeinclude/platform_vxworks.GNU | 4 | ||||
-rw-r--r-- | ACE/include/makeinclude/platform_vxworks7.0.GNU | 119 |
6 files changed, 155 insertions, 4 deletions
diff --git a/ACE/ace/config-vxworks.h b/ACE/ace/config-vxworks.h index 9d0ea65e25c..e9b35930a27 100644 --- a/ACE/ace/config-vxworks.h +++ b/ACE/ace/config-vxworks.h @@ -34,6 +34,8 @@ # elif (_WRS_VXWORKS_MINOR == 9) # define ACE_VXWORKS 0x690 # endif +# elif (_WRS_VXWORKS_MAJOR == 7) +# define ACE_VXWORKS 0x700 # endif # endif #endif /* ! ACE_VXWORKS */ @@ -50,8 +52,10 @@ # include "ace/config-vxworks6.8.h" #elif (ACE_VXWORKS == 0x690) # include "ace/config-vxworks6.9.h" +#elif (ACE_VXWORKS == 0x700) +# include "ace/config-vxworks7.0.h" #else -#error Unknown or unsupported VxWorks version +# error Unknown or unsupported VxWorks version #endif // Adapt to system argument changes added at VxWorks 6.9 and 64-bit. diff --git a/ACE/ace/config-vxworks7.0.h b/ACE/ace/config-vxworks7.0.h new file mode 100644 index 00000000000..11057aaff24 --- /dev/null +++ b/ACE/ace/config-vxworks7.0.h @@ -0,0 +1,19 @@ +/* -*- C++ -*- */ +// The following configuration file is designed to work for VxWorks +// 7.0 platforms using one of these compilers: +// 1) The GNU g++ compiler that is shipped with VxWorks 7.0 +// (other compilers not yet tested) + +#ifndef ACE_CONFIG_VXWORKS_7_0_H +#define ACE_CONFIG_VXWORKS_7_0_H +#include /**/ "ace/pre.h" + +#if !defined (ACE_VXWORKS) +# define ACE_VXWORKS 0x700 +#endif /* ! ACE_VXWORKS */ + +#include "ace/config-vxworks6.9.h" + +#include /**/ "ace/post.h" +#endif /* ACE_CONFIG_VXWORKS_7_0_H */ + diff --git a/ACE/ace/os_include/sys/os_types.h b/ACE/ace/os_include/sys/os_types.h index bff05e48e94..60a425b9252 100644 --- a/ACE/ace/os_include/sys/os_types.h +++ b/ACE/ace/os_include/sys/os_types.h @@ -74,7 +74,7 @@ typedef double ACE_timer_t; typedef offset_t ACE_LOFF_T; #elif defined (WIN32) typedef __int64 ACE_LOFF_T; -#elif (defined (ACE_VXWORKS) && (ACE_VXWORKS <= 0x690)) || \ +#elif (defined (ACE_VXWORKS) && (ACE_VXWORKS <= 0x700)) || \ defined (ACE_LYNXOS_MAJOR) || \ (defined (ACE_OPENVMS) && !defined (_LARGEFILE)) || \ defined (__TANDEM) diff --git a/ACE/include/makeinclude/platform_linux.GNU b/ACE/include/makeinclude/platform_linux.GNU index 26e550317ba..df2f20b6338 100644 --- a/ACE/include/makeinclude/platform_linux.GNU +++ b/ACE/include/makeinclude/platform_linux.GNU @@ -56,7 +56,10 @@ DCFLAGS += -ggdb DCCFLAGS += -ggdb DLD = $(CXX) LD = $(CXX) -LIBS += -ldl + +ifneq ($(dynamic_loader),0) + LIBS += -ldl +endif ifeq ($(threads),1) FLAGS_C_CC += -pthread @@ -68,6 +71,10 @@ ifeq ($(optimize),1) SOFLAGS += -Wl,-O3 endif +ifeq ($(static_stdlibs),1) + LDFLAGS += -static-libgcc -static-libstdc++ +endif + SOFLAGS += -shared SOBUILD = $(COMPILE.cc) $(PIC) -o $(VSHDIR)$*.so $<; \ $(SOLINK.cc) -o $@ $(LDFLAGS) $(VSHDIR)$*.o diff --git a/ACE/include/makeinclude/platform_vxworks.GNU b/ACE/include/makeinclude/platform_vxworks.GNU index 3be39480e02..9e09aa9aa3b 100644 --- a/ACE/include/makeinclude/platform_vxworks.GNU +++ b/ACE/include/makeinclude/platform_vxworks.GNU @@ -30,4 +30,6 @@ endif ifeq (vxworks-6.9, $(findstring vxworks-6.9,$(WIND_PLATFORM))) include $(ACE_ROOT)/include/makeinclude/platform_vxworks6.9.GNU endif - +ifeq (vxworks-7.0, $(findstring vxworks-7.0,$(WIND_PLATFORM))) + include $(ACE_ROOT)/include/makeinclude/platform_vxworks7.0.GNU +endif diff --git a/ACE/include/makeinclude/platform_vxworks7.0.GNU b/ACE/include/makeinclude/platform_vxworks7.0.GNU new file mode 100644 index 00000000000..57bb39430d0 --- /dev/null +++ b/ACE/include/makeinclude/platform_vxworks7.0.GNU @@ -0,0 +1,119 @@ +# -*- Makefile -*- +# VxWorks 7.0 + +# Building ACE for VxWorks 7.0 +# +# Unlike earlier versions, VxWorks 7 requires a VSB before application code +# can be compiled (either kernel mode or RTP). See the VxWorks documentation +# for information on creating a VSB (VxWorks Source Build). +# +# Create the file ace/config.h containing #include "ace/config-vxworks.h" +# Create the file include/makeinclude/platform_macros.GNU containing... +# VSB_DIR = <<absolute path to the VSB directory for the target system>> +# HOST_ROOT = <<location of host tools if using tao_idl, etc.>> +# << add other build settings here (debug, optimize, inline, rtp) >> +# include $(ACE_ROOT)/include/makeinclude/platform_vxworks.GNU +# +# Use the wrenv script for your host system to start a VxWorks development shell +# and build ACE from that shell using the normal procedure (set ACE_ROOT, +# generate makefiles if necessary, etc.). +# +# Not all configurations supported on VxWorks 6.x have been brought forward +# to this file. If you are building a configuration that has not yet been +# attempted on VxWorks 7, this file may need to be changed. The following have +# been tested: +# hosts: linux +# targets: itl_x86 +# toolchains: gnu4.3 +# rtp settings: 1 +# libraries: shared + +VXWORKS = 1 +CROSS-COMPILE = 1 + +debug ?= 1 +optimize ?= 1 +threads ?= 1 +rtp ?= 1 +pthread ?= $(if $(findstring 1,$(rtp)),1,0) +xerces ?= 0 +aio ?= 0 +versioned_so ?= 0 +footprint ?= 0 +rwho = 0 +templates ?= automatic + +ifeq (,$(WIND_BASE)) + default: + @ERROR: you must set your WIND_BASE environment variable +endif # WIND_BASE + +ifeq (,$(WIND_HOST_TYPE)) + default: + @ERROR: you must set your WIND_HOST_TYPE environment variable +endif # WIND_HOST_TYPE + +ifeq ($(WIND_HOST_TYPE),x86-win32) + vxworks_ntbuild ?= 0 + mingw32 ?= 1 + lacks_touch ?= 0 + PWD = $(subst \,/,$(shell pwd)) + ACE_ROOT := $(subst \,/,$(ACE_ROOT)) + TAO_ROOT := $(subst \,/,$(TAO_ROOT)) + CIAO_ROOT := $(subst \,/,$(CIAO_ROOT)) + HOST_ROOT := $(subst \,/,$(HOST_ROOT)) + override RM = rm -f + HOST_EXE_EXT = .exe +endif # x86-win32 + +ifneq (,$(HOST_ROOT)) + TAO_IDLFLAGS += -g $(HOST_ROOT)/bin/ace_gperf + TAO_IDL = $(HOST_ROOT)/bin/tao_idl$(HOST_EXE_EXT) + TAO_IDL3_TO_IDL2 = $(HOST_ROOT)/bin/tao_idl3_to_idl2$(HOST_EXE_EXT) + TAO_IDL_DEP = $(TAO_IDL) + TAO_IDL3_TO_IDL2_DEP = $(TAO_IDL3_TO_IDL2) +else + # Append the HOST_EXE_EXT if it's not already there + TAO_IDL_DEP = $(TAO_IDL:$(HOST_EXE_EXT)=)$(HOST_EXE_EXT) + TAO_IDL3_TO_IDL2_DEP = $(TAO_IDL3_TO_IDL2:$(HOST_EXE_EXT)=)$(HOST_EXE_EXT) +endif + +VXWORKS_VERSION_FLAG ?= -DACE_VXWORKS=0x700 +CPPFLAGS += $(VXWORKS_VERSION_FLAG) + +ifeq ($(pthread),1) + CPPFLAGS += -DACE_HAS_PTHREADS +endif + +ace_vx_mk_dir = $(if $(findstring 1,$(rtp)),$(WIND_USR_MK),$(WIND_KRNL_MK)) +include $(ace_vx_mk_dir)/defs.library.mk + +CCFLAGS += $(C++FLAGS) +PIC += $(OPTION_SHARED_CODE) + +OCFLAGS += $(filter -O%,$(CFLAGS)) +OCCFLAGS += $(filter -O%,$(CCFLAGS)) +ifneq ($(OCFLAGS),) + CFLAGS := $(filter-out $(OCFLAGS),$(CFLAGS)) +endif +ifneq ($(OCCFLAGS),) + CCFLAGS := $(filter-out $(OCCFLAGS),$(CCFLAGS)) +endif + +DCFLAGS += -g +DCCFLAGS += -g + +LD = $(CPLUS) +DLD = $(CPLUS) + +EXEEXT = $(if $(findstring 1,$(rtp)),.vxe,.out) + +SO_NAME = $(SHLIB) +SOFLAGS += $(C++_COMPILER) $(OPTION_SHARED_CODE) $(LD_SHARED_LIB) \ + $(LD_OPTION_SONAME) + +LDFLAGS := $(filter-out -X -N,$(LDFLAGS)) +LDFLAGS += -L$(VSB_DIR)/usr/lib/common$(if $(filter library,$(PRJ_TYPE)),/PIC) +LIBS += -lstdc++ + +LDFLAGS += $(if $(filter 1,$(shared_libs)),$(if $(filter 1,$(static_libs_only)),,$(LD_OPTION_DYNAMIC))) |