2019-10-11 17:36:57 +02:00
|
|
|
##############################################################################
|
2021-03-08 22:29:12 +01:00
|
|
|
# boards/renesas/rx65n/rx65n-grrose/scripts/Make.defs
|
2019-10-11 17:36:57 +02:00
|
|
|
#
|
2021-08-16 11:13:22 +02:00
|
|
|
# Licensed to the Apache Software Foundation (ASF) under one or more
|
|
|
|
# contributor license agreements. See the NOTICE file distributed with
|
|
|
|
# this work for additional information regarding copyright ownership. The
|
|
|
|
# ASF licenses this file to you under the Apache License, Version 2.0 (the
|
|
|
|
# "License"); you may not use this file except in compliance with the
|
|
|
|
# License. You may obtain a copy of the License at
|
2019-10-11 17:36:57 +02:00
|
|
|
#
|
2021-08-16 11:13:22 +02:00
|
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
2019-10-11 17:36:57 +02:00
|
|
|
#
|
2021-08-16 11:13:22 +02:00
|
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
|
|
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
|
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
|
|
|
# License for the specific language governing permissions and limitations
|
|
|
|
# under the License.
|
2019-10-11 17:36:57 +02:00
|
|
|
#
|
|
|
|
##############################################################################
|
|
|
|
|
2020-05-19 16:25:18 +02:00
|
|
|
include $(TOPDIR)/.config
|
|
|
|
include $(TOPDIR)/tools/Config.mk
|
2019-10-11 17:36:57 +02:00
|
|
|
|
2022-02-14 22:29:40 +01:00
|
|
|
ARCHSCRIPT += $(BOARD_DIR)$(DELIM)scripts$(DELIM)linker_script.ld
|
2019-10-11 17:36:57 +02:00
|
|
|
|
|
|
|
CROSSDEV = rx-elf-
|
|
|
|
CC = $(CROSSDEV)gcc
|
|
|
|
CXX = $(CROSSDEV)g++
|
2020-07-01 12:08:10 +02:00
|
|
|
CPP = $(CROSSDEV)gcc -E -P -x c
|
2019-10-11 17:36:57 +02:00
|
|
|
LD = $(CROSSDEV)ld
|
|
|
|
STRIP = $(CROSSDEV)strip --strip-unneeded
|
|
|
|
AR = $(CROSSDEV)ar rcs
|
|
|
|
AS = $(CROSSDEV)as
|
|
|
|
NM = $(CROSSDEV)nm
|
|
|
|
OBJCOPY = $(CROSSDEV)objcopy
|
|
|
|
OBJDUMP = $(CROSSDEV)objdump
|
|
|
|
|
2020-05-19 11:43:29 +02:00
|
|
|
ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
|
|
|
|
ARCHOPTIMIZATION = -g
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifneq ($(CONFIG_DEBUG_NOOPT),y)
|
2022-01-17 19:26:25 +01:00
|
|
|
ARCHOPTIMIZATION += -Os -fno-strict-aliasing -fomit-frame-pointer
|
2020-05-19 11:43:29 +02:00
|
|
|
endif
|
|
|
|
|
|
|
|
ARCHPICFLAGS = -fpic
|
2022-02-12 23:14:22 +01:00
|
|
|
ARCHCFLAGS = -fno-common -std=c99
|
2020-05-19 11:43:29 +02:00
|
|
|
ARCHCPUFLAGS = -mcpu=rx64m
|
|
|
|
ARCHWARNINGS = -Wall -Wstrict-prototypes -Wshadow -Wundef
|
|
|
|
ARCHWARNINGSXX = -Wall -Wshadow -Wundef
|
|
|
|
|
2020-09-24 12:46:51 +02:00
|
|
|
CFLAGS := $(ARCHCFLAGS) $(ARCHWARNINGS) $(ARCHOPTIMIZATION) \
|
2020-04-10 04:37:54 +02:00
|
|
|
$(ARCHCPUFLAGS) $(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRAFLAGS) -pipe
|
2020-09-24 12:46:51 +02:00
|
|
|
CPPFLAGS := $(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRAFLAGS) $(ARCHWARNINGSXX)
|
|
|
|
AFLAGS := $(CFLAGS) -D__ASSEMBLY__
|
2019-10-11 17:36:57 +02:00
|
|
|
|
|
|
|
LDMODULEFLAGS = -r -e module_initialize
|
2022-02-20 03:34:50 +01:00
|
|
|
LDMODULEFLAGS += -T $(call CONVERT_PATH,$(TOPDIR)/libs/libc/modlib/gnu-elf.ld)
|
2019-10-11 17:36:57 +02:00
|
|
|
|
|
|
|
|
|
|
|
CMODULEFLAGS = $(CFLAGS) -mlong-calls # --target1-abs
|
|
|
|
|
|
|
|
ASMEXT = .asm
|