diff --git a/ports/paho-mqtt/CONTROL b/ports/paho-mqtt/CONTROL index 4d819f5b10..590968f0a0 100644 --- a/ports/paho-mqtt/CONTROL +++ b/ports/paho-mqtt/CONTROL @@ -1,4 +1,4 @@ Source: paho-mqtt -Version: 1.2.1-1 +Version: 1.3.0 Description: Paho project provides open-source client implementations of MQTT and MQTT-SN messaging protocols aimed at new, existing, and emerging applications for the Internet of Things Build-Depends: openssl diff --git a/ports/paho-mqtt/fix-install-path.patch b/ports/paho-mqtt/fix-install-path.patch index 512052e1a8..4781419315 100644 --- a/ports/paho-mqtt/fix-install-path.patch +++ b/ports/paho-mqtt/fix-install-path.patch @@ -1,48 +1,56 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 418e2f2..f05aad4 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -62,9 +62,9 @@ ENDIF() - ### packaging settings - SET(CPACK_PACKAGE_VENDOR "Eclipse Paho") - SET(CPACK_PACKAGE_NAME "Eclipse-Paho-MQTT-C") --INSTALL(FILES CONTRIBUTING.md epl-v10 edl-v10 README.md notice.html DESTINATION .) -+INSTALL(FILES CONTRIBUTING.md epl-v10 edl-v10 README.md notice.html DESTINATION share/paho-mqtt) - FILE(GLOB samples "src/samples/*.c") --INSTALL(FILES ${samples} DESTINATION samples) -+INSTALL(FILES ${samples} DESTINATION share/paho-mqtt/samples) - IF (WIN32) - SET(CPACK_GENERATOR "ZIP") - ELSEIF(PAHO_BUILD_DEB_PACKAGE) -diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt -index 06e4c5d..9cf7c21 100644 ---- a/doc/CMakeLists.txt -+++ b/doc/CMakeLists.txt -@@ -37,4 +37,4 @@ FOREACH(DOXYFILE_SRC DoxyfileV3ClientAPI;DoxyfileV3AsyncAPI;DoxyfileV3ClientInte - SET(DOXYTARGETS ${DOXYTARGETS} ${DOXYFILE_SRC}.target) - ENDFOREACH(DOXYFILE_SRC) - ADD_CUSTOM_TARGET(doc ALL DEPENDS ${DOXYTARGETS}) --INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/doc DESTINATION share) -+INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/doc DESTINATION share/paho-mqtt) -diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index c57185b..98c7f31 100644 ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -84,7 +84,7 @@ INSTALL(TARGETS paho-mqtt3c paho-mqtt3a - LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} - RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) - INSTALL(TARGETS MQTTVersion -- RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) -+ RUNTIME DESTINATION tools/paho-mqtt) - - IF (PAHO_BUILD_STATIC) - ADD_LIBRARY(paho-mqtt3c-static STATIC $ MQTTClient.c) -@@ -98,7 +98,7 @@ IF (PAHO_BUILD_STATIC) - ENDIF() - - INSTALL(FILES MQTTAsync.h MQTTClient.h MQTTClientPersistence.h -- DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) -+ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/paho-mqtt) - - IF (PAHO_WITH_SSL) - SET(OPENSSL_SEARCH_PATH "" CACHE PATH "Directory containing OpenSSL libraries and includes") +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 64ae92c..6d552d1 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -64,11 +64,11 @@ ENDIF() + IF (PAHO_ENABLE_CPACK) + ### packaging settings + FILE(GLOB samples "src/samples/*.c") +- INSTALL(FILES ${samples} DESTINATION samples) ++ INSTALL(FILES ${samples} DESTINATION share/paho-mqtt/samples) + + SET(CPACK_PACKAGE_VENDOR "Eclipse Paho") + SET(CPACK_PACKAGE_NAME "Eclipse-Paho-MQTT-C") +- INSTALL(FILES CONTRIBUTING.md epl-v10 edl-v10 README.md notice.html DESTINATION .) ++ INSTALL(FILES CONTRIBUTING.md epl-v10 edl-v10 README.md notice.html DESTINATION share/paho-mqtt) + + IF (WIN32) + SET(CPACK_GENERATOR "ZIP") +diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt +index f15f314..54deec5 100644 +--- a/doc/CMakeLists.txt ++++ b/doc/CMakeLists.txt +@@ -39,7 +39,7 @@ ENDFOREACH(DOXYFILE_SRC) + + ADD_CUSTOM_TARGET(doc ALL DEPENDS ${DOXYTARGETS}) + IF (PAHO_ENABLE_CPACK) +- INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/doc DESTINATION share) ++ INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/doc DESTINATION share/paho-mqtt) + ELSE() + INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/doc DESTINATION ${CMAKE_INSTALL_DOCDIR}) + ENDIF() +\ No newline at end of file +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index b46eaca..a132062 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -89,7 +89,7 @@ INSTALL(TARGETS paho-mqtt3c paho-mqtt3a + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) + INSTALL(TARGETS MQTTVersion +- RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) ++ RUNTIME DESTINATION tools/paho-mqtt) + + IF (PAHO_BUILD_STATIC) + ADD_LIBRARY(paho-mqtt3c-static STATIC $ MQTTClient.c) +@@ -102,8 +102,8 @@ IF (PAHO_BUILD_STATIC) + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}) + ENDIF() + +-INSTALL(FILES MQTTAsync.h MQTTClient.h MQTTClientPersistence.h MQTTProperties.h MQTTReasonCodes.h MQTTSubscribeOpts.h +- DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) ++INSTALL(FILES MQTTAsync.h MQTTClient.h MQTTClientPersistence.h MQTTProperties.h MQTTReasonCodes.h MQTTSubscribeOpts.h ++ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/paho-mqtt) + + IF (PAHO_WITH_SSL) + SET(OPENSSL_SEARCH_PATH "" CACHE PATH "Directory containing OpenSSL libraries and includes") diff --git a/ports/paho-mqtt/fix-unresolvedsymbol-arm.patch b/ports/paho-mqtt/fix-unresolvedsymbol-arm.patch new file mode 100644 index 0000000000..1659018878 --- /dev/null +++ b/ports/paho-mqtt/fix-unresolvedsymbol-arm.patch @@ -0,0 +1,12 @@ +diff --git a/src/SHA1.c b/src/SHA1.c +index 9bb1175..b2ef930 100644 +--- a/src/SHA1.c ++++ b/src/SHA1.c +@@ -19,6 +19,7 @@ + #if !defined(OPENSSL) + #if defined(WIN32) || defined(WIN64) + #pragma comment(lib, "crypt32.lib") ++#pragma comment(lib, "Advapi32.lib") + + int SHA1_Init(SHA_CTX *c) + { diff --git a/ports/paho-mqtt/portfile.cmake b/ports/paho-mqtt/portfile.cmake index 5453abf1b7..03b6c73bd7 100644 --- a/ports/paho-mqtt/portfile.cmake +++ b/ports/paho-mqtt/portfile.cmake @@ -3,13 +3,14 @@ include(vcpkg_common_functions) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO eclipse/paho.mqtt.c - REF v1.2.1 - SHA512 98828852ecd127445591df31416adaebebd30848c027361ae62af6b14b84e3cf2a4b90cab692b983148cbf93f710a9e2dd722a3da8c4fd17eb2149e4227a8860 + REF 9f715d0862a8e16099b5837c4e53a1bf6a6a0675 + SHA512 3ab5e25bfe303f51485696248e78a8a10f20c0e69b7ea6016165a97d61172336e8fbe5b9d059ae546357bace9f3adb8e2026643b61a6af82fae448a024e51d21 HEAD_REF master PATCHES remove_compiler_options.patch fix-install-path.patch fix-static-build.patch + fix-unresolvedsymbol-arm.patch ) string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "static" PAHO_BUILD_STATIC)