Commit 6d3c94e4 authored by Masahiro Yamada's avatar Masahiro Yamada

kbuild: turn '/' into an alias of './'

Commit 06300b21 ("kbuild: support building individual files for
external modules") introduced the '/' target. It works only for
external modules to build all .o files, but skip the modpost stage.

However, 'make /' looks a bit weird to me. 'make ./' is more sensible
if you want to build all objects under the current directory, and it
works as expected.

Let's change '/' into a phony target that is an alias of './', but
I may feel like deprecating it in the future.
Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
parent 648ad9b1
...@@ -140,7 +140,7 @@ executed to make module versioning work. ...@@ -140,7 +140,7 @@ executed to make module versioning work.
make -C $KDIR M=$PWD bar.lst make -C $KDIR M=$PWD bar.lst
make -C $KDIR M=$PWD baz.o make -C $KDIR M=$PWD baz.o
make -C $KDIR M=$PWD foo.ko make -C $KDIR M=$PWD foo.ko
make -C $KDIR M=$PWD / make -C $KDIR M=$PWD ./
=== 3. Creating a Kbuild File for an External Module === 3. Creating a Kbuild File for an External Module
......
...@@ -1715,8 +1715,9 @@ endif ...@@ -1715,8 +1715,9 @@ endif
$(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@)
# Modules # Modules
/: prepare FORCE PHONY += /
$(Q)$(MAKE) KBUILD_MODULES=1 $(build)=$(build-dir) /: ./
# Make sure the latest headers are built for Documentation # Make sure the latest headers are built for Documentation
Documentation/ samples/: headers_install Documentation/ samples/: headers_install
%/: prepare FORCE %/: prepare FORCE
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment