Merge pull request #1349 from UnaNancyOwen/add_kinectsdk1

Add Kinect SDK v1.x port
This commit is contained in:
Robert Schumacher 2017-06-28 14:17:30 -07:00 committed by GitHub
commit ccf245c7d1
2 changed files with 45 additions and 0 deletions

3
ports/kinectsdk1/CONTROL Normal file
View File

@ -0,0 +1,3 @@
Source: kinectsdk1
Version: 1.8-1
Description: Kinect for Windows SDK for Kinect v1 sensor.

View File

@ -0,0 +1,42 @@
include(vcpkg_common_functions)
get_filename_component(KINECTSDK10_DIR "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Kinect;SDKInstallPath]" ABSOLUTE CACHE)
if(NOT EXISTS "${KINECTSDK10_DIR}")
message(FATAL_ERROR "Error: Could not find Kinect for Windows SDK v1.x.")
endif()
file(
INSTALL
"${KINECTSDK10_DIR}/inc/NuiApi.h"
"${KINECTSDK10_DIR}/inc/NuiImageCamera.h"
"${KINECTSDK10_DIR}/inc/NuiSensor.h"
"${KINECTSDK10_DIR}/inc/NuiSkeleton.h"
DESTINATION
${CURRENT_PACKAGES_DIR}/include
)
if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86")
set(ARCHITECTURE x86)
elseif(VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
set(ARCHITECTURE amd64)
else()
message(FATAL_ERROR "This port does not currently support architecture: ${VCPKG_TARGET_ARCHITECTURE}")
endif()
file(
INSTALL
"${KINECTSDK10_DIR}/lib/${ARCHITECTURE}/Kinect10.lib"
DESTINATION
${CURRENT_PACKAGES_DIR}/lib
)
file(
INSTALL
"${KINECTSDK10_DIR}/lib/${ARCHITECTURE}/Kinect10.lib"
DESTINATION
${CURRENT_PACKAGES_DIR}/debug/lib
)
# Handle copyright
file(COPY "${KINECTSDK10_DIR}/SDKEula.rtf" DESTINATION ${CURRENT_PACKAGES_DIR}/share/kinectsdk1)
file(RENAME ${CURRENT_PACKAGES_DIR}/share/kinectsdk1/SDKEula.rtf ${CURRENT_PACKAGES_DIR}/share/kinectsdk1/copyright)