-
-
Notifications
You must be signed in to change notification settings - Fork 865
Closed
Description
xmake: v2.3.3+202005231421
os: ubuntu 20.04, wsl
gcc: 9.3.0
xmake.lua:
target("test")
set_kind("binary")
add_files("test.cpp")
set_strip("debug")
After calling xmake, there's no executable 'test' in the output directory. If set_strip changed to "all", the target file can be generated.
The output of "xmake -v":
configure
{
arch = x86_64
ccache = true
mode = debug
ndk_stdcxx = true
host = linux
ld = /usr/bin/g++
kind = static
buildir = build
cxx = /usr/bin/gcc
plat = linux
}
[ 75%]: linking.debug test
/usr/bin/g++ -o build/linux/x86_64/debug/test build/.objs/test/linux/x86_64/debug/./test.cpp.o -S -m64 -L/usr/local/lib -L/usr/lib
[100%]: build ok!
I noticed that there's a '-S' option in the command line of g++, accroding to http://gcc.gnu.org/onlinedocs/gcc/Link-Options.html#Link-Options:
-c
-S
-E
If any of these options is used, then the linker is not run, and object file names should not be used as arguments.
Is that option caused this issue?
About the feature of stripping the target file. I need to preserve some symbols instead of stripping all of them, is that possible?
thanks