Changeset 323 in pacpusframework for trunk/cmake


Ignore:
Timestamp:
Oct 28, 2014, 1:01:45 PM (10 years ago)
Author:
Marek Kurdej
Message:

Add auto-finding WINSDK_LIB.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/cmake/PacpusDependencies.cmake

    r322 r323  
    2323)
    2424if(WIN32)
    25     set(WINSDK_LIB "$ENV{WINSDK_LIB}" CACHE PATH "Directory of Windows Development Kit, should contain glu32.lib.")
    26     find_library(GLU32_LIB_PATH glu32 "${WINSDK_LIB}" "$ENV{WINSDK_LIB}")
    27     get_filename_component(WINSDK_LIB "${GLU32_LIB_PATH}" DIRECTORY)
     25    find_library(GLU32_LIB_PATH
     26        NAMES glu32
     27        HINTS
     28            "${WINSDK_LIB}"
     29            "$ENV{WINSDK_LIB}"
     30            # 8.1
     31            "C:/Program Files/Windows Kits/8.1/Lib/winv6.3/um/x86"
     32            "C:/Program Files (x86)/Windows Kits/8.1/Lib/winv6.3/um/x86"
     33            "C:/Program Files/Windows Kits/8.1/Lib/winv6.3/um/x64"
     34            "C:/Program Files (x86)/Windows Kits/8.1/Lib/winv6.3/um/x64"
     35            # 8.0
     36            "C:/Program Files/Windows Kits/8.0/Lib/win8/um/x86"
     37            "C:/Program Files (x86)/Windows Kits/8.0/Lib/win8/um/x86"
     38            "C:/Program Files/Windows Kits/8.0/Lib/win8/um/x64"
     39            "C:/Program Files (x86)/Windows Kits/8.0/Lib/win8/um/x64"
     40    )
     41    get_filename_component(GLU32_LIB_DIR "${GLU32_LIB_PATH}" DIRECTORY)
     42    set(WINSDK_LIB "${GLU32_LIB_DIR}" CACHE PATH "Directory of Windows Development Kit, should contain glu32.lib.")
    2843    if("${WINSDK_LIB}" STREQUAL "")
    2944        message(STATUS "Environment variable 'WINSDK_LIB' should be set to the path containing glu32 library, e.g. 'C:/Program Files (x86)/Windows Kits/8.0/Lib/win8/um/x86'")
Note: See TracChangeset for help on using the changeset viewer.