diff options
| author | schmidt <douglascraigschmidt@users.noreply.github.com> | 2001-04-08 14:26:53 +0000 |
|---|---|---|
| committer | schmidt <douglascraigschmidt@users.noreply.github.com> | 2001-04-08 14:26:53 +0000 |
| commit | 396e002bfa4c614a232bdd438558833d35e86c84 (patch) | |
| tree | 1b0e5d2285741f43200c5b84feb1ffda693d5ac5 /include/makeinclude | |
| parent | 4fc7d800d28dcb8608ec00bebddd6542ca864562 (diff) | |
| download | ATCD-396e002bfa4c614a232bdd438558833d35e86c84.tar.gz | |
ChangeLogTag:Sat Apr 7 16:00:48 2001 Douglas C. Schmidt <schmidt@tango.doc.wustl.edu>
Diffstat (limited to 'include/makeinclude')
| -rw-r--r-- | include/makeinclude/Makefile.rtems | 26 | ||||
| -rw-r--r-- | include/makeinclude/platform_rtems.x_g++.GNU | 91 |
2 files changed, 117 insertions, 0 deletions
diff --git a/include/makeinclude/Makefile.rtems b/include/makeinclude/Makefile.rtems new file mode 100644 index 00000000000..088a4d4b031 --- /dev/null +++ b/include/makeinclude/Makefile.rtems @@ -0,0 +1,26 @@ +# Makefile + +export RTEMS_MAKEFILE_PATH=/opt/rtems/sparc-rtems/erc32/ +include $(RTEMS_MAKEFILE_PATH)/Makefile.inc +include $(RTEMS_CUSTOM) +include $(PROJECT_ROOT)/make/leaf.cfg + +print_cxx: + @echo sparc-rtems-g++ + +print_cc: + @echo sparc-rtems-gcc + +print_cflags: + @echo -B/opt/rtems/sparc-rtems/erc32/lib/ -specs bsp_specs -qrtems -mcpu=cypress + +print_prefix: + @echo /opt/rtems + +print_target: + @echo sparc-rtems + +is_big_endian: + t=`echo "#include <rtems.h>" | \ + sparc-rtems-gcc -B/opt/rtems/sparc-rtems/erc32/lib/ -specs bsp_specs -qrtems -mcpu=cypress -E -dM - | \ + grep CPU_BIG_ENDIAN | cut -d' ' -f3` ; echo $$t diff --git a/include/makeinclude/platform_rtems.x_g++.GNU b/include/makeinclude/platform_rtems.x_g++.GNU new file mode 100644 index 00000000000..3b1b36f07c4 --- /dev/null +++ b/include/makeinclude/platform_rtems.x_g++.GNU @@ -0,0 +1,91 @@ +# $Id$ +# +# RTEMS 4.5.0 and later with GNU g++. + +#### Notes: +#### 1) This file requires that the WIND_BASE and WIND_HOST_TYPE environment +#### variables be set. If the target CPU is not a PPC604, then your CPU +#### environment variable must be set. If perl is not on your path, +#### you'll also need to set your PERL_PATH environment variable to +#### the full path to perl. + +CROSS-COMPILE = 1 + +ifndef debug + debug = 1 +endif # ! debug +ifndef optimize + optimize = 1 +endif # ! optimize +ifndef rtti + rtti = +endif # ! rtti + +shared_libs = +static_libs = 1 + +ifeq (,$(RTEMS_MAKEFILE_PATH)) + default: + @ERROR: you must set your RTEMS_MAKEFILE_PATH environment variable +endif # RTEMS_MAKEFILE_PATH + +ifeq (,$(PERL_PATH)) + PERL_PATH = perl +endif # ! PERL_PATH + + +#### BEGIN target CPU-specific settings + +# look them up +CFLAGS = $(shell make -f $(ACE_ROOT)/include/makeinclude/Makefile.rtems print_cflags) +#CCFLAGS = $(shell make -f $(ACE_ROOT)/include/makeinclude/Makefile.rtems print_cflags) -fno-implicit-templates +CCFLAGS = -fno-implicit-templates + +#### END target CPU-specific settings + +CXX := $(shell make -f $(ACE_ROOT)/include/makeinclude/Makefile.rtems print_cxx) + +ifndef ACE_CC +ACE_CC := $(shell make -f $(ACE_ROOT)/include/makeinclude/Makefile.rtems print_cc) +endif # ! ACE_CC +ifndef ACE_CC_VERSION + ACE_CC_VERSION := $(shell $(ACE_CC) --version) +endif # ! ACE_CC_VERSION + +ifeq (egcs,$(findstring egcs,$(ACE_CC_VERSION))) + ACE_HAS_GNUG_PRE_2_8 := 0 + CFLAGS += + ifneq (1,$(exceptions)) + #### With exceptions, this is applied in wrapper_macros.GNU. + #### Without, we do it here. + CFLAGS += -Wno-uninitialized + endif # ! exceptions +endif # egcs + +#CFLAGS += -D_REENTRANT -ansi -fno-builtin -fno-defer-pop \ +# -fvolatile $(PIPE_OPT) -W -Wall +#CCFLAGS += $(CFLAGS) +ifeq (,$(rtti)) + #### Don't use RTTI even with egcs, because Tornado 1.0.x libraries + #### don't support it. + CCFLAGS += -fno-rtti -DACE_LACKS_RTTI +endif # rtti +DCFLAGS += -g +DLD = $(LD) +INCLDIRS += +# Hand build tests/rtems_init.o .. something like this +# sparc-rtems-gcc -B/opt/rtems/sparc-rtems/erc32/lib/ -specs bsp_specs \ +# -qrtems -mcpu=cypress -O -g \ +# -I$(ACE_ROOT) -c -o rtems_init.o rtems_init.c + +LD = $(CXX) $(CCFLAGS) $(ACE_ROOT)/tests/rtems_init.o +LDFLAGS += #-Wl,-X -Wl,-r +OCFLAGS += -O +PIC = + +#### ld can't handle INCLDIRS, so override LINK definitions. +LINK.c = override +LINK.c.override = $(LD) $(LDFLAGS) $(LDLIBS) $(LIBS) + +LINK.cc = override +LINK.cc.override = $(LD) |
