cleanup
This commit is contained in:
@@ -8,14 +8,14 @@
|
||||
# GMP_LIBRARY_DLL - library DLL to install. Only available on WIN32.
|
||||
# GMP_LIBRARIES_DIR - the directory the library we link with is found in.
|
||||
|
||||
|
||||
if (ANDROID)
|
||||
set( GMP_ROOT ${CMAKE_SOURCE_DIR}/../gmp/${ANDROID_ABI} )
|
||||
set (GMP_FOUND ON)
|
||||
set (GMP_INCLUDE_DIRS ${GMP_ROOT})
|
||||
set (GMP_LIBRARIES ${GMP_ROOT}/libgmp.so)
|
||||
set (GMP_FOUND ON)
|
||||
set (GMP_LIBRARIES_DIR ${GMP_ROOT})
|
||||
else(ANDROID)
|
||||
if(MSVC)
|
||||
elif(MSVC)
|
||||
find_library(GMP_LIBRARIES NAMES mpir mpird
|
||||
PATHS
|
||||
$ENV{GMP_ROOT}
|
||||
@@ -50,12 +50,13 @@ find_file(GMP_LIBRARY_DLL NAMES mpir.dll mpird.dll
|
||||
${GMP_LIBRARIES_DIR}
|
||||
)
|
||||
|
||||
else(MSVC)
|
||||
else()
|
||||
|
||||
#use GMP, notice that there are two cases, everything is the same directory, or everything is in
|
||||
#its proper places
|
||||
|
||||
|
||||
|
||||
find_library(GMP_LIBRARIES
|
||||
NAMES gmp libgmp
|
||||
HINTS
|
||||
@@ -87,17 +88,18 @@ else(MSVC)
|
||||
get_filename_component(GMP_LIBRARIES_DIR "${GMP_LIBRARIES}" PATH CACHE)
|
||||
|
||||
|
||||
endif(MSVC)
|
||||
endif(ANDROID)
|
||||
|
||||
# handle the QUIET and REQUIRED arguments and set GMP_FOUND to TRUE if
|
||||
# all listed variables are true
|
||||
include(FindPackageHandleStandardArgs)
|
||||
if(MSVC)
|
||||
find_package_handle_standard_args(GMP DEFAULT_MSG GMP_LIBRARIES GMP_LIBRARIES_DIR GMP_LIBRARY_DLL GMP_INCLUDE_DIRS)
|
||||
mark_as_advanced(GMP_LIBRARY_DLL)
|
||||
find_package_handle_standard_args(GMP DEFAULT_MSG GMP_LIBRARIES GMP_LIBRARIES_DIR GMP_LIBRARY_DLL GMP_INCLUDE_DIRS)
|
||||
mark_as_advanced(GMP_LIBRARY_DLL)
|
||||
else()
|
||||
find_package_handle_standard_args(GMP DEFAULT_MSG GMP_LIBRARIES GMP_LIBRARIES_DIR GMP_INCLUDE_DIRS)
|
||||
find_package_handle_standard_args(GMP DEFAULT_MSG GMP_LIBRARIES GMP_LIBRARIES_DIR GMP_INCLUDE_DIRS)
|
||||
endif()
|
||||
|
||||
|
||||
mark_as_advanced(GMP_LIBRARIES GMP_LIBRARIES_DIR GMP_INCLUDE_DIRS)
|
||||
|
||||
endif()
|
||||
|
||||
|
Reference in New Issue
Block a user