Patch rtems-rc-19991105-1.diff.gz from Ralf Corsepius

<corsepiu@faw.uni-ulm.de> which does the following:

    This is the configuration cleanup patch:

    Main changes:
      * TARGET_ARCH removed
      * target.cfg.in moved to c/make/target.cfg.in (Only configured once for
        all BSPs of a target)
      * BARE_XXX variables appended to bsp.cfg.in
      * autogen renamed to bootstrap
      * removed stray variables from make/custom/*.cfg

    To apply:
        cd <source-tree>
        rm c/src/make/target.cfg.in
        cp autogen bootstrap
        mkdir c/make
        cp make/target.cfg.in c/make/target.cfg.in
        rm make/target.cfg.in
        rm autogen
        patch -p1 < rtems-rc-19991105-1.diff
This commit is contained in:
Joel Sherrill
1999-11-16 15:48:11 +00:00
parent fa3346f509
commit d6c8352925
28 changed files with 129 additions and 110 deletions

View File

@@ -8,7 +8,7 @@ ACLOCAL_AMFLAGS = -I $(RTEMS_TOPdir)/aclocal
rtems_makedir=$(prefix)/make
GENERIC_FILES = \
host.cfg target.cfg
host.cfg
MAKE_FILES = README \
directory.cfg leaf.cfg \
@@ -37,8 +37,6 @@ $(srcdir)/main.cfg.in: $(top_srcdir)/@RTEMS_TOPdir@/make/main.cfg
$(srcdir)/host.cfg.in: $(top_srcdir)/@RTEMS_TOPdir@/make/host.cfg.in
cp $< $@
$(srcdir)/target.cfg.in: $(top_srcdir)/@RTEMS_TOPdir@/make/target.cfg.in
cp $< $@
endif
SUBDIRS = compilers custom

View File

@@ -29,3 +29,7 @@ HAS_CPLUSPLUS = @HAS_CPLUSPLUS@
## Does this BSP support RTEMS's networking ?
##
HAS_NETWORKING = @HAS_NETWORKING@
## Only used for the bare bsp
BARE_CPU_MODEL = @BARE_CPU_MODEL@
BARE_CPU_CFLAGS = @BARE_CPU_CFLAGS@

View File

@@ -82,7 +82,7 @@ endif
# Define this to yes if C++ is included in the development environment.
# This requires that at least the GNU C++ compiler and libg++ be installed.
ifeq ($(RTEMS_HAS_CPLUSPLUS),yes)
ifeq ($(HAS_CPLUSPLUS),yes)
CPLUS_LD_LIBS += $(PROJECT_RELEASE)/lib/librtems++$(LIBSUFFIX_VA)
endif
@@ -172,13 +172,15 @@ MKLIB=$(RANLIB)
#
# How to compile stuff into ${ARCH} subdirectory
#
# OBSOLETE: we use make's default rules now
#
# NOTE: we override COMPILE.[c|cc|S]
# because gmake default rules use TARGET_ARCH for different purposes
#
COMPILE.c=$(CC) $(CPPFLAGS) $(CFLAGS) -c
COMPILE.cc=$(CXX) $(CPPFLAGS) $(CXXFLAGS) -c
COMPILE.S=$(CC) $(ASFLAGS) $(CPPFLAGS) -c
#
# COMPILE.c=$(CC) $(CPPFLAGS) $(CFLAGS) -c
# COMPILE.cc=$(CXX) $(CPPFLAGS) $(CXXFLAGS) -c
# COMPILE.S=$(CC) $(ASFLAGS) $(CPPFLAGS) -c
${ARCH}/%.o: %.c
${COMPILE.c} -o $@ $<
@@ -198,13 +200,6 @@ ${ARCH}/%.o: %.C
${ARCH}/%.o: %.S
${COMPILE.S} -DASM -o $@ $<
# OBSOLETE: the rule above should be equivalent.
# strip out C++ style comments.
# ${ARCH}/%.o: %.S
# sed -e 's/\/\/.*$$//' < $< | \
# $(CPP) $(CPPFLAGS) -I. -I$(srcdir) -DASM - >$(ARCH)/$*.i
# $(AS) $(ASFLAGS) -o $@ $(ARCH)/$*.i
# Make foo.rel from foo.o
${ARCH}/%.rel: ${ARCH}/%.o
${LD} $(LDFLAGS_INCOMPLETE) -o $@ $^
@@ -216,10 +211,10 @@ ${ARCH}/%: %.sh
$(CHMOD) +x $@
# Dependency files for use by gmake
# NOTE: we don't put in $(TARGET_ARCH)
# NOTE: we don't put them into $(ARCH)
# so that 'make clean' doesn't blow it away
DEPEND=Depends-$(TARGET_ARCH:o-%=%)
DEPEND=Depends-${ARCH}
CLEAN_DEPEND=$(DEPEND).tmp
CLOBBER_DEPEND=$(DEPEND)

View File

@@ -124,7 +124,6 @@ Makefile
Makefile.inc
main.cfg
host.cfg
target.cfg
bsp.cfg
custom/Makefile
custom/default.cfg

View File

@@ -8,20 +8,14 @@
# $Id$
#
include $(RTEMS_ROOT)/make/target.cfg
include $(RTEMS_ROOT)/../make/target.cfg
include $(RTEMS_ROOT)/make/host.cfg
# Specify here the host and target "architectures"
HOST_ARCH=o-$(RTEMS_HOST)
ifndef TARGET_ARCH
TARGET_ARCH=o-@RTEMS_BSP@
endif
include $(RTEMS_ROOT)/make/main.cfg
include $(RTEMS_ROOT)/make/bsp.cfg
## Target compiler config file, if any
CONFIG.$(TARGET_ARCH).CC = $(RTEMS_ROOT)/make/compilers/gcc-target-default.cfg
CONFIG.CC = $(RTEMS_ROOT)/make/compilers/gcc-target-default.cfg
## GCC specs extension file location
RTEMS_BSP_SPECS = $(PROJECT_ROOT)/@RTEMS_BSP@/lib/bsp_specs

View File

@@ -17,11 +17,11 @@ PROJECT_INCLUDE=$(PROJECT_RELEASE)/lib/include
PROJECT_TOOLS = $(PROJECT_RELEASE)/build-tools
#
# Target architecture; may be changed as per 'make "ARCH=${TARGET_ARCH}-debug"'
# Target architecture; may be changed as per 'make "ARCH=debug"'
# This is where the object files get put.
#
ARCH=${TARGET_ARCH}
ARCH=o-optimize
VARIANT=
@@ -43,12 +43,12 @@ MAKEFILE=Makefile
#
# Target variant names
#
TARGET_VARIANTS = debug profile
TARGET_VARIANTS = optimize debug profile
#
# Generate list of object directories: sun4, sun4-debug, sun4-profile
# Generate list of object directories: o-optimize, o-debug, o-profile
#
VARIANTS=${TARGET_ARCH} ${TARGET_VARIANTS:%=${TARGET_ARCH}-%}
VARIANTS=${TARGET_VARIANTS:%=o-%}
#
# List of "recursion-able" targets for directory Makefiles

View File

@@ -1,73 +0,0 @@
#
# $Id$
#
# Target specific settings.
#
prefix = @prefix@
CFLAGS = @CFLAGS@
CPPFLAGS = @CPPFLAGS@
DEFS = @DEFS@
LDFLAGS =
LIBS = @LIBS@
CC = @CC_FOR_TARGET@
AS = @AS_FOR_TARGET@
AR = @AR_FOR_TARGET@
NM = @NM_FOR_TARGET@
LD = @LD_FOR_TARGET@
SIZE = @SIZE_FOR_TARGET@
STRIP = @STRIP_FOR_TARGET@
OBJCOPY = @OBJCOPY_FOR_TARGET@
RANLIB = @RANLIB_FOR_TARGET@
CXX = @CXX_FOR_TARGET@
export CC
export AS
export LD
export NM
export AR
export SIZE
export OBJCOPY
export CXX
RTEMS_CROSS_TARGET=@rtems_cv_prog_cc_cross@
RTEMS_HOST = @RTEMS_HOST@
RTEMS_HAS_MULTIPROCESSING = @RTEMS_HAS_MULTIPROCESSING@
RTEMS_HAS_POSIX_API = @RTEMS_HAS_POSIX_API@
RTEMS_HAS_ITRON_API = @RTEMS_HAS_ITRON_API@
RTEMS_HAS_NETWORKING = @RTEMS_HAS_NETWORKING@
RTEMS_HAS_RDBG = @RTEMS_HAS_RDBG@
RTEMS_HAS_CPLUSPLUS = @RTEMS_HAS_CPLUSPLUS@
RTEMS_USE_MACROS = @RTEMS_USE_MACROS@
RTEMS_USE_GCC272 = @RTEMS_USE_GCC272@
RTEMS_LIBC_DIR = @RTEMS_LIBC_DIR@
RTEMS_CPU = @RTEMS_CPU@
# the following are only used for the bare bsp
BARE_CPU_MODEL = @BARE_CPU_MODEL@
BARE_CPU_CFLAGS = @BARE_CPU_CFLAGS@
XCFLAGS=$(CFLAGS_FOR_TARGET)
export RTEMS_BSP
export RTEMS_CUSTOM
export PROJECT_ROOT
# List (possibly empty) of required managers
# We require:
# region -- used by lib/libcsupport for malloc()
# ext -- used by libc for libc reentrancy hooks
MANAGERS_REQUIRED=region ext sem
# Create a RTEMS executable based on MANAGERS which was set in
# app's Makefile
MANAGERS_NOT_WANTED=$(filter-out $(MANAGERS) \
$(MANAGERS_REQUIRED), $(MANAGER_LIST))

View File

@@ -50,7 +50,7 @@ PACKHEX = @PACKHEX@
#
DEFINES +=
CPPFLAGS += -I$(LIBCC_INCLUDE)
CPPFLAGS +=
CFLAGS +=
LD_PATHS +=

View File

@@ -52,7 +52,7 @@ CPPFLAGS +=
CFLAGS +=
LD_PATHS +=
LD_LIBS += $(LIBC_LIBM)
LD_LIBS += -lm
LDFLAGS +=
#