roentgen 3969d9
# preferred homebrew's directories.
Campbell Barton 7aaaec
find_path(
Campbell Barton 7aaaec
    SUPERLU_INCLUDE_DIR
Campbell Barton 7aaaec
    NAMES
Campbell Barton 7aaaec
        slu_Cnames.h
Campbell Barton 7aaaec
    HINTS
Campbell Barton 7aaaec
        ${THIRDPARTY_LIBS_HINTS}
Campbell Barton 7aaaec
    PATH_SUFFIXES
Campbell Barton 7aaaec
        superlu43/4.3_1/include/superlu
Campbell Barton 7aaaec
        superlu/SuperLU_4.1/include
Campbell Barton 7aaaec
)
Campbell Barton 7aaaec
Campbell Barton 7aaaec
find_library(
Campbell Barton 7aaaec
    SUPERLU_LIBRARY
Campbell Barton 7aaaec
    NAMES
Campbell Barton 78b2e3
        libsuperlu.so
Campbell Barton 7aaaec
        libsuperlu.a
Campbell Barton 7aaaec
        libsuperlu_4.1.a
Campbell Barton 7aaaec
    HINTS
Campbell Barton 7aaaec
        ${THIRDPARTY_LIBS_HINTS}
Campbell Barton 7aaaec
    PATH_SUFFIXES
Campbell Barton 7aaaec
        superlu43/4.3_1/lib
Campbell Barton 7aaaec
        superlu
Campbell Barton 7aaaec
)
roentgen 3969d9
roentgen 3969d9
message("***** SuperLU Header path:" ${SUPERLU_INCLUDE_DIR})
Campbell Barton bf80fb
message("***** SuperLU Library path:" ${SUPERLU_LIBRARY})
roentgen 3969d9
roentgen 3969d9
set(SUPERLU_NAMES ${SUPERLU_NAMES} SuperLU)
roentgen 3969d9
roentgen 3969d9
include(FindPackageHandleStandardArgs)
Campbell Barton 7aaaec
FIND_PACKAGE_HANDLE_STANDARD_ARGS(SuperLU
Campbell Barton 7aaaec
    DEFAULT_MSG SUPERLU_LIBRARY SUPERLU_INCLUDE_DIR)
roentgen 3969d9
roentgen 3969d9
if(SUPERLU_FOUND)
roentgen 3969d9
    set(SUPERLU_LIBRARIES ${SUPERLU_LIBRARY})
roentgen 3969d9
endif()
roentgen 3969d9
Campbell Barton 7aaaec
mark_as_advanced(
Campbell Barton 7aaaec
    SUPERLU_LIBRARY
Campbell Barton 7aaaec
    SUPERLU_INCLUDE_DIR
Campbell Barton 7aaaec
)