File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -328,10 +328,10 @@ if(CARGO_EXECUTABLE)
328328
329329 # Install the Rust GUI binary
330330 if (WIN32 )
331- install (FILES "${CMAKE_CURRENT_SOURCE_DIR } /target/release/gpubench-gui.exe"
331+ install (PROGRAMS "${CMAKE_CURRENT_SOURCE_DIR } /target/release/gpubench-gui.exe"
332332 DESTINATION bin)
333333 else ()
334- install (FILES "${CMAKE_CURRENT_SOURCE_DIR } /target/release/gpubench-gui"
334+ install (PROGRAMS "${CMAKE_CURRENT_SOURCE_DIR } /target/release/gpubench-gui"
335335 DESTINATION bin)
336336 endif ()
337337else ()
@@ -411,8 +411,9 @@ if(WIN32)
411411 set (CPACK_NSIS_URL_INFO_ABOUT "https://github.com/Soddentrough/GPUBench" )
412412 set (CPACK_NSIS_CONTACT "https://github.com/Soddentrough/GPUBench/issues" )
413413 set (CPACK_NSIS_MENU_LINKS
414- "RunAllBenchmarks.bat " "Run All Benchmarks "
414+ "bin/gpubench-gui.exe " "GPUBench "
415415 "bin/gpubench.exe" "GPUBench (CLI)"
416+ "RunAllBenchmarks.bat" "Run All Benchmarks"
416417 "https://github.com/Soddentrough/GPUBench" "GPUBench Website"
417418 )
418419
Original file line number Diff line number Diff line change @@ -7,7 +7,15 @@ fn main() {
77 println ! ( "cargo:rustc-link-search=native={}/build/Release" , dst. display( ) ) ;
88 println ! ( "cargo:rustc-link-search=native={}/build/Debug" , dst. display( ) ) ;
99 println ! ( "cargo:rustc-link-lib=static=gpubench_lib" ) ;
10- println ! ( "cargo:rustc-link-lib=vulkan" ) ;
10+ let target_os = std:: env:: var ( "CARGO_CFG_TARGET_OS" ) . unwrap_or_default ( ) ;
11+ if target_os == "windows" {
12+ println ! ( "cargo:rustc-link-lib=vulkan-1" ) ;
13+ if let Ok ( sdk) = std:: env:: var ( "VULKAN_SDK" ) {
14+ println ! ( "cargo:rustc-link-search=native={}/Lib" , sdk) ;
15+ }
16+ } else {
17+ println ! ( "cargo:rustc-link-lib=vulkan" ) ;
18+ }
1119
1220 cxx_build:: bridge ( "src/lib.rs" )
1321 . file ( "src/bridge.cpp" ) // We'll create this to bridge complex types if needed
You can’t perform that action at this time.
0 commit comments