Merge pull request #1288 from yipdw/bugfix/use-64-bit-file-access

Use _FILE_OFFSET_BITS=64 when building on Linux 32-bit systems
This commit is contained in:
Gabi Melman 2019-10-28 20:48:56 +02:00 committed by GitHub
commit 685ad74d53
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -49,6 +49,12 @@ function(spdlog_prepare_test test_target spdlog_lib)
spdlog_enable_sanitizer(${test_target}) spdlog_enable_sanitizer(${test_target})
endif() endif()
add_test(NAME ${test_target} COMMAND ${test_target}) add_test(NAME ${test_target} COMMAND ${test_target})
if (CMAKE_SYSTEM_NAME STREQUAL Linux)
if (CMAKE_SIZEOF_VOID_P EQUAL 4)
target_compile_definitions(${test_target} PRIVATE _FILE_OFFSET_BITS=64)
endif()
endif()
endfunction() endfunction()
# The compiled library tests # The compiled library tests