diff options
author | Hanjoung Lee <hanjoung.lee@samsung.com> | 2020-06-25 10:02:35 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-25 10:02:35 +0900 |
commit | 8876d6e356efda86c8ef8261b3f11f6f952f3950 (patch) | |
tree | 34512802a410de8d65c1c1a882e90032e610b094 | |
parent | 806f974fb0f6bca42137d2b22780272d59098bd6 (diff) | |
download | nnfw-8876d6e356efda86c8ef8261b3f11f6f952f3950.tar.gz nnfw-8876d6e356efda86c8ef8261b3f11f6f952f3950.tar.bz2 nnfw-8876d6e356efda86c8ef8261b3f11f6f952f3950.zip |
[tools] CMake: Unify linking boost (#2585)
Use variable `${Boost_PROGRAM_OPTIONS_LIBRARY}` rather than plain
strings. This may resolve both cases(if-else branch).
ONE-DCO-1.0-Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
-rw-r--r-- | tests/tools/nnpackage_run/CMakeLists.txt | 12 | ||||
-rw-r--r-- | tests/tools/tflite_run/CMakeLists.txt | 12 |
2 files changed, 2 insertions, 22 deletions
diff --git a/tests/tools/nnpackage_run/CMakeLists.txt b/tests/tools/nnpackage_run/CMakeLists.txt index 4fb0bdb1c..e30ee9dec 100644 --- a/tests/tools/nnpackage_run/CMakeLists.txt +++ b/tests/tools/nnpackage_run/CMakeLists.txt @@ -37,17 +37,7 @@ endif() target_link_libraries(nnpackage_run onert_core onert tflite_loader) target_link_libraries(nnpackage_run tensorflow-lite ${LIB_PTHREAD} dl nnfw_lib_tflite jsoncpp) target_link_libraries(nnpackage_run nnfw-dev) -if(BUILD_BOOST) - # We have to use Boost::program_options, instead of boost_program_optinos - # Boost::program_options provides the full path for our own built boost. - target_link_libraries(nnpackage_run Boost::program_options) -else() - # We cannot use `Boost::program_options` on aarch64 - # because it uses boost 1.65.1, which requires cmake >= 3.9.3 - # to identify Boost::program_options imported target correctly, - # However, it uses cmake 3.5. (old version). - target_link_libraries(nnpackage_run boost_program_options) -endif() +target_link_libraries(nnpackage_run ${Boost_PROGRAM_OPTIONS_LIBRARY}) target_link_libraries(nnpackage_run nnfw_lib_benchmark) if(Ruy_FOUND AND PROFILE_RUY) target_link_libraries(nnpackage_run ruy_instrumentation) diff --git a/tests/tools/tflite_run/CMakeLists.txt b/tests/tools/tflite_run/CMakeLists.txt index 1fcb7aec7..45101264f 100644 --- a/tests/tools/tflite_run/CMakeLists.txt +++ b/tests/tools/tflite_run/CMakeLists.txt @@ -14,17 +14,7 @@ target_include_directories(tflite_run PRIVATE src) target_include_directories(tflite_run PRIVATE ${Boost_INCLUDE_DIRS}) target_link_libraries(tflite_run tensorflow-lite ${LIB_PTHREAD} dl nnfw_lib_tflite) -if(BUILD_BOOST) - # We have to use Boost::program_options, instead of boost_program_optinos - # Boost::program_options provides the full path for our own built boost. - target_link_libraries(tflite_run Boost::program_options) -else() - # We cannot use `Boost::program_options` on aarch64 - # because it uses boost 1.65.1, which requires cmake >= 3.9.3 - # to identify Boost::program_options imported target correctly, - # However, it uses cmake 3.5. (old version). - target_link_libraries(tflite_run boost_program_options) -endif() +target_link_libraries(tflite_run ${Boost_PROGRAM_OPTIONS_LIBRARY}) target_link_libraries(tflite_run nnfw_lib_benchmark) |