Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
M
mock-turtle
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
hdl-core-lib
mock-turtle
Commits
a01fb394
Commit
a01fb394
authored
Feb 06, 2019
by
Federico Vaga
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sw:fw: simplify validation mantory variables
Signed-off-by:
Federico Vaga
<
federico.vaga@cern.ch
>
parent
4e976471
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
11 deletions
+13
-11
Makefile
software/firmware/Makefile
+13
-11
No files found.
software/firmware/Makefile
View file @
a01fb394
-include
Makefile.specific
-include
$(CURDIR)/.config
# Validation
ifndef
OUTPUT
$(error
Missing
variable
OUTPUT)
endif
ifndef
OBJS
$(error
Missing
variable
OBJS)
endif
# and don't touch the rest unless you know what you're doing.
INSTALL_PREFIX
?=
.
PATH_COMMON_RT
?=
.
...
...
@@ -78,7 +87,7 @@ OBJDIR_BUILD += $(BUILDDIR)
MOCKTURTLE_LDSCRIPT
?=
$(TRTL)
/software/firmware/urv/mockturtle.ld
.PHONY
:
all clean cleanall
check-def
.PHONY
:
all clean cleanall
all
:
$(OUTPUT).bin
...
...
@@ -93,16 +102,9 @@ $(TRTL_SW)/include/hw/mockturtle_cpu_csr.h: $(TRTL_HDL)/cpu/mt_cpu_csr.wb
$(TRTL_SW)/include/hw/mockturtle_cpu_lr.h
:
$(TRTL_HDL)/cpu/mt_cpu_lr.wb
# target to let wbgen2 to generate headers
$(addprefix $(TRTL_SW)/include/hw/,$(WBGEN_HEADERS))
:
| check-def
$(addprefix $(TRTL_SW)/include/hw/,$(WBGEN_HEADERS))
:
make
-C
$(TRTL_SW)
headers
# check needed env variables
check-def
:
ifndef
OUTPUT
@echo
"OUTPUT variable is mandatory"
@exit
1
endif
# create dirs for object files
$(OBJDIR_BUILD)
:
mkdir
-p
$@
...
...
@@ -112,10 +114,10 @@ $(OBJDIR_BUILD):
$(OBJS_BUILD)
:
| $(AUTOCONF)
$(OBJS_BUILD)
:
| $(OBJDIR_BUILD)
$(OUTPUT).elf
:
$(addprefix $(TRTL_SW)/include/hw/
,
$(WBGEN_HEADERS)) $(MOCKTURTLE_LDSCRIPT) $(OBJS_BUILD)
| check-def
$(OUTPUT).elf
:
$(addprefix $(TRTL_SW)/include/hw/
,
$(WBGEN_HEADERS)) $(MOCKTURTLE_LDSCRIPT) $(OBJS_BUILD)
${
CC
}
$(CFLAGS)
$(LDFLAGS)
-o
$(OUTPUT)
.elf
-nostartfiles
$(OBJS_BUILD)
-T
$(MOCKTURTLE_LDSCRIPT)
$(OUTPUT).bin
:
$(OUTPUT).elf
| check-def
$(OUTPUT).bin
:
$(OUTPUT).elf
${
OBJCOPY
}
--remove-section
.smem
-O
binary
$(OUTPUT)
.elf
$(OUTPUT)
.bin
$(SIZE)
$(OUTPUT)
.elf
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment