Commit b64f7b5c authored by jdelange's avatar jdelange

* Update Makefile to build with the new orchestrator



git-svn-id: https://tecsw.estec.esa.int/svn/taste/trunk/po-hi-c@3883 129961e7-ef38-4bb5-a8f7-c9a525a55882
parent 16bafd20
......@@ -235,7 +235,7 @@ compile-node: $(BINARY)
ifeq ($(TARGET), $(filter $(TARGET), leon.rtems leon.rtems_posix))
OBJS = $(USER_OBJS) $(PO_HI_OBJS) $(GENERATED_OBJS) $(EXTERNAL_OBJECTS)
$(BINARY): generate-asn1-deployment target-objects check-rtems compile-po-hi $(USER_OBJS) $(GENERATED_OBJS)
$(make-exe)
$(CC) -o $(BINARY) $(EXTERNAL_OBJECTS) $(PO_HI_OBJS) $(GENERATED_OBJS) $(USER_OBJS) $(LDFLAGS) $(CFLAGS)
endif
ifeq ($(TARGET), leon3-xm3)
......@@ -270,7 +270,7 @@ endif #TARGET=x86qemu
ifeq ($(TARGET), nds.rtems)
OBJS = $(USER_OBJS) $(PO_HI_OBJS) $(GENERATED_OBJS) $(EXTERNAL_OBJECTS)
$(BINARY): generate-asn1-deployment target-objects check-rtems compile-po-hi $(USER_OBJS) $(GENERATED_OBJS)
$(make-exe)
$(CC) -o $(BINARY) $(EXTERNAL_OBJECTS) $(PO_HI_OBJS) $(GENERATED_OBJS) $(USER_OBJS) $(LDFLAGS)
endif
......
......@@ -7,6 +7,10 @@
## This file has been built for RTEMS 4.8.0
include $(RTEMS_MAKEFILE_PATH)/Makefile.inc
include $(RTEMS_CUSTOM)
include $(PROJECT_ROOT)/make/leaf.cfg
define bsp-post-link
$(NM) -g -n $@ > $(basename $@).num
......@@ -16,54 +20,38 @@ endef
MANAGERS = all
CC = sparc-rtems-gcc
CPP = sparc-rtems-g++
CC = $(CC_FOR_TARGET)
CPP = $(CXX_FOR_TARGET)
GPROF = sparc-rtems-gprof
TARGET_SOURCES =
#TARGET_TRANSPORT_SOURCES = $(RUNTIME_PATH)/config/leon-rtems/config.c
TARGET_TRANSPORT_SOURCES =
TARGET_CFLAGS = -DRTEMS_POSIX -DLEON_RTEMS $(GCC_GENERIC_FLAGS)
TARGET_CFLAGS = -DRTEMS_POSIX -DLEON_RTEMS $(GCC_GENERIC_FLAGS) $(CPU_FLAGS) $(AM_FLAGS) $(GCCSPECS)
TARGET_INCLUDE = -I $(RUNTIME_PATH)/config/leon-rtems/
LD = sparc-rtems-ld
TARGET_LDFLAGS = -lrtemsbsp -lc -lm
EXTERNAL_OBJECTS += -L$(RUNTIME_PATH)/libs/leon/ -llua -lm
RTEMS410=$(shell grep VERSION $$RTEMS_MAKEFILE_PATH_LEON/lib/include/rtems/score/cpuopts.h|grep 4.10)
RTEMS411=$(shell grep VERSION $$RTEMS_MAKEFILE_PATH_LEON/lib/include/rtems/score/cpuopts.h|grep 4.11)
RTEMS48=$(shell grep VERSION $$RTEMS_MAKEFILE_PATH_LEON/lib/include/rtems/score/cpuopts.h|grep 4.8)
RTEMS410=$(shell grep VERSION $$RTEMS_MAKEFILE_PATH/lib/include/rtems/score/cpuopts.h|grep 4.10)
RTEMS411=$(shell grep VERSION $$RTEMS_MAKEFILE_PATH/lib/include/rtems/score/cpuopts.h|grep 4.11)
RTEMS48=$(shell grep VERSION $$RTEMS_MAKEFILE_PATH/lib/include/rtems/score/cpuopts.h|grep 4.8)
ifneq ($(RTEMS48),)
TARGET_CFLAGS += -DRTEMS_VERSION=48
TARGET_CFLAGS += -DRTEMS48
endif
ifneq ($(RTEMS411),)
TARGET_CFLAGS += -DRTEMS_VERSION=411
TARGET_CFLAGS += -DRTEMS411
endif
ifneq ($(RTEMS410),)
TARGET_CFLAGS += -DRTEMS_VERSION=410
TARGET_CFLAGS += -DRTEMS410
endif
target-clean:
-include $(RTEMS_MAKEFILE_PATH)/Makefile.inc
-include $(RTEMS_CUSTOM)
-include $(PROJECT_ROOT)/make/leaf.cfg
define bsp-link-c
$(LINK.c) $(CPU_CFLAGS) $(AM_CFLAGS) $(AM_LDFLAGS) \
-o $(BINARY) $(LINK_OBJS) $(LINK_LIBS)
endef
define bsp-link-cxx
$(LINK.cc) $(CPU_CFLAGS) $(AM_CFLAGS) $(AM_LDFLAGS) \
-o $(BINARY) $(LINK_OBJS) $(LINK_LIBS)
endef
ifdef USE_GPROF
TARGET_LDFLAGS+=-Wl,--wrap,Clock_isr -pg
......@@ -81,3 +69,4 @@ emulate-qemu: $(BINARY)
qemu-system-sparc -M at697 -nographic -kernel $(BINARY).exe
target-clean:
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment