From 8f095fa0342454181dc10f1b9c176c19b356ee67 Mon Sep 17 00:00:00 2001 From: SunBlack Date: Fri, 16 Jan 2026 13:44:44 +0100 Subject: [PATCH] [lcm] Update to 1.5.2 (#48608) --- ports/lcm/avoid-fake-stdint-h.patch | 24 ------------------ ports/lcm/fix-build-error.patch | 32 ----------------------- ports/lcm/glib.link.patch | 39 ++++++++++++----------------- ports/lcm/portfile.cmake | 12 ++++----- ports/lcm/vcpkg.json | 3 +-- scripts/ci.baseline.txt | 6 ----- scripts/ci.feature.baseline.txt | 2 -- versions/baseline.json | 4 +-- versions/l-/lcm.json | 5 ++++ 9 files changed, 29 insertions(+), 98 deletions(-) delete mode 100644 ports/lcm/avoid-fake-stdint-h.patch delete mode 100644 ports/lcm/fix-build-error.patch diff --git a/ports/lcm/avoid-fake-stdint-h.patch b/ports/lcm/avoid-fake-stdint-h.patch deleted file mode 100644 index 7290c6ae5b..0000000000 --- a/ports/lcm/avoid-fake-stdint-h.patch +++ /dev/null @@ -1,24 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 90833e3..2b7cff8 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -17,7 +17,6 @@ include(lcm-cmake/version.cmake) - set(CMAKE_INCLUDE_CURRENT_DIR ON) - if (WIN32) - add_definitions(-DWIN32 -D_CRT_SECURE_NO_WARNINGS) -- include_directories(${lcm_SOURCE_DIR}/WinSpecific/include) - include_directories(${lcm_SOURCE_DIR}/WinSpecific/getopt) - include_directories(${lcm_SOURCE_DIR}) - add_subdirectory(WinSpecific) -diff --git a/lcm-python/setup.py b/lcm-python/setup.py -index e015d20..2528d9f 100644 ---- a/lcm-python/setup.py -+++ b/lcm-python/setup.py -@@ -47,7 +47,6 @@ if os.name == 'nt': - sys.exit('GLIB_PATH environment variable not set.') - - include_dirs += [ \ -- os.path.join("..", "WinSpecific\include"), - os.path.join("..", "WinSpecific"), - os.path.join(glibPath, "include", "glib-2.0"), - os.path.join(glibPath, "lib", "glib-2.0", "include") ] diff --git a/ports/lcm/fix-build-error.patch b/ports/lcm/fix-build-error.patch deleted file mode 100644 index ffca33d796..0000000000 --- a/ports/lcm/fix-build-error.patch +++ /dev/null @@ -1,32 +0,0 @@ -diff --git a/lcm/windows/WinPorting.cpp b/lcm/windows/WinPorting.cpp -index e22acd6..b9c7e69 100644 ---- a/lcm/windows/WinPorting.cpp -+++ b/lcm/windows/WinPorting.cpp -@@ -1,8 +1,8 @@ - - #define _WIN32_WINNT 0x0501 --#include - #include - #include -+#include - - #include "WinPorting.h" - -diff --git a/lcmgen/emit_go.c b/lcmgen/emit_go.c -index c520044..b5be56a 100644 ---- a/lcmgen/emit_go.c -+++ b/lcmgen/emit_go.c -@@ -6,8 +6,13 @@ - #include - #include - #include -+#ifdef WIN32 -+#include -+#else - #include -+#endif - #ifdef WIN32 -+#define F_OK 0 - #define __STDC_FORMAT_MACROS // Enable integer types - #endif - diff --git a/ports/lcm/glib.link.patch b/ports/lcm/glib.link.patch index 4808fe7317..3769ffe549 100644 --- a/ports/lcm/glib.link.patch +++ b/ports/lcm/glib.link.patch @@ -1,30 +1,23 @@ diff --git a/cmake/FindGLib2.cmake b/cmake/FindGLib2.cmake -index 2f1a8be45..db823b953 100644 +index f94f74e..2823fcf 100644 --- a/cmake/FindGLib2.cmake +++ b/cmake/FindGLib2.cmake -@@ -14,7 +14,7 @@ function(_glib2_find_include VAR HEADER) +@@ -74,15 +74,11 @@ find_package(PkgConfig) - find_path(GLIB2_${VAR}_INCLUDE_DIR ${HEADER} - PATHS ${_paths} -- PATH_SUFFIXES glib-2.0 glib-2.0/include -+ PATH_SUFFIXES glib-2.0 glib-2.0/include lib/glib-2.0/include - ) - mark_as_advanced(GLIB2_${VAR}_INCLUDE_DIR) - endfunction() -@@ -108,6 +108,16 @@ foreach(_glib2_component ${GLib2_FIND_COMPONENTS}) + if(${PkgConfig_FOUND}) - endforeach() +- pkg_check_modules(GLIB glib-2.0) ++ pkg_check_modules(GLIB IMPORTED_TARGET glib-2.0) -+find_library(PCRE_LIBRARY pcre2-8) -+set_property(TARGET GLib2::glib APPEND PROPERTY -+ INTERFACE_LINK_LIBRARIES ${PCRE_LIBRARY} -+) -+set(THREADS_PREFER_PTHREAD_FLAG ON) -+find_package(Threads) -+set_property(TARGET GLib2::glib APPEND PROPERTY -+ INTERFACE_LINK_LIBRARIES Threads::Threads -+) -+ - list(APPEND GLib2_FIND_COMPONENTS glib) - set(GLib2_FIND_REQUIRED_glib TRUE) + if(${GLIB_FOUND}) +- add_library(GLib2::glib UNKNOWN IMPORTED) +- set_target_properties(GLib2::glib PROPERTIES +- IMPORTED_LOCATION "${pkgcfg_lib_GLIB_glib-2.0}" +- INTERFACE_COMPILE_OPTIONS "${GLIB_CFLAGS_OTHER}" +- INTERFACE_INCLUDE_DIRECTORIES "${GLIB_INCLUDE_DIRS}" +- ) ++ add_library(GLib2::glib INTERFACE IMPORTED) ++ target_link_libraries(GLib2::glib INTERFACE PkgConfig::GLIB) + return() + endif() diff --git a/ports/lcm/portfile.cmake b/ports/lcm/portfile.cmake index be6a4cee18..1ae8e8c78c 100644 --- a/ports/lcm/portfile.cmake +++ b/ports/lcm/portfile.cmake @@ -1,19 +1,17 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO lcm-proj/lcm - REF v1.4.0 - SHA512 ca036aa2c31911e0bfaeab9665188c97726201267314693a1c333c4efe13ea598b39a55a19bc1d48e65462ac9d1716adfda5af86c645d59c3247192631247cc6 + REF "v${VERSION}" + SHA512 3da9739a03769e609d44a93ae0f6790a604ca05c93639860bdc67843738452894582ca5eccabc3ade61afe519f40d3147f6bf2fe6ec5abcb03c8dd74dd22fb9c HEAD_REF master PATCHES only-install-one-flavor.patch - fix-build-error.patch glib.link.patch disable-docs.patch - avoid-fake-stdint-h.patch # https://github.com/lcm-proj/lcm/pull/563 ) -# Remove fake stdint.h that conficts with the real one in VS2022 17.13 targeting arm64 -file(REMOVE "${SOURCE_PATH}/WinSpecific/include/inttypes.h" "${SOURCE_PATH}/WinSpecific/include/stdint.h") +vcpkg_find_acquire_program(PKGCONFIG) +set(ENV{PKG_CONFIG} "${PKGCONFIG}") vcpkg_cmake_configure( SOURCE_PATH "${SOURCE_PATH}" @@ -48,4 +46,4 @@ if(VCPKG_LIBRARY_LINKAGE STREQUAL "static") file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin" "${CURRENT_PACKAGES_DIR}/debug/bin") endif() -file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright) +vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/COPYING") diff --git a/ports/lcm/vcpkg.json b/ports/lcm/vcpkg.json index 7538e5c48b..65fbcdabf3 100644 --- a/ports/lcm/vcpkg.json +++ b/ports/lcm/vcpkg.json @@ -1,7 +1,6 @@ { "name": "lcm", - "version": "1.4.0", - "port-version": 7, + "version": "1.5.2", "description": [ "Lightweight Communications and Marshalling (LCM)", "LCM is a set of libraries and tools for message passing and data marshalling, targeted at real-time systems where high-bandwidth and low latency are critical. It provides a publish/subscribe message passing model and automatic marshalling/unmarshalling code generation with bindings for applications in a variety of programming languages." diff --git a/scripts/ci.baseline.txt b/scripts/ci.baseline.txt index 758222a73c..c481aed1d8 100644 --- a/scripts/ci.baseline.txt +++ b/scripts/ci.baseline.txt @@ -336,12 +336,6 @@ juce:x64-android=fail kf6archive:arm-neon-android=skip kf6archive:arm64-android=skip kf6archive:x64-android=skip -lcm:arm-neon-android=fail -lcm:arm64-android=fail -lcm:arm64-windows-static-md=fail -lcm:x64-android=fail -lcm:x64-windows-static-md=fail -lcm:x64-windows-static=fail leptonica:arm64-uwp=fail leptonica:x64-uwp=fail libaiff:x64-linux=fail diff --git a/scripts/ci.feature.baseline.txt b/scripts/ci.feature.baseline.txt index 4df9ed17c6..4cf91df638 100644 --- a/scripts/ci.feature.baseline.txt +++ b/scripts/ci.feature.baseline.txt @@ -115,8 +115,6 @@ ismrmrd:x86-windows=fail jemalloc(android)=fail jemalloc(windows & (arm | uwp))=fail kfr[capi](windows) = feature-fails # feature emits DLL even when built static -lcm:x64-windows-static-md=fail -lcm:x64-windows-static=fail leptonica(uwp)=fail libaiff:x64-linux=fail libcerf:x64-windows-static-md=fail diff --git a/versions/baseline.json b/versions/baseline.json index 423c071d8c..4dd5c26224 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -4521,8 +4521,8 @@ "port-version": 0 }, "lcm": { - "baseline": "1.4.0", - "port-version": 7 + "baseline": "1.5.2", + "port-version": 0 }, "lcms": { "baseline": "2.18", diff --git a/versions/l-/lcm.json b/versions/l-/lcm.json index 0300797224..130e755559 100644 --- a/versions/l-/lcm.json +++ b/versions/l-/lcm.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "a6c6dc725edd7b8b27c34831ffb235f1fb551a13", + "version": "1.5.2", + "port-version": 0 + }, { "git-tree": "38f103e81adb06b1836fef85e22d61ca409e1ec4", "version": "1.4.0",