Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
driveos_test
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xulei
driveos_test
Commits
4891cbae
Commit
4891cbae
authored
Jul 21, 2022
by
xulei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Makefile_new
parent
2af51c1c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
45 additions
and
0 deletions
+45
-0
Makefile
Makefile
+45
-0
No files found.
Makefile
0 → 100644
View file @
4891cbae
obj-m
+=
tms.o
tms-y
=
src/tms.o
-include
path.mk
SRC
:=
$(
shell
pwd
)
#Options
#Enable debug
DEBUG
=
y
ARCH
=
arm64
ifndef
KERNEL_DIR
$(error KERNEL_DIR is not defined, use
:
make KERNEL_DIR=<path to kernel directory> CROSS_COMPILE=<path to crosscompiler>)
endif
ifndef
CROSS_COMPILE
$(error CROSS_COMPILE is not defined, use
:
make KERNEL_DIR=<path to kernel directory> CROSS_COMPILE=<path to crosscompiler>)
endif
# Add your debugging flag (or not) to EXTRA_CFLAGS
ifeq
($(DEBUG),y)
DEBFLAGS
=
-O
-g
-DSBULL_DEBUG
# "-O" is needed to expand inlines
else
# DEBFLAGS = -fverbose-asm -O2
# DEBFLAGS = -Wa -adhln -g -fverbose-asm -marm -O2
DEBFLAGS
=
-O2
endif
EXTRA_CFLAGS
+=
$(DEBFLAGS)
-DKERNEL
-D__KERNEL__
EXTRA_CFLAGS
+=
-I
$(SRC)
/include
default
:
@
echo
"Build default"
$(MAKE)
modules
-C
$(KERNEL_DIR)
M
=
$(SRC)
EXTRA_CFLAGS
=
"
$(EXTRA_CFLAGS)
"
ARCH
=
$(ARCH)
CROSS_COMPILE
=
$(CROSS_COMPILE)
all
:
@
echo
"Build all"
$(MAKE)
-C
$(KERNEL_DIR)
M
=
$(SRC)
EXTRA_CFLAGS
=
"
$(EXTRA_CFLAGS)
"
modules_install
:
$(MAKE)
-C
$(KERNEL_DIR)
M
=
$(SRC)
EXTRA_CFLAGS
=
"
$(EXTRA_CFLAGS)
"
modules_install
clean
:
rm
-rf
src/
*
.o src/
*
.cmd src/.
*
.cmd
*
.o
*
~ core .depend .
*
.cmd
*
.ko
*
.mod.c .tmp_versions Module.symvers modules.order
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