mirror of
https://github.com/dgibson/dtc.git
synced 2025-10-13 16:27:39 -04:00
Allow static building with meson
Added "static-build" option in the meson_options.txt. Setting it to "true" allows static building. Signed-off-by: Tero Tervala <tero.tervala@unikie.com> Message-Id: <20220629163557.932298-1-tero.tervala@unikie.com> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
fd9b8c96c7
commit
7ad60734b1
4 changed files with 28 additions and 5 deletions
|
@ -96,15 +96,20 @@ tests += [
|
|||
]
|
||||
|
||||
dl = cc.find_library('dl', required: false)
|
||||
if dl.found()
|
||||
if dl.found() and not static_build
|
||||
tests += [
|
||||
'asm_tree_dump',
|
||||
'value-labels',
|
||||
]
|
||||
endif
|
||||
|
||||
test_deps = [testutil_dep, util_dep, libfdt_dep]
|
||||
if not static_build
|
||||
test_deps += [dl]
|
||||
endif
|
||||
|
||||
foreach t: tests
|
||||
executable(t, files(t + '.c'), dependencies: [testutil_dep, util_dep, libfdt_dep, dl])
|
||||
executable(t, files(t + '.c'), dependencies: test_deps, link_args: extra_link_args)
|
||||
endforeach
|
||||
|
||||
run_tests = find_program('run_tests.sh')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue