OpenCores
URL https://opencores.org/ocsvn/fwrisc/fwrisc/trunk

Subversion Repositories fwrisc

[/] [fwrisc/] [trunk/] [ve/] [fwrisc/] [sim/] [scripts/] [embedded.mk] - Blame information for rev 2

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 mballance
 
2
GCC_ARCH:=riscv32-unknown-elf
3
 
4
MK_INCLUDES += $(PACKAGES_DIR)/simscripts/mkfiles/common_tool_gcc.mk
5
MK_INCLUDES += $(FWRISC)/ve/fwrisc/tests/fwrisc_tests.mk
6
 
7
include $(MK_INCLUDES)
8
 
9
 
10
CFLAGS += -march=rv32i -mabi=ilp32
11
ASFLAGS += -march=rv32i -mabi=ilp32
12
 
13
RULES := 1
14
 
15
%.elf : %.o
16
        $(Q)$(CC) -o $@ $^ \
17
                -static -mcmodel=medany -fvisibility=hidden -nostdlib -nostartfiles \
18
                -T$(FWRISC_TESTS_DIR)/riscv-compliance/riscv-test-env/p/link.ld
19
 
20
zephyr/%/zephyr/zephyr.elf : $(ZEPHYR_BASE)/samples/%/CMakeLists.txt $(wildcard $(ZEPHYR_BASE)/samples/%/src/%.c)
21
        $(Q)rm -rf zephyr/$*
22
        $(Q)mkdir -p zephyr/$*
23
        $(Q)cd zephyr/$* ; cmake -DBOARD=fwrisc_sim -DCMAKE_C_FLAGS="-DSIMULATION_MODE" $(ZEPHYR_BASE)/samples/$*
24
        $(Q)cd zephyr/$* ; $(MAKE)
25
 
26
zephyr_tests/%/zephyr/zephyr.elf : $(FWRISC_TESTS_DIR)/%/CMakeLists.txt $(wildcard $(FWRISC_TESTS_DIR)/%/src/%.c)
27
        $(Q)rm -rf zephyr_tests/$*
28
        $(Q)mkdir -p zephyr_tests/$*
29
        $(Q)cd zephyr_tests/$* ; cmake -DBOARD=fwrisc_sim $(FWRISC_TESTS_DIR)/$*
30
        $(Q)cd zephyr_tests/$* ; $(MAKE)
31
 
32
include $(MK_INCLUDES)

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.