forked from microsoft/vcpkg
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[perfetto] initial port of 43.1 (microsoft#37959)
- Loading branch information
Showing
5 changed files
with
100 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# Unofficial perfetto CMakeLists.txt from https://github.com/google/perfetto/blob/v43.1/meson.build | ||
cmake_minimum_required(VERSION 3.23) | ||
project(perfetto LANGUAGES CXX) | ||
|
||
add_library(perfetto) | ||
target_compile_features(perfetto PRIVATE cxx_std_17) | ||
target_sources(perfetto | ||
PRIVATE "sdk/perfetto.cc" | ||
PUBLIC FILE_SET HEADERS BASE_DIRS "sdk" FILES "sdk/perfetto.h" | ||
) | ||
|
||
set(THREADS_PREFER_PTHREAD_FLAG TRUE) | ||
find_package(Threads REQUIRED) | ||
target_link_libraries(perfetto PRIVATE Threads::Threads) | ||
|
||
if(ANDROID) | ||
target_link_libraries(perfetto PRIVATE log) | ||
endif(ANDROID) | ||
|
||
if(WIN32) | ||
target_compile_options(perfetto PRIVATE "/bigobj") | ||
target_compile_definitions(perfetto PRIVATE WIN32_LEAN_AND_MEAN NOMINMAX) | ||
target_link_libraries(perfetto PRIVATE ws2_32) | ||
endif(WIN32) | ||
|
||
if(MSVC) | ||
target_compile_options(perfetto PRIVATE "/permissive-") | ||
endif(MSVC) | ||
|
||
install(TARGETS perfetto | ||
EXPORT unofficial-perfetto-config | ||
FILE_SET HEADERS DESTINATION "include" | ||
) | ||
|
||
install(EXPORT unofficial-perfetto-config | ||
NAMESPACE unofficial::perfetto:: | ||
DESTINATION "share/unofficial-perfetto" | ||
) | ||
|
||
install(FILES "protos/perfetto/trace/perfetto_trace.proto" DESTINATION "share/unofficial-perfetto") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
if (VCPKG_TARGET_IS_WINDOWS) | ||
vcpkg_check_linkage(ONLY_STATIC_LIBRARY) | ||
endif() | ||
|
||
vcpkg_from_github( | ||
OUT_SOURCE_PATH SOURCE_PATH | ||
REPO google/perfetto | ||
REF "v${VERSION}" | ||
SHA512 9ad6f314e6e56558f7062290afef840d81689776bf3a31708a61fef9ea8d80ac00892b5316856adc784b17e71c67a8429500602b301958ccba24fc4a3b6ac6f8 | ||
HEAD_REF main | ||
) | ||
|
||
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}") | ||
|
||
vcpkg_cmake_configure( | ||
SOURCE_PATH "${SOURCE_PATH}" | ||
) | ||
|
||
vcpkg_cmake_install() | ||
|
||
vcpkg_cmake_config_fixup(PACKAGE_NAME unofficial-${PORT}) | ||
|
||
file(REMOVE_RECURSE | ||
"${CURRENT_PACKAGES_DIR}/debug/include" | ||
"${CURRENT_PACKAGES_DIR}/debug/share" | ||
) | ||
|
||
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
"name": "perfetto", | ||
"version": "43.1", | ||
"description": "System profiling, app tracing and trace analysis", | ||
"homepage": "https://perfetto.dev", | ||
"license": "Apache-2.0", | ||
"supports": "!uwp & !x86", | ||
"dependencies": [ | ||
"pthreads", | ||
{ | ||
"name": "vcpkg-cmake", | ||
"host": true | ||
}, | ||
{ | ||
"name": "vcpkg-cmake-config", | ||
"host": true | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"versions": [ | ||
{ | ||
"git-tree": "db7cf7be562a134411d6aadaeef44df6e9758e6f", | ||
"version": "43.1", | ||
"port-version": 0 | ||
} | ||
] | ||
} |