Skip to content

Commit

Permalink
build: unit_tests_static_truncating restored for quantity_test and …
Browse files Browse the repository at this point in the history
…chrono_test
  • Loading branch information
mpusz committed Oct 30, 2024
1 parent e78a0ac commit 26d2fc4
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions test/static/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,15 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

add_library(unit_tests_static_truncating quantity_test.cpp)
if(NOT ${projectPrefix}API_FREESTANDING)
target_sources(unit_tests_static_truncating PRIVATE chrono_test.cpp)
endif()
target_link_libraries(unit_tests_static_truncating PRIVATE mp-units::mp-units)
target_compile_options(
unit_tests_static_truncating PRIVATE $<IF:$<CXX_COMPILER_ID:MSVC>,/wd4242 /wd4244,-Wno-conversion>
)

add_library(
unit_tests_static
angular_test.cpp
Expand All @@ -41,7 +50,6 @@ add_library(
# magnitude_test.cpp
natural_test.cpp
prime_test.cpp
quantity_test.cpp
quantity_point_test.cpp
quantity_spec_test.cpp
ratio_test.cpp
Expand All @@ -56,8 +64,9 @@ add_library(
)

if(NOT ${projectPrefix}API_FREESTANDING)
target_sources(unit_tests_static PRIVATE chrono_test.cpp fractional_exponent_quantity.cpp math_test.cpp)
target_sources(unit_tests_static PRIVATE fractional_exponent_quantity.cpp math_test.cpp)
endif()

target_compile_options(unit_tests_static PRIVATE $<$<CXX_COMPILER_ID:GNU>:-Wno-subobject-linkage>)
target_link_libraries(unit_tests_static PRIVATE mp-units::mp-units)
target_link_libraries(unit_tests_static PRIVATE unit_tests_static_truncating)

0 comments on commit 26d2fc4

Please sign in to comment.