Skip to content

Commit

Permalink
Pay attention to hint directories for Check.
Browse files Browse the repository at this point in the history
Allow specifying a base hint directory, and look there and in include/libs underneath it.
  • Loading branch information
Jim Hague committed Oct 24, 2019
1 parent e8eafdf commit 072bdd9
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions cmake/modules/FindCheck.cmake
Expand Up @@ -33,23 +33,23 @@ This module will set the following variables in your project:

find_path(CHECK_INCLUDE_DIR check.h
HINTS
${PC_CHECK_INCLUDEDIR}
${PC_CHECK_INCLUDE_DIRS}
"${CHECK_DIR}"
"${CHECK_DIR}/include"
)

# Check for PIC and non-PIC libraries. If PIC present, use that
# in preference (as per Debian check.pc).
find_library(CHECK_LIBRARY NAMES check_pic libcheck_pic
HINTS
${PC_CHECK_LIBDIR}
${PC_CHECK_LIBRARY_DIRS}
"${CHECK_DIR}"
"${CHECK_DIR}/lib"
)

if (NOT CHECK_LIBRARY)
find_library(CHECK_LIBRARY NAMES check libcheck
HINTS
${PC_CHECK_LIBDIR}
${PC_CHECK_LIBRARY_DIRS}
"${CHECK_DIR}"
"${CHECK_DIR}/lib"
)
endif ()

Expand Down

0 comments on commit 072bdd9

Please sign in to comment.