Former test is extremely hard to follow, target names are inconsistent with directory names, test case mixes up 2 separate testing scenarios, names are meaningless. In order to fix this provides comments what each command is doing and why, renamed targets into descriptive and longer names, made names consistent with contents so that it is easier to follow test logic without looking up source code.pull/3146/head
parent
8c3a1afde0
commit
d040ce4165
13 changed files with 23 additions and 17 deletions
@ -1 +0,0 @@ |
||||
stlib = static_library('allofme', '../libfile.c') |
@ -1,2 +1 @@ |
||||
exe = executable('prog', '../prog.c', |
||||
link_with : dylib) |
||||
exe = executable('prog', '../prog.c', link_with : sh_func2_linked_func1) |
||||
|
@ -1 +1 @@ |
||||
exe2 = executable('prog2', '../prog.c', link_with : dylib2) |
||||
exe2 = executable('prog2', '../prog.c', link_with : sh_only_link_whole) |
||||
|
@ -0,0 +1,3 @@ |
||||
# Nothing in func2.c uses func1, so the linker would throw it |
||||
# away and thus linking the exe would fail. |
||||
sh_func2_linked_func1 = shared_library('sh_func2_linked_func1', '../func2.c', link_whole : st_func1) |
@ -0,0 +1 @@ |
||||
sh_only_link_whole = shared_library('sh_only_link_whole', link_whole : [st_func1, st_func2]) |
@ -1,4 +0,0 @@ |
||||
# Nothing in dylib.c uses func1, so the linker would throw it |
||||
# away and thus linking the exe would fail. |
||||
dylib = shared_library('shlib', '../dylib.c', |
||||
link_whole : stlib) |
@ -0,0 +1 @@ |
||||
st_func1 = static_library('st_func1', '../func1.c') |
@ -0,0 +1 @@ |
||||
st_func2 = static_library('st_func2', '../func2.c') |
@ -1 +0,0 @@ |
||||
static = static_library('static', '../dylib.c') |
@ -1 +0,0 @@ |
||||
dylib2 = shared_library('link_whole', link_whole : [stlib, static]) |
Loading…
Reference in new issue