Skip to content

Commit f0aee16

Browse files
committed
[tracy] update to 0.13
1 parent ae8fa5a commit f0aee16

File tree

15 files changed

+267
-25
lines changed

15 files changed

+267
-25
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
2+
index 740b484..e4397a4 100644
3+
--- a/src/CMakeLists.txt
4+
+++ b/src/CMakeLists.txt
5+
@@ -128,6 +128,14 @@ set_target_properties(${TARGET_NAME} PROPERTIES
6+
7+
if (NFD_INSTALL)
8+
include(GNUInstallDirs)
9+
+ include(CMakePackageConfigHelpers)
10+
+
11+
+ write_basic_package_version_file("${CMAKE_CURRENT_BINARY_DIR}/${TARGET_NAME}-config-version.cmake"
12+
+ VERSION "${PROJECT_VERSION}"
13+
+ COMPATIBILITY SameMajorVersion
14+
+ )
15+
+
16+
+ install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${TARGET_NAME}-config-version.cmake" DESTINATION lib/cmake/${TARGET_NAME})
17+
18+
install(TARGETS ${TARGET_NAME} EXPORT ${TARGET_NAME}-export
19+
LIBRARY DESTINATION ${LIB_INSTALL_DIR} ARCHIVE DESTINATION ${LIB_INSTALL_DIR} PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}

ports/nativefiledialog-extended/portfile.cmake

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ vcpkg_from_github(
44
REF v${VERSION}
55
SHA512 4ec3e174a90354c524d9be2776422740f80b73021df94e1942e60ab4310995245554f83097b9b2dcca04d016a8548d3fc0760f73daf724c5c3d72c15cf776bed
66
HEAD_REF master
7+
PATCHES
8+
fix-version.cmake
79
)
810

911
vcpkg_cmake_configure(

ports/nativefiledialog-extended/vcpkg.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"name": "nativefiledialog-extended",
33
"version": "1.2.1",
4+
"port-version": 1,
45
"description": "Native File Dialog Extended",
56
"homepage": "https://github.com/btzy/nativefiledialog-extended",
67
"license": "Zlib",

ports/tidy-html5/fix-version.cmake

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
diff --git a/CMakeLists.txt b/CMakeLists.txt
2+
index 8efec25..6007610 100644
3+
--- a/CMakeLists.txt
4+
+++ b/CMakeLists.txt
5+
@@ -700,4 +700,13 @@ install(FILES
6+
DESTINATION "${LIB_INSTALL_DIR}/pkgconfig"
7+
)
8+
9+
+
10+
+include(CMakePackageConfigHelpers)
11+
+
12+
+write_basic_package_version_file("${CMAKE_CURRENT_BINARY_DIR}/unofficial-tidy-html5Config-version.cmake"
13+
+ VERSION "${LIBTIDY_VERSION}"
14+
+ COMPATIBILITY SameMajorVersion
15+
+)
16+
+
17+
+install(FILES ${CMAKE_CURRENT_BINARY_DIR}/unofficial-tidy-html5Config-version.cmake DESTINATION ${LIB_INSTALL_DIR}/cmake/unofficial-tidy-html5)
18+
# eof

ports/tidy-html5/portfile.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ vcpkg_from_github(
1010
debug-postfix.patch
1111
fix_unsupport_func_uwp.patch
1212
cmake_find_package_support.patch
13+
fix-version.cmake
1314
)
1415

1516
string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "dynamic" BUILD_SHARED_LIB)

ports/tidy-html5/vcpkg.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "tidy-html5",
33
"version": "5.8.0",
4-
"port-version": 2,
4+
"port-version": 3,
55
"description": "Tidy tidies HTML and XML. It can tidy your documents by itself, and developers can easily integrate its features into even more powerful tools.",
66
"homepage": "https://www.html-tidy.org",
77
"license": null,

ports/tracy/disable-git.patch

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
diff --git a/profiler/CMakeLists.txt b/profiler/CMakeLists.txt
2+
index d01731d3..1d36eee1 100644
3+
--- a/profiler/CMakeLists.txt
4+
+++ b/profiler/CMakeLists.txt
5+
@@ -266,7 +266,7 @@ if(NOT DEFINED GIT_REV)
6+
endif()
7+
8+
find_package(Git)
9+
-if(Git_FOUND)
10+
+if(0)
11+
add_custom_target(git-ref
12+
COMMAND ${CMAKE_COMMAND} -E echo "#pragma once" > GitRef.hpp.tmp
13+
COMMAND ${GIT_EXECUTABLE} -C ${CMAKE_CURRENT_SOURCE_DIR} log -1 "--format=namespace tracy { static inline const char* GitRef = %x22%h%x22; }" ${GIT_REV} >> GitRef.hpp.tmp || echo "namespace tracy { static inline const char* GitRef = \"unknown\"; }" >> GitRef.hpp.tmp
Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
diff --git a/profiler/src/profiler/TracySourceView.cpp b/profiler/src/profiler/TracySourceView.cpp
2+
index c79948b8..7bd717b7 100644
3+
--- a/profiler/src/profiler/TracySourceView.cpp
4+
+++ b/profiler/src/profiler/TracySourceView.cpp
5+
@@ -713,7 +713,7 @@ bool SourceView::Disassemble( uint64_t symAddr, const Worker& worker )
6+
rval = cs_open( CS_ARCH_ARM, CS_MODE_ARM, &handle );
7+
break;
8+
case CpuArchArm64:
9+
- rval = cs_open( CS_ARCH_AARCH64, CS_MODE_ARM, &handle );
10+
+ rval = cs_open( CS_ARCH_ARM64, CS_MODE_ARM, &handle );
11+
break;
12+
default:
13+
assert( false );
14+
@@ -778,9 +778,9 @@ bool SourceView::Disassemble( uint64_t symAddr, const Worker& worker )
15+
}
16+
break;
17+
case CpuArchArm64:
18+
- if( detail.aarch64.op_count == 1 && detail.aarch64.operands[0].type == AARCH64_OP_IMM )
19+
+ if( detail.arm64.op_count == 1 && detail.arm64.operands[0].type == ARM64_OP_IMM )
20+
{
21+
- jumpAddr = (uint64_t)detail.aarch64.operands[0].imm;
22+
+ jumpAddr = (uint64_t)detail.arm64.operands[0].imm;
23+
}
24+
break;
25+
default:
26+
@@ -865,18 +865,18 @@ bool SourceView::Disassemble( uint64_t symAddr, const Worker& worker )
27+
}
28+
break;
29+
case CpuArchArm64:
30+
- for( uint8_t i=0; i<detail.aarch64.op_count; i++ )
31+
+ for( uint8_t i=0; i<detail.arm64.op_count; i++ )
32+
{
33+
uint8_t type = 0;
34+
- switch( detail.aarch64.operands[i].type )
35+
+ switch( detail.arm64.operands[i].type )
36+
{
37+
- case AARCH64_OP_IMM:
38+
+ case ARM64_OP_IMM:
39+
type = 0;
40+
break;
41+
- case AARCH64_OP_REG:
42+
+ case ARM64_OP_REG:
43+
type = 1;
44+
break;
45+
- case AARCH64_OP_MEM:
46+
+ case ARM64_OP_MEM:
47+
type = 2;
48+
break;
49+
default:
50+
diff --git a/server/TracyWorker.cpp b/server/TracyWorker.cpp
51+
index b1dffe1a..cb1e179f 100644
52+
--- a/server/TracyWorker.cpp
53+
+++ b/server/TracyWorker.cpp
54+
@@ -3912,7 +3912,7 @@ void Worker::AddSymbolCode( uint64_t ptr, const char* data, size_t sz )
55+
rval = cs_open( CS_ARCH_ARM, CS_MODE_ARM, &handle );
56+
break;
57+
case CpuArchArm64:
58+
- rval = cs_open( CS_ARCH_AARCH64, CS_MODE_ARM, &handle );
59+
+ rval = cs_open( CS_ARCH_ARM64, CS_MODE_ARM, &handle );
60+
break;
61+
default:
62+
assert( false );
63+
@@ -3952,9 +3952,9 @@ void Worker::AddSymbolCode( uint64_t ptr, const char* data, size_t sz )
64+
}
65+
break;
66+
case CpuArchArm64:
67+
- if( detail.aarch64.op_count == 1 && detail.aarch64.operands[0].type == AARCH64_OP_IMM )
68+
+ if( detail.arm64.op_count == 1 && detail.arm64.operands[0].type == ARM64_OP_IMM )
69+
{
70+
- callAddr = (uint64_t)detail.aarch64.operands[0].imm;
71+
+ callAddr = (uint64_t)detail.arm64.operands[0].imm;
72+
}
73+
break;
74+
default:
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
diff --git a/cmake/server.cmake b/cmake/server.cmake
2+
index a76d1c13..d8c1a26f 100644
3+
--- a/cmake/server.cmake
4+
+++ b/cmake/server.cmake
5+
@@ -29,7 +29,7 @@ list(TRANSFORM TRACY_SERVER_SOURCES PREPEND "${TRACY_SERVER_DIR}/")
6+
7+
add_library(TracyServer STATIC EXCLUDE_FROM_ALL ${TRACY_COMMON_SOURCES} ${TRACY_SERVER_SOURCES})
8+
target_include_directories(TracyServer PUBLIC ${TRACY_COMMON_DIR} ${TRACY_SERVER_DIR})
9+
-target_link_libraries(TracyServer PUBLIC TracyCapstone libzstd PPQSort::PPQSort)
10+
+target_link_libraries(TracyServer PUBLIC TracyCapstone zstd::libzstd PPQSort::PPQSort)
11+
if(NO_STATISTICS)
12+
target_compile_definitions(TracyServer PUBLIC TRACY_NO_STATISTICS)
13+
endif()
14+
diff --git a/cmake/vendor.cmake b/cmake/vendor.cmake
15+
index a54f7c53..62a48b7b 100644
16+
--- a/cmake/vendor.cmake
17+
+++ b/cmake/vendor.cmake
18+
@@ -109,6 +109,7 @@ CPMAddPackage(
19+
NAME zstd
20+
GITHUB_REPOSITORY facebook/zstd
21+
GIT_TAG v1.5.7
22+
+ VERSION 1.5.6
23+
OPTIONS
24+
"ZSTD_BUILD_SHARED OFF"
25+
EXCLUDE_FROM_ALL TRUE
26+
@@ -136,6 +137,7 @@ target_include_directories(TracyGetOpt PUBLIC ${GETOPT_DIR})
27+
CPMAddPackage(
28+
NAME ImGui
29+
GITHUB_REPOSITORY ocornut/imgui
30+
+ FORCE TRUE
31+
GIT_TAG v1.92.1-docking
32+
DOWNLOAD_ONLY TRUE
33+
PATCHES
34+
@@ -151,6 +153,7 @@ set(IMGUI_SOURCES
35+
imgui_tables.cpp
36+
misc/freetype/imgui_freetype.cpp
37+
backends/imgui_impl_opengl3.cpp
38+
+ backends/imgui_impl_glfw.cpp
39+
)
40+
41+
list(TRANSFORM IMGUI_SOURCES PREPEND "${ImGui_SOURCE_DIR}/")
42+
@@ -198,7 +201,8 @@ CPMAddPackage(
43+
# json
44+
45+
CPMAddPackage(
46+
- NAME json
47+
+ NAME nlohmann_json
48+
+ VERSION 3.11.0
49+
GITHUB_REPOSITORY nlohmann/json
50+
GIT_TAG v3.12.0
51+
EXCLUDE_FROM_ALL TRUE
52+
@@ -233,7 +237,7 @@ if(NOT EMSCRIPTEN)
53+
# tidy
54+
55+
CPMAddPackage(
56+
- NAME tidy
57+
+ NAME unofficial-tidy-html5
58+
GITHUB_REPOSITORY htacg/tidy-html5
59+
GIT_TAG 5.8.0
60+
PATCHES
61+
@@ -246,6 +250,7 @@ if(NOT EMSCRIPTEN)
62+
CPMAddPackage(
63+
NAME usearch
64+
GITHUB_REPOSITORY unum-cloud/usearch
65+
+ VERSION 2.17.0
66+
GIT_TAG v2.19.1
67+
EXCLUDE_FROM_ALL TRUE
68+
)
69+
diff --git a/profiler/CMakeLists.txt b/profiler/CMakeLists.txt
70+
index d01731d3..9c07e971 100644
71+
--- a/profiler/CMakeLists.txt
72+
+++ b/profiler/CMakeLists.txt
73+
@@ -242,7 +242,7 @@ target_link_libraries(${PROJECT_NAME} PRIVATE
74+
TracyImGui
75+
Threads::Threads
76+
nlohmann_json::nlohmann_json
77+
- md4c
78+
+ md4c::md4c
79+
)
80+
target_include_directories(${PROJECT_NAME} PRIVATE
81+
${tidy_SOURCE_DIR}/include
82+
@@ -254,8 +254,8 @@ target_include_directories(${PROJECT_NAME} PRIVATE
83+
if(NOT EMSCRIPTEN)
84+
target_link_libraries(${PROJECT_NAME} PRIVATE
85+
TracyLibcurl
86+
- base64
87+
- tidy-static
88+
+ aklomp::base64
89+
+ unofficial::tidy-html5::tidy
90+
TracyPugixml
91+
usearch
92+
)

ports/tracy/portfile.cmake

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,14 @@
1-
vcpkg_download_distfile(PATCH_MISSING_CHRONO_INCLUDE
2-
URLS https://github.com/wolfpld/tracy/commit/50ff279aaddfd91dc3cdcfd5b7aec3978e63da25.diff?full_index=1
3-
SHA512 f9594297ea68612b68bd631497cd312ea01b34280a0f098de0d2b99810149345251a8985a6430337d0b55d2f181ceac10d563b64cfe48f78959f79ec7a6ea3b5
4-
FILENAME wolfpld-tracy-PR982.diff
5-
)
6-
71
vcpkg_from_github(
82
OUT_SOURCE_PATH SOURCE_PATH
93
REPO wolfpld/tracy
104
REF "v${VERSION}"
11-
SHA512 d3d99284e3c3172236c3f02b3bc52df111ef650fb8609e54fb3302ece28e55a06cd16713ed532f1e1aad66678ff09639dfc7e01a1e96880fb923b267a1b1b79b
5+
SHA512 ee1c6596e7313bdccb8e2e9354c1e2ec14e78a6252b4f53861256807a09bac19f9ff0d7ffb95e60f1d16f5cec22cb95989a216f5c637d32cee9a8c4257a567fa
126
HEAD_REF master
137
PATCHES
148
build-tools.patch
15-
"${PATCH_MISSING_CHRONO_INCLUDE}"
9+
disable-git.patch
10+
fix-vendor-versions.patch
11+
downgrade-capstone-5.patch
1612
)
1713

1814
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
@@ -40,16 +36,25 @@ vcpkg_cmake_configure(
4036
OPTIONS
4137
-DDOWNLOAD_CAPSTONE=OFF
4238
-DLEGACY=ON
39+
-DCPM_USE_LOCAL_PACKAGES=ON
40+
-DCPM_LOCAL_PACKAGES_ONLY=ON
41+
-DCPM_DONT_UPDATE_MODULE_PATH=ON
42+
-DFETCHCONTENT_FULLY_DISCONNECTED=ON
43+
-DFETCHCONTENT_TRY_FIND_PACKAGE_MODE=ALWAYS
4344
${FEATURE_OPTIONS}
4445
OPTIONS_RELEASE
4546
${TOOLS_OPTIONS}
4647
MAYBE_UNUSED_VARIABLES
4748
DOWNLOAD_CAPSTONE
4849
LEGACY
50+
CPM_DONT_UPDATE_MODULE_PATH
51+
CPM_LOCAL_PACKAGES_ONLY
52+
CPM_USE_LOCAL_PACKAGES
53+
FETCHCONTENT_TRY_FIND_PACKAGE_MODE
4954
)
5055
vcpkg_cmake_install()
5156
vcpkg_copy_pdbs()
52-
vcpkg_cmake_config_fixup(PACKAGE_NAME Tracy)
57+
vcpkg_cmake_config_fixup(PACKAGE_NAME Tracy CONFIG_PATH "lib/cmake/Tracy")
5358

5459
function(tracy_copy_tool tool_name tool_dir)
5560
vcpkg_copy_tools(

0 commit comments

Comments
 (0)