2017-11-07 15:59:02 +08:00
vcpkg_from_github (
O U T _ S O U R C E _ P A T H S O U R C E _ P A T H
R E P O I n t e l R e a l S e n s e / l i b r e a l s e n s e
2020-11-13 05:04:16 +08:00
R E F d 8 f 5 d 4 2 1 2 d f 8 5 5 2 2 a 1 4 b 4 a 7 b 8 3 b f 4 d 5 4 2 1 9 b 0 6 f a #v2.39.0
S H A 5 1 2 1 a 9 0 2 a b 3 3 3 f e a 7 e b a c a d 6 d 4 4 5 5 9 4 d 4 f 5 a 4 0 d 5 9 1 4 d a f c 6 a a 2 5 8 a 0 6 7 6 4 8 1 c 1 c e a 6 5 b 9 7 8 0 f 0 6 9 5 e 1 4 e 0 2 d c b f 0 5 b 6 0 9 6 d f 8 2 5 3 3 a d b d f 7 7 f a 1 0 b a a b b 3 f 1 6 7 c e c c c 3 0 7
2020-01-11 07:39:20 +08:00
H E A D _ R E F m a s t e r
2019-06-18 07:04:18 +08:00
P A T C H E S
2019-09-24 01:43:25 +08:00
f i x _ o p e n n i 2 . p a t c h
f i x - d e p e n d e n c y - g l f w 3 . p a t c h
2017-11-07 15:59:02 +08:00
)
2020-03-28 10:13:40 +08:00
file ( COPY ${ SOURCE_PATH } /src/win7/drivers/IntelRealSense_D400_series_win7.inf DESTINATION ${ SOURCE_PATH } )
2018-04-18 01:01:22 +08:00
string ( COMPARE EQUAL "${VCPKG_CRT_LINKAGE}" "static" BUILD_CRT_LINKAGE )
2020-04-17 04:29:32 +08:00
vcpkg_check_features ( OUT_FEATURE_OPTIONS FEATURE_OPTIONS
t m 2 B U I L D _ W I T H _ T M 2
)
2019-06-18 07:04:18 +08:00
set ( BUILD_TOOLS OFF )
2018-04-18 01:01:22 +08:00
if ( "tools" IN_LIST FEATURES )
2019-06-18 07:04:18 +08:00
set ( BUILD_TOOLS ON )
endif ( )
set ( BUILD_OPENNI2_BINDINGS OFF )
if ( ( "openni2" IN_LIST FEATURES ) AND ( VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic" ) )
set ( BUILD_OPENNI2_BINDINGS ON )
2018-04-18 01:01:22 +08:00
endif ( )
2017-11-07 15:59:02 +08:00
vcpkg_configure_cmake (
S O U R C E _ P A T H $ { S O U R C E _ P A T H }
2019-06-18 05:38:05 +08:00
P R E F E R _ N I N J A
2020-04-17 04:29:32 +08:00
O P T I O N S $ { F E A T U R E _ O P T I O N S }
2017-12-24 22:46:16 +08:00
- D E N F O R C E _ M E T A D A T A = O N
2018-03-08 03:01:49 +08:00
- D B U I L D _ W I T H _ O P E N M P = O F F
2019-06-18 05:38:05 +08:00
- D B U I L D _ U N I T _ T E S T S = O F F
2018-03-08 03:01:49 +08:00
- D B U I L D _ W I T H _ S T A T I C _ C R T = $ { B U I L D _ C R T _ L I N K A G E }
2019-06-18 07:04:18 +08:00
- D B U I L D _ O P E N N I 2 _ B I N D I N G S = $ { B U I L D _ O P E N N I 2 _ B I N D I N G S }
- D O P E N N I 2 _ D I R = $ { C U R R E N T _ I N S T A L L E D _ D I R } / i n c l u d e / o p e n n i 2
2019-06-18 05:38:05 +08:00
O P T I O N S _ R E L E A S E
2019-06-18 07:04:18 +08:00
- D B U I L D _ E X A M P L E S = $ { B U I L D _ T O O L S }
- D B U I L D _ G R A P H I C A L _ E X A M P L E S = $ { B U I L D _ T O O L S }
2017-11-07 15:59:02 +08:00
O P T I O N S _ D E B U G
2018-04-24 22:07:37 +08:00
- D B U I L D _ E X A M P L E S = O F F
- D B U I L D _ G R A P H I C A L _ E X A M P L E S = O F F
2017-11-07 15:59:02 +08:00
)
vcpkg_install_cmake ( )
2019-06-18 05:38:05 +08:00
2017-11-07 15:59:02 +08:00
vcpkg_fixup_cmake_targets ( CONFIG_PATH lib/cmake/realsense2 )
2019-06-18 05:38:05 +08:00
2018-04-18 01:01:22 +08:00
vcpkg_copy_pdbs ( )
2017-11-07 15:59:02 +08:00
file ( REMOVE_RECURSE ${ CURRENT_PACKAGES_DIR } /debug/include )
2018-04-18 01:01:22 +08:00
file ( REMOVE_RECURSE ${ CURRENT_PACKAGES_DIR } /debug/share )
2017-11-07 15:59:02 +08:00
2019-06-18 07:04:18 +08:00
if ( BUILD_TOOLS )
2019-06-18 05:38:05 +08:00
file ( GLOB EXEFILES_RELEASE
$ { C U R R E N T _ P A C K A G E S _ D I R } / b i n / r s - *
$ { C U R R E N T _ P A C K A G E S _ D I R } / b i n / r e a l s e n s e - *
)
2018-10-26 00:32:23 +08:00
if ( EXEFILES_RELEASE )
file ( COPY ${ EXEFILES_RELEASE } DESTINATION ${ CURRENT_PACKAGES_DIR } /tools/realsense2 )
file ( REMOVE ${ EXEFILES_RELEASE } )
endif ( )
2019-06-18 05:38:05 +08:00
2018-04-18 01:01:22 +08:00
vcpkg_copy_tool_dependencies ( ${ CURRENT_PACKAGES_DIR } /tools/realsense2 )
2018-10-26 00:32:23 +08:00
file ( GLOB BINS ${ CURRENT_PACKAGES_DIR } /bin/* )
if ( NOT BINS )
file ( REMOVE_RECURSE ${ CURRENT_PACKAGES_DIR } /bin ${ CURRENT_PACKAGES_DIR } /debug/bin )
endif ( )
2019-09-24 01:43:25 +08:00
# Issue#7109, remove mismatched dlls and libs when build with tools, this workaround should be removed when the post-build checks related feature implemented.
file ( REMOVE ${ CURRENT_PACKAGES_DIR } /lib/realsense2-gl.lib )
file ( REMOVE ${ CURRENT_PACKAGES_DIR } /bin/realsense2-gl.dll )
file ( REMOVE ${ CURRENT_PACKAGES_DIR } /bin/realsense2-gl.pdb )
2018-04-18 01:01:22 +08:00
endif ( )
2017-11-07 15:59:02 +08:00
2019-06-18 07:04:18 +08:00
if ( BUILD_OPENNI2_BINDINGS )
2020-03-17 05:56:05 +08:00
file ( GLOB RS2DRIVER ${ CURRENT_BUILDTREES_DIR } / ${ TARGET_TRIPLET } -rel/_out/rs2driver* )
if ( RS2DRIVER )
file ( COPY ${ RS2DRIVER } DESTINATION ${ CURRENT_PACKAGES_DIR } /tools/openni2/OpenNI2/Drivers )
endif ( )
2019-06-18 07:04:18 +08:00
endif ( )
2019-09-24 01:43:25 +08:00
file ( INSTALL ${ SOURCE_PATH } /LICENSE DESTINATION ${ CURRENT_PACKAGES_DIR } /share/ ${ PORT } RENAME copyright )