mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-27 22:01:37 +08:00
[libdisasm][breakpad] Initial commit of breakpad. Improvements to libdisasm.
This commit is contained in:
parent
12f19c7a30
commit
0f607865f3
49
ports/breakpad/CMakeLists.txt
Normal file
49
ports/breakpad/CMakeLists.txt
Normal file
@ -0,0 +1,49 @@
|
||||
cmake_minimum_required(VERSION 3.8)
|
||||
project(breakpad CXX)
|
||||
|
||||
add_definitions(
|
||||
-DNOMINMAX
|
||||
-DUNICODE
|
||||
-DWIN32_LEAN_AND_MEAN
|
||||
-D_CRT_SECURE_NO_WARNINGS
|
||||
-D_CRT_SECURE_NO_DEPRECATE
|
||||
-D_CRT_NONSTDC_NO_DEPRECATE
|
||||
)
|
||||
|
||||
set(CMAKE_DEBUG_POSTFIX d)
|
||||
set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON)
|
||||
|
||||
string(COMPARE EQUAL "${CMAKE_BUILD_TYPE}" "Release" DEFAULT_INSTALL_HEADERS)
|
||||
option(INSTALL_HEADERS "Install header files" ${DEFAULT_INSTALL_HEADERS})
|
||||
|
||||
file(GLOB_RECURSE SOURCES src/processor/*.cc)
|
||||
list(FILTER SOURCES EXCLUDE REGEX
|
||||
"_unittest|synth_minidump|/tests|/testdata|/linux|/mac|/android|/solaris|microdump_stackwalk|minidump_dump|minidump_stackwalk")
|
||||
|
||||
find_library(LIBDISASM_LIB NAMES libdisasmd libdisasm)
|
||||
|
||||
add_library(libbreakpad ${SOURCES})
|
||||
target_link_libraries(libbreakpad PRIVATE ${LIBDISASM_LIB})
|
||||
|
||||
target_include_directories(libbreakpad
|
||||
PUBLIC
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src>
|
||||
$<INSTALL_INTERFACE:include>
|
||||
)
|
||||
|
||||
install(TARGETS libbreakpad EXPORT unofficial-breakpad-targets
|
||||
RUNTIME DESTINATION bin
|
||||
LIBRARY DESTINATION lib
|
||||
ARCHIVE DESTINATION lib
|
||||
)
|
||||
|
||||
if(INSTALL_HEADERS)
|
||||
install(DIRECTORY src/google_breakpad DESTINATION include)
|
||||
endif()
|
||||
|
||||
install(
|
||||
EXPORT unofficial-breakpad-targets
|
||||
FILE unofficial-breakpad-config.cmake
|
||||
NAMESPACE unofficial::breakpad::
|
||||
DESTINATION share/unofficial-breakpad
|
||||
)
|
4
ports/breakpad/CONTROL
Normal file
4
ports/breakpad/CONTROL
Normal file
@ -0,0 +1,4 @@
|
||||
Source: breakpad
|
||||
Version: 2018-2-19
|
||||
Build-Depends: libdisasm
|
||||
Description: a set of client and server components which implement a crash-reporting system.
|
24
ports/breakpad/portfile.cmake
Normal file
24
ports/breakpad/portfile.cmake
Normal file
@ -0,0 +1,24 @@
|
||||
include(vcpkg_common_functions)
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO google/breakpad
|
||||
REF 6bb6c9b26afd9844b9e35fcaa39fb24893e7abb5
|
||||
SHA512 a6a786c2cabb1fd2749d79215c7a3024ae6d1a894166060b22869cd3ee3010edb3e0613c0aeea254580554f402d919ed630ee088c53a1f218e01a7280ad29fec
|
||||
HEAD_REF master
|
||||
)
|
||||
|
||||
file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PREFER_NINJA
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
|
||||
vcpkg_fixup_cmake_targets(CONFIG_PATH share/unofficial-breakpad TARGET_PATH share/unofficial-breakpad)
|
||||
|
||||
vcpkg_copy_pdbs()
|
||||
|
||||
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/breakpad RENAME copyright)
|
@ -1,7 +1,10 @@
|
||||
cmake_minimum_required(VERSION 3.9)
|
||||
project(libdisasm)
|
||||
set(
|
||||
SRCS
|
||||
project(libdisasm C)
|
||||
|
||||
set(CMAKE_DEBUG_POSTFIX d)
|
||||
set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON)
|
||||
|
||||
set(SRCS
|
||||
ia32_implicit.c
|
||||
ia32_implicit.h
|
||||
ia32_insn.c
|
||||
@ -32,7 +35,7 @@ set(
|
||||
|
||||
include_directories(libdisasm)
|
||||
|
||||
add_library(libdisasm ${SRCS})
|
||||
add_library(libdisasm ${SRCS})
|
||||
|
||||
install(
|
||||
TARGETS libdisasm
|
||||
|
@ -1,3 +1,3 @@
|
||||
Source: libdisasm
|
||||
Version: 0.23
|
||||
Version: 0.23-1
|
||||
Description: x86 Disassembler Library.
|
||||
|
@ -25,6 +25,7 @@ file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PREFER_NINJA
|
||||
OPTIONS_DEBUG -DDISABLE_INSTALL_HEADERS=ON
|
||||
)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user