]> www.infradead.org Git - users/sagi/libnvme.git/commit
test: define separate library for MI unit tests
authorJeremy Kerr <jk@codeconstruct.com.au>
Thu, 23 Jun 2022 11:35:25 +0000 (19:35 +0800)
committerJeremy Kerr <jk@codeconstruct.com.au>
Thu, 23 Jun 2022 11:39:30 +0000 (19:39 +0800)
commit46e882953d2fb86e77d944f8692ab5d3881a29e6
tree3599fd177333b2bbe1bb388a234e0dda83197141
parent8556da59d3ec923702da52d31eabccd7ed1809d6
test: define separate library for MI unit tests

We previously exposed a couple of internal functions for libnvme-mi.so
in ce4a044720. However, Daniel Wagner has suggest instead using a
separate shared library with all symbols visible, just for the unit
test.

This change reverts the symbol visibility changes for the installed
libnvme-mi.so, and defines a separate, non-installed library for the MI
unit tests. This is the same as libnvme-mi.so, but has no linker script
or versioning information.

This means we're not exposing the init_ep and crc32 functions in the
actual .so, but can still allow unit tests to access non-public symbols.
The coverage reports can handle the separate library just fine, as the
coverage data is correlated on the underlying source files.

Signed-off-by: Jeremy Kerr <jk@codeconstruct.com.au>
src/libnvme-mi.map
src/meson.build
test/meson.build