diff options
author | Daniel Kirchner <daniel@ekpyron.org> | 2018-12-17 20:42:48 +0800 |
---|---|---|
committer | Daniel Kirchner <daniel@ekpyron.org> | 2018-12-17 22:15:11 +0800 |
commit | 2f698b6efe1b1bb932b238a5dd912b290978ac72 (patch) | |
tree | e5c669583348c70c91eceb4655701e3cf9809ef5 /cmake/FindGMP.cmake | |
parent | 8d3617b7c522d74bcc36a1fbc1eb7c16bf96ad4d (diff) | |
download | dexon-solidity-2f698b6efe1b1bb932b238a5dd912b290978ac72.tar.gz dexon-solidity-2f698b6efe1b1bb932b238a5dd912b290978ac72.tar.zst dexon-solidity-2f698b6efe1b1bb932b238a5dd912b290978ac72.zip |
Use imported CMake targets.
Diffstat (limited to 'cmake/FindGMP.cmake')
-rw-r--r-- | cmake/FindGMP.cmake | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/cmake/FindGMP.cmake b/cmake/FindGMP.cmake index 8abe354c..c3a02654 100644 --- a/cmake/FindGMP.cmake +++ b/cmake/FindGMP.cmake @@ -1,3 +1,8 @@ -find_library(GMP_LIBRARY NAMES gmp ) +find_library(GMP_LIBRARY NAMES gmp) include(FindPackageHandleStandardArgs) find_package_handle_standard_args(GMP DEFAULT_MSG GMP_LIBRARY) + +if(GMP_FOUND AND NOT TARGET GMP::GMP) + add_library(GMP::GMP UNKNOWN IMPORTED) + set_property(TARGET GMP::GMP PROPERTY IMPORTED_LOCATION ${GMP_LIBRARY}) +endif() |