File: FindSpaceWare.cmake

package info (click to toggle)
solvespace 3.1%2Bds1-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 15,960 kB
  • sloc: cpp: 122,491; ansic: 11,375; javascript: 1,919; sh: 89; xml: 44; makefile: 25
file content (28 lines) | stat: -rw-r--r-- 772 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# Find the libspnav library and header.
#
# Sets the usual variables expected for find_package scripts:
#
# SPACEWARE_INCLUDE_DIR - header location
# SPACEWARE_LIBRARIES - library to link against
# SPACEWARE_FOUND - true if libspnav was found.

if(UNIX)

    find_path(SPACEWARE_INCLUDE_DIR
        spnav.h)

    find_library(SPACEWARE_LIBRARY
        NAMES spnav libspnav)

    # Support the REQUIRED and QUIET arguments, and set SPACEWARE_FOUND if found.
    include(FindPackageHandleStandardArgs)
    find_package_handle_standard_args(SpaceWare DEFAULT_MSG
        SPACEWARE_LIBRARY SPACEWARE_INCLUDE_DIR)

    if(SPACEWARE_FOUND)
        set(SPACEWARE_LIBRARIES ${SPACEWARE_LIBRARY})
    endif()

    mark_as_advanced(SPACEWARE_LIBRARY SPACEWARE_INCLUDE_DIR)

endif()