Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
kernel_linux
提交
60eab877
K
kernel_linux
项目概览
OpenHarmony
/
kernel_linux
上一次同步 4 年多
通知
15
Star
8
Fork
2
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
kernel_linux
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
60eab877
编写于
9月 13, 2010
作者:
M
Michal Marek
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'kbuild/clean' into kbuild/kbuild
上级
c3e2f196
88d7be03
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
24 addition
and
22 deletion
+24
-22
Documentation/kbuild/makefiles.txt
Documentation/kbuild/makefiles.txt
+7
-0
Kbuild
Kbuild
+2
-2
Makefile
Makefile
+13
-20
scripts/Makefile.clean
scripts/Makefile.clean
+2
-0
未找到文件。
Documentation/kbuild/makefiles.txt
浏览文件 @
60eab877
...
@@ -779,6 +779,13 @@ This will delete the directory debian, including all subdirectories.
...
@@ -779,6 +779,13 @@ This will delete the directory debian, including all subdirectories.
Kbuild will assume the directories to be in the same relative path as the
Kbuild will assume the directories to be in the same relative path as the
Makefile if no absolute path is specified (path does not start with '/').
Makefile if no absolute path is specified (path does not start with '/').
To exclude certain files from make clean, use the $(no-clean-files) variable.
This is only a special case used in the top level Kbuild file:
Example:
#Kbuild
no-clean-files := $(bounds-file) $(offsets-file)
Usually kbuild descends down in subdirectories due to "obj-* := dir/",
Usually kbuild descends down in subdirectories due to "obj-* := dir/",
but in the architecture makefiles where the kbuild infrastructure
but in the architecture makefiles where the kbuild infrastructure
is not sufficient this sometimes needs to be explicit.
is not sufficient this sometimes needs to be explicit.
...
...
Kbuild
浏览文件 @
60eab877
...
@@ -94,5 +94,5 @@ PHONY += missing-syscalls
...
@@ -94,5 +94,5 @@ PHONY += missing-syscalls
missing-syscalls: scripts/checksyscalls.sh FORCE
missing-syscalls: scripts/checksyscalls.sh FORCE
$(call cmd,syscalls)
$(call cmd,syscalls)
#
Delete all target
s during make clean
#
Keep these two file
s during make clean
clean-files := $(addprefix $(objtree)/,$(filter-out $(bounds-file) $(offsets-file),$(targets))
)
no-clean-files := $(bounds-file) $(offsets-file
)
Makefile
浏览文件 @
60eab877
...
@@ -1119,21 +1119,13 @@ MRPROPER_FILES += .config .config.old .version .old_version \
...
@@ -1119,21 +1119,13 @@ MRPROPER_FILES += .config .config.old .version .old_version \
#
#
clean
:
rm-dirs := $(CLEAN_DIRS)
clean
:
rm-dirs := $(CLEAN_DIRS)
clean
:
rm-files := $(CLEAN_FILES)
clean
:
rm-files := $(CLEAN_FILES)
clean-dirs
:=
$(
addprefix
_clean_,
$(srctree)
$
(
vmlinux-alldirs
)
Documentation
)
clean-dirs
:=
$(
addprefix
_clean_,
.
$
(
vmlinux-alldirs
)
Documentation
)
PHONY
+=
$
(
clean-dirs
)
clean archclean
PHONY
+=
$
(
clean-dirs
)
clean archclean
$(clean-dirs)
:
$(clean-dirs)
:
$(Q)$(MAKE)
$(clean)
=
$(
patsubst
_clean_%,%,
$@
)
$(Q)$(MAKE)
$(clean)
=
$(
patsubst
_clean_%,%,
$@
)
clean
:
archclean $(clean-dirs)
clean
:
archclean
$(
call
cmd,rmdirs
)
$(
call
cmd,rmfiles
)
@
find
.
$(RCS_FIND_IGNORE)
\
\(
-name
'*.[oas]'
-o
-name
'*.ko'
-o
-name
'.*.cmd'
\
-o
-name
'.*.d'
-o
-name
'.*.tmp'
-o
-name
'*.mod.c'
\
-o
-name
'*.symtypes'
-o
-name
'modules.order'
\
-o
-name
modules.builtin
-o
-name
'.tmp_*.o.*'
\
-o
-name
'*.gcno'
\)
-type
f
-print
| xargs
rm
-f
# mrproper - Delete all generated files, including .config
# mrproper - Delete all generated files, including .config
#
#
...
@@ -1331,16 +1323,7 @@ $(clean-dirs):
...
@@ -1331,16 +1323,7 @@ $(clean-dirs):
$(Q)$(MAKE)
$(clean)
=
$(
patsubst
_clean_%,%,
$@
)
$(Q)$(MAKE)
$(clean)
=
$(
patsubst
_clean_%,%,
$@
)
clean
:
rm-dirs := $(MODVERDIR)
clean
:
rm-dirs := $(MODVERDIR)
clean
:
rm-files := $(KBUILD_EXTMOD)/Module.symvers
\
clean
:
rm-files := $(KBUILD_EXTMOD)/Module.symvers
$(KBUILD_EXTMOD)/modules.order
\
$(KBUILD_EXTMOD)/modules.builtin
clean
:
$(clean-dirs)
$(
call
cmd,rmdirs
)
$(
call
cmd,rmfiles
)
@
find
$(KBUILD_EXTMOD)
$(RCS_FIND_IGNORE)
\
\(
-name
'*.[oas]'
-o
-name
'*.ko'
-o
-name
'.*.cmd'
\
-o
-name
'.*.d'
-o
-name
'.*.tmp'
-o
-name
'*.mod.c'
\
-o
-name
'*.gcno'
\)
-type
f
-print
| xargs
rm
-f
help
:
help
:
@
echo
' Building external modules.'
@
echo
' Building external modules.'
...
@@ -1357,6 +1340,16 @@ prepare: ;
...
@@ -1357,6 +1340,16 @@ prepare: ;
scripts
:
;
scripts
:
;
endif
# KBUILD_EXTMOD
endif
# KBUILD_EXTMOD
clean
:
$(clean-dirs)
$(
call
cmd,rmdirs
)
$(
call
cmd,rmfiles
)
@
find
$(
or
$(KBUILD_EXTMOD)
, .
)
$(RCS_FIND_IGNORE)
\
\(
-name
'*.[oas]'
-o
-name
'*.ko'
-o
-name
'.*.cmd'
\
-o
-name
'.*.d'
-o
-name
'.*.tmp'
-o
-name
'*.mod.c'
\
-o
-name
'*.symtypes'
-o
-name
'modules.order'
\
-o
-name
modules.builtin
-o
-name
'.tmp_*.o.*'
\
-o
-name
'*.gcno'
\)
-type
f
-print
| xargs
rm
-f
# Generate tags for editors
# Generate tags for editors
# ---------------------------------------------------------------------------
# ---------------------------------------------------------------------------
quiet_cmd_tags
=
GEN
$@
quiet_cmd_tags
=
GEN
$@
...
...
scripts/Makefile.clean
浏览文件 @
60eab877
...
@@ -45,6 +45,8 @@ __clean-files := $(extra-y) $(always) \
...
@@ -45,6 +45,8 @@ __clean-files := $(extra-y) $(always) \
$
(
host-progs
)
\
$
(
host-progs
)
\
$
(
hostprogs-y
)
$
(
hostprogs-m
)
$
(
hostprogs-
)
$
(
hostprogs-y
)
$
(
hostprogs-m
)
$
(
hostprogs-
)
__clean-files
:=
$(
filter-out
$
(
no-clean-files
)
,
$
(
__clean-files
))
# as clean-files is given relative to the current directory, this adds
# as clean-files is given relative to the current directory, this adds
# a $(obj) prefix, except for absolute paths
# a $(obj) prefix, except for absolute paths
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录