-
Notifications
You must be signed in to change notification settings - Fork 551
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix misused tabs in Makefiles #1018
Conversation
You need add Signed-off-by tag in commit. See CONTRIBUTING.md |
The error do not occur in ordinary build process since the problematic corresponding branch is not triggered. But we can manually trigger it by $ make ARCH=whatever USE_CRYPTO_LIB=0 clean
make[1]: Entering directory '/linux-sgx/sdk'
make -C tlibc/ clean
make[2]: Entering directory '/linux-sgx/sdk/tlibc'
make[2]: Leaving directory '/linux-sgx/sdk/tlibc'
make -C tlibthread/ clean
make[2]: Entering directory '/linux-sgx/sdk/tlibthread'
make[2]: Leaving directory '/linux-sgx/sdk/tlibthread'
make -C compiler-rt/ clean
make[2]: Entering directory '/linux-sgx/sdk/compiler-rt'
make[2]: Leaving directory '/linux-sgx/sdk/compiler-rt'
make -C cpprt clean
make[2]: Entering directory '/linux-sgx/sdk/cpprt'
make[2]: Leaving directory '/linux-sgx/sdk/cpprt'
make -C tlibcxx/ clean
make[2]: Entering directory '/linux-sgx/sdk/tlibcxx'
make[2]: Leaving directory '/linux-sgx/sdk/tlibcxx'
make -C tseal/linux/ clean
make[2]: Entering directory '/linux-sgx/sdk/tseal/linux'
make[2]: Leaving directory '/linux-sgx/sdk/tseal/linux'
make -C selib/linux/ clean
make[2]: Entering directory '/linux-sgx/sdk/selib/linux'
make[2]: Leaving directory '/linux-sgx/sdk/selib/linux'
make -C trts/ clean
make[2]: Entering directory '/linux-sgx/sdk/trts'
make -C linux clean
make[3]: Entering directory '/linux-sgx/sdk/trts/linux'
make[4]: Entering directory '/linux-sgx/external/sgx-emm'
make[4]: Leaving directory '/linux-sgx/external/sgx-emm'
make[3]: Leaving directory '/linux-sgx/sdk/trts/linux'
make[2]: Leaving directory '/linux-sgx/sdk/trts'
make -C tsetjmp/ clean
make[2]: Entering directory '/linux-sgx/sdk/tsetjmp'
make[2]: Leaving directory '/linux-sgx/sdk/tsetjmp'
make -C tsafecrt/ clean
make[2]: Entering directory '/linux-sgx/sdk/tsafecrt'
make[2]: Leaving directory '/linux-sgx/sdk/tsafecrt'
make -C gperftools/ clean
make[2]: Entering directory '/linux-sgx/sdk/gperftools'
make[2]: Leaving directory '/linux-sgx/sdk/gperftools'
make -C tlibcrypto/ clean
make[2]: Entering directory '/linux-sgx/sdk/tlibcrypto'
Makefile:49: *** recipe commences before first target. Stop.
make[2]: Leaving directory '/linux-sgx/sdk/tlibcrypto'
make[1]: *** [Makefile.source:326: clean] Error 2
make[1]: Leaving directory '/linux-sgx/sdk'
make: *** [Makefile:483: clean] Error 2 The root cause for it is that make will treat every line begin with a tab as a recipe. Here is a minimum example showing how the error occurs: # content of Makefile
ifeq (,)
$(info hello) # note that this line begins with a tab
endif
default:
touch defaut $ make
Makefile:2: *** recipe commences before first target. Stop. I can reproduce this error on ubuntu latest, with make 4.3 and commit 05851b2. |
37ce0ae
to
d9b373b
Compare
Rebased and signed off the commit now. |
Signed-off-by: SharzyL <[email protected]>
d9b373b
to
960e84e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
Thanks
Makefile use tabs to identify the lines of recipes. If using tabs in a non-recipe part, it may complain
‘recipe commences before first target. Stop.
(Makefile manual) and quits.