<commit_before># -*- tab-width : 4 -*-
#=======================================================================
#   @file
#   @brief  RX71M Makefile
#   @author 平松邦仁 (<EMAIL>)
#	@copyright	Copyright (C) 2020 <NAME> @n
#				Released under the MIT license @n
#				https://github.com/hirakuni45/RX/blob/master/LICENSE
#=======================================================================
TARGET		=	raytracer_sample

DEVICE		=	R5F571ML

BUILD		=	release
# BUILD		=	debug

VPATH		=	../../

ASOURCES	=	common/start.s

CSOURCES	=	common/init.c \
				common/vect.c \
				common/syscalls.c

PSOURCES	=	RAYTRACER_sample/main.cpp \
				graphics/font8x16.cpp \
				graphics/color.cpp \
				common/stdapi.cpp
USER_LIBS	=

LDSCRIPT	=	../../RX71M/$(DEVICE).ld

USER_DEFS	=	SIG_RX71M \
				F_ICLK=240000000 \
				F_PCLKA=120000000 F_PCLKB=60000000 F_PCLKC=60000000 F_PCLKD=60000000 \
				F_FCLK=60000000 F_BCLK=120000000

# Renesas GNU-RX gcc compiler version check
TARGET_ISA_TEXT := $(shell rx-elf-gcc --target-help | grep ISA)

AS_DEFS		=	--defsym NOT_USER=1

ifeq ($(TARGET_ISA_TEXT), )
# gcc-7.5.0 current gcc source build
AS_DEFS		=	-mcpu=rx600
CC_DEFS		=	-mcpu=rx600 -Wa,-mcpu=rxv2
CP_DEFS		=	-mcpu=rx600
else # Renesas GNU-RX gcc
AS_DEFS		=	-misa=v2
CC_DEFS		=	-misa=v2
CP_DEFS		=	-misa=v2
endif

# Include path for each environment
ifeq ($(OS),Windows_NT)
SYSTEM := WIN
LOCAL_PATH  =   /mingw64
else
  UNAME := $(shell uname -s)
  ifeq ($(UNAME),Linux)
    SYSTEM := LINUX
    LOCAL_PATH = /usr/local
  endif
  ifeq ($(UNAME),Darwin)
    SYSTEM := OSX
    OSX_VER := $(shell sw_vers -productVersion | sed 's/^\([0-9]*.[0-9]*\).[0-9]*/\1/')
    LOCAL_PATH = /opt/local
  endif
endif

INC_SYS     =   $(LOCAL_PATH)/include

INC_APP		=	. ../ ../../

AS_OPT		=	--defsym MEMWAIT=1

CP_OPT		=	-Wall -Werror \
				-Wno-unused-variable \
				-Wno-unused-function \
				-fno-exceptions

CC_OPT		=	-Wall -Werror \
				-Wno-unused-variable \
				-fno-exceptions

ifeq ($(BUILD),debug)
    CC_OPT += -g -DDEBUG
    CP_OPT += -g -DDEBUG
	OPTIMIZE = -O0
endif

ifeq ($(BUILD),release)
    CC_OPT += -DNDEBUG
    CP_OPT += -DNDEBUG
	OPTIMIZE = -O3
endif

SYSINCS		=	$(addprefix -I, $(INC_SYS))
APPINCS		=	$(addprefix -I, $(INC_APP))<commit_msg>Update: cleanup<commit_after># -*- tab-width : 4 -*-
#=======================================================================
#   @file
#   @brief  RX71M Makefile
#   @author 平松邦仁 (<EMAIL>)
#	@copyright	Copyright (C) 2020 Kunihito Hiramatsu @n
#				Released under the MIT license @n
#				https://github.com/hirakuni45/RX/blob/master/LICENSE
#=======================================================================
TARGET		=	raytracer_sample

DEVICE		=	R5F571ML

BUILD		=	release
# BUILD		=	debug

VPATH		=	../../

ASOURCES	=	common/start.s

CSOURCES	=	common/init.c \
				common/vect.c \
				common/syscalls.c

PSOURCES	=	RAYTRACER_sample/main.cpp \
				graphics/font8x16.cpp \
				graphics/color.cpp \
				common/stdapi.cpp
USER_LIBS	=

LDSCRIPT	=	../../RX71M/$(DEVICE).ld

USER_DEFS	=	SIG_RX71M \
				F_ICLK=240000000 \
				F_PCLKA=120000000 F_PCLKB=60000000 F_PCLKC=60000000 F_PCLKD=60000000 \
				F_FCLK=60000000 F_BCLK=120000000

# Renesas GNU-RX gcc compiler version check
TARGET_ISA_TEXT := $(shell rx-elf-gcc --target-help | grep ISA)

ifeq ($(TARGET_ISA_TEXT), )
# gcc-7.5.0 current gcc source build
AS_DEFS		=	-mcpu=rx600
CC_DEFS		=	-mcpu=rx600 -Wa,-mcpu=rxv2
CP_DEFS		=	-mcpu=rx600
else # Renesas GNU-RX gcc
AS_DEFS		=	-misa=v2
CC_DEFS		=	-misa=v2
CP_DEFS		=	-misa=v2
endif

# Include path for each environment
ifeq ($(OS),Windows_NT)
SYSTEM := WIN
LOCAL_PATH  =   /mingw64
else
  UNAME := $(shell uname -s)
  ifeq ($(UNAME),Linux)
    SYSTEM := LINUX
    LOCAL_PATH = /usr/local
  endif
  ifeq ($(UNAME),Darwin)
    SYSTEM := OSX
    OSX_VER := $(shell sw_vers -productVersion | sed 's/^\([0-9]*.[0-9]*\).[0-9]*/\1/')
    LOCAL_PATH = /opt/local
  endif
endif

INC_SYS     =   $(LOCAL_PATH)/include

INC_APP		=	. ../ ../../

# RX71M MEMWAIT register access for 'start.s'
AS_OPT		=	--defsym MEMWAIT=1

CP_OPT		=	-Wall -Werror \
				-Wno-unused-variable \
				-Wno-unused-function \
				-fno-exceptions

CC_OPT		=	-Wall -Werror \
				-Wno-unused-variable \
				-fno-exceptions

ifeq ($(BUILD),debug)
    CC_OPT += -g -DDEBUG
    CP_OPT += -g -DDEBUG
	OPTIMIZE = -O0
endif

ifeq ($(BUILD),release)
    CC_OPT += -DNDEBUG
    CP_OPT += -DNDEBUG
	OPTIMIZE = -O3
endif

SYSINCS		=	$(addprefix -I, $(INC_SYS))
APPINCS		=	$(addprefix -I, $(INC_APP))
{'fraction_non_alphanumeric': 0.20477891916033944, 'fraction_numerical': 0.048459133541759715, 'mean_word_length': 3.0904109589041098, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 14, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1531824', 'n_tokens_mistral': 2176, 'n_tokens_neox': 1850, 'n_words': 358}