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
f3435ff6
Commit
f3435ff6
authored
Feb 06, 2019
by
Federico Vaga
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sw:fw:bld: better use of TRTL env variable
Signed-off-by:
Federico Vaga
<
federico.vaga@cern.ch
>
parent
a01fb394
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
11 deletions
+12
-11
Makefile
software/firmware/Makefile
+12
-11
No files found.
software/firmware/Makefile
View file @
f3435ff6
...
...
@@ -16,6 +16,7 @@ PATH_COMMON_RT ?= .
PATH_COMMON_H
?=
../include
TRTL
?=
../../
TRTL_SW
?=
$(TRTL)
/software
TRTL_FW
?=
$(TRTL_SW)
/firmware
TRTL_HDL
?=
$(TRTL)
/hdl/rtl
RT_GIT_VERSION
=
0x
$(
shell
git rev-parse
--short
=
8 HEAD
||
echo
"0"
)
# empty if git is not there
...
...
@@ -30,8 +31,8 @@ CFLAGS += -mabi=ilp32 -march=rv32im -ffunction-sections -fdata-sections
LDFLAGS
+=
-lgcc
-lc
-Wl
,--gc-sections
# provide search patch for sources
vpath
%.c
$(TRTL
)/software/firmware
vpath
%.S
$(TRTL
)/software/firmware
vpath
%.c
$(TRTL
_FW)
vpath
%.S
$(TRTL
_FW)
BUILDDIR
:=
build
...
...
@@ -51,10 +52,10 @@ STRIP = $(CROSS_COMPILE_TARGET)strip
CFLAGS
+=
-Wall
-D__TRTL_FIRMWARE__
-DARCH
=
urv
CFLAGS
+=
-I
.
CFLAGS
+=
-I
$(BUILDDIR)
/include
CFLAGS
+=
-I
$(TRTL
)
/software/firmware
CFLAGS
+=
-I
$(TRTL
)
/software/firmware
/lib
CFLAGS
+=
-I
$(TRTL
)
/software/firmware
/framework
CFLAGS
+=
-I
$(TRTL
)
/software
/include
CFLAGS
+=
-I
$(TRTL
_FW)
CFLAGS
+=
-I
$(TRTL
_FW)
/lib
CFLAGS
+=
-I
$(TRTL
_FW)
/framework
CFLAGS
+=
-I
$(TRTL
_SW)
/include
CFLAGS
+=
-DGIT_VERSION
=
$(RT_GIT_VERSION)
# used for firmware by trtl-project-creator
...
...
@@ -85,7 +86,7 @@ OBJS_BUILD = $(addprefix $(BUILDDIR)/, $(OBJS))
OBJDIR_BUILD
=
$
(
addprefix
$(BUILDDIR)
/,
$(OBJDIR)
)
OBJDIR_BUILD
+=
$(BUILDDIR)
MOCKTURTLE_LDSCRIPT
?=
$(TRTL
)
/software/firmware
/urv/mockturtle.ld
MOCKTURTLE_LDSCRIPT
?=
$(TRTL
_FW)
/urv/mockturtle.ld
.PHONY
:
all clean cleanall
...
...
@@ -153,16 +154,16 @@ include $(wildcard $(patsubst %,%/.d/*.d,$(basename $(OBJDIR_BUILD))))
# this one is used to generate autoconf.h file
$(AUTOCONF) silentoldconfig
:
.config | $(BUILDDIR)
export
KCONFIG_CONFIG
=
$(CURDIR)
/.config
;
\
$(MAKE)
quiet
=
quiet_
KBUILD_KCONFIG
=
$(CURDIR)
/Kconfig
projtree
=
$(CURDIR)
/
$(BUILDDIR)
-C
$(TRTL
)
/software/firmware
-f
Makefile.kconfig silentoldconfig
$(MAKE)
quiet
=
quiet_
KBUILD_KCONFIG
=
$(CURDIR)
/Kconfig
projtree
=
$(CURDIR)
/
$(BUILDDIR)
-C
$(TRTL
_FW)
-f
Makefile.kconfig silentoldconfig
scripts_basic config
:
$(MAKE)
quiet
=
quiet_
KBUILD_KCONFIG
=
$(CURDIR)
/Kconfig
projtree
=
$(CURDIR)
-C
$(TRTL
)
/software/firmware
-f
Makefile.kconfig
$@
$(MAKE)
quiet
=
quiet_
KBUILD_KCONFIG
=
$(CURDIR)
/Kconfig
projtree
=
$(CURDIR)
-C
$(TRTL
_FW)
-f
Makefile.kconfig
$@
%config
:
$(MAKE)
quiet
=
quiet_
KBUILD_KCONFIG
=
$(CURDIR)
/Kconfig
projtree
=
$(CURDIR)
-C
$(TRTL
)
/software/firmware
-f
Makefile.kconfig
$@
$(MAKE)
quiet
=
quiet_
KBUILD_KCONFIG
=
$(CURDIR)
/Kconfig
projtree
=
$(CURDIR)
-C
$(TRTL
_FW)
-f
Makefile.kconfig
$@
defconfig
:
$(MAKE)
quiet
=
quiet_
KBUILD_KCONFIG
=
$(CURDIR)
/Kconfig
projtree
=
$(CURDIR)
-C
$(TRTL
)
/software/firmware
-f
Makefile.kconfig mt_defconfig
$(MAKE)
quiet
=
quiet_
KBUILD_KCONFIG
=
$(CURDIR)
/Kconfig
projtree
=
$(CURDIR)
-C
$(TRTL
_FW)
-f
Makefile.kconfig mt_defconfig
.config
:
;
...
...
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