Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add new entry in Release_Notes.
[simgrid.git] / tools / cmake / Modules / FindPAPI.cmake
index afb95bb..28b2b35 100644 (file)
@@ -4,7 +4,7 @@
 #
 #     find_package(PAPI)
 #
-# Variables used by this module, they can change the default behaviour and need
+# Variables used by this module, they can change the default behavior and need
 # to be set before calling find_package:
 #
 #  PAPI_PREFIX         Set this variable to the root installation of
@@ -17,7 +17,7 @@
 #  PAPI_LIBRARY          The PAPI library
 #  PAPI_INCLUDE_DIRS       The location of PAPI headers
 
-set(HAVE_PAPI 0)
+set(HAVE_PAPI OFF)
 set(PAPI_HINT ${papi_path} CACHE PATH "Path to search for PAPI headers and library")
 
 find_path(PAPI_PREFIX
@@ -29,10 +29,10 @@ find_path(PAPI_PREFIX
 message(STATUS "Looking for libpapi")
 find_library(PAPI_LIBRARY
     NAMES libpapi papi
-    PATH_SUFFIXES lib64 lib 
+    PATH_SUFFIXES lib64 lib
     # HINTS gets searched before PATHS
-    HINTS 
-    ${PAPI_PREFIX}/lib 
+    HINTS
+    ${PAPI_PREFIX}/lib
 )
 if(PAPI_LIBRARY)
   message(STATUS "Looking for libpapi - found at ${PAPI_LIBRARY}")
@@ -44,7 +44,7 @@ message(STATUS "Looking for papi.h")
 find_path(PAPI_INCLUDE_DIRS
     NAMES papi.h
     # HINTS gets searched before PATHS
-    HINTS ${PAPI_PREFIX}/include 
+    HINTS ${PAPI_PREFIX}/include
 )
 if(PAPI_INCLUDE_DIRS)
   message(STATUS "Looking for papi.h - found at ${PAPI_INCLUDE_DIRS}")
@@ -55,7 +55,7 @@ endif()
 
 if (PAPI_LIBRARY)
   if(PAPI_INCLUDE_DIRS)
-    set(HAVE_PAPI 1)
+    set(HAVE_PAPI ON)
     mark_as_advanced(HAVE_PAPI)
   endif()
 endif()