aboutsummaryrefslogtreecommitdiff
path: root/ports/dbghelp
diff options
context:
space:
mode:
authortbdrake <draketb@gmail.com>2020-08-09 16:12:14 -0400
committerGitHub <noreply@github.com>2020-08-09 13:12:14 -0700
commit4b1950f7981e478cc2006e0104c82d6c3c5d6f6c (patch)
tree63855a9cd6fe60a4685b9e4dcad0c16e47b2861f /ports/dbghelp
parent8121b4ec3d6a11353daf7639ed9082a78e617a2e (diff)
downloadvcpkg-4b1950f7981e478cc2006e0104c82d6c3c5d6f6c.tar.gz
vcpkg-4b1950f7981e478cc2006e0104c82d6c3c5d6f6c.zip
[crashrpt] Add new port (#9162)
* Add port files for crashrpt * Fix x64 output paths and fail port install if architecture is not x86 or x64 * Use vcpkg_fail_port_install * Add patch for CMakeLists.txt add install target for CrashRpt and CrashSender * Replace vendored dependencies for minizip, png, and zlib with packages from vcpkg * Fix 002-find-minizip-png-zlib.patch, accidentally included folder move/renaming in previous commit * Add vcpkg_copy_tool_dependencies so that dlls for CrashSender .exe will be copied to tools folder * Add install for crprober.exe tool * Replace libogg and libtheora vendored dependencies using find_library() and find_path() * Replace vendored tinyxml library * Replace vendored wtl library * Replace vendored JPEG library with libjpeg-turbo from vcpkg * Add patch to install demos and test applications to tools directory and add vcpkg port features to enable building the tests and demos * Add port of dbghelp that copies files from Windows 10 SDK. Use this crashrpt to replace vendored dependency of dbghelp. * [dbghelp] Improve portfile.cmake * Update baseline * update CONTROL file * Update ci.baseline.txt to skip dbghelp on Windows platforms * * Combined patch files * Use vendored minizip since it has modifications to support Unicode file paths using wchar_t* which CrashRpt depends on * Add feature "probe" in order to allow excluding the CrashRptProbe library * Use VERSION_GREATER instead of MATCHES to compare WINDOWS_SDK version in dbghelp portfile.cmake. Remove redundant check of WINDOWS_SDK version later in script. Co-authored-by: Travis Drake <tdrake@qsrautomations.com> Co-authored-by: JackBoosY <yuzaiyang@beyondsoft.com>
Diffstat (limited to 'ports/dbghelp')
-rw-r--r--ports/dbghelp/CONTROL4
-rw-r--r--ports/dbghelp/portfile.cmake27
2 files changed, 31 insertions, 0 deletions
diff --git a/ports/dbghelp/CONTROL b/ports/dbghelp/CONTROL
new file mode 100644
index 000000000..e92599d57
--- /dev/null
+++ b/ports/dbghelp/CONTROL
@@ -0,0 +1,4 @@
+Source: dbghelp
+Version: 0.0
+Description: Windows Debug Help Library
+Supports: windows \ No newline at end of file
diff --git a/ports/dbghelp/portfile.cmake b/ports/dbghelp/portfile.cmake
new file mode 100644
index 000000000..832bec6d7
--- /dev/null
+++ b/ports/dbghelp/portfile.cmake
@@ -0,0 +1,27 @@
+vcpkg_fail_port_install(ON_TARGET "OSX" "Linux")
+vcpkg_check_linkage(ONLY_DYNAMIC_LIBRARY)
+
+vcpkg_get_windows_sdk(WINDOWS_SDK)
+
+if (WINDOWS_SDK VERSION_GREATER "10")
+ set(LIBFILEPATH "$ENV{WindowsSdkDir}Debuggers\\lib\\${TRIPLET_SYSTEM_ARCH}\\dbghelp.lib")
+ message("LIBFILEPATH: ${LIBFILEPATH}")
+ set(DLLFILEPATH "$ENV{WindowsSdkDir}Debuggers\\${TRIPLET_SYSTEM_ARCH}\\dbghelp.dll")
+ message("DLLFILEPATH: ${DLLFILEPATH}")
+ set(HEADERPATH "$ENV{WindowsSdkDir}Debuggers\\inc\\dbghelp.h")
+ message("HEADERPATH: ${HEADERPATH}")
+else()
+ message(FATAL_ERROR "Portfile not yet configured for Windows SDK with version: ${WINDOWS_SDK}")
+endif()
+
+if (NOT EXISTS "${LIBFILEPATH}" OR NOT EXISTS "${DLLFILEPATH}" OR NOT EXISTS "${HEADERPATH}")
+ message(FATAL_ERROR "Cannot find debugging tools in Windows SDK ${WINDOWS_SDK}. Please reinstall the Windows SDK and select \"Debugging Tools\".")
+endif()
+
+file(INSTALL ${LIBFILEPATH} DESTINATION ${CURRENT_PACKAGES_DIR}/lib)
+file(INSTALL ${LIBFILEPATH} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib)
+file(INSTALL ${DLLFILEPATH} DESTINATION ${CURRENT_PACKAGES_DIR}/bin)
+file(INSTALL ${DLLFILEPATH} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin)
+file(INSTALL ${HEADERPATH} DESTINATION ${CURRENT_PACKAGES_DIR}/include)
+
+file(WRITE ${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright "See https://developer.microsoft.com/windows/downloads/windows-10-sdk for the Windows 10 SDK license")