aboutsummaryrefslogtreecommitdiff
path: root/ports/mosquitto
diff options
context:
space:
mode:
authornicole mazzuca <mazzucan@outlook.com>2020-09-24 15:15:06 -0700
committerGitHub <noreply@github.com>2020-09-24 15:15:06 -0700
commit4cbbcbddfd42d94d6d8ee6c8b6ad00ef6a0927d3 (patch)
tree371509cc59c45895c85e5e049aaa2cd9c39cc7b0 /ports/mosquitto
parentc1acea1f044d3300b0c3791c2ce74d53e5a15548 (diff)
downloadvcpkg-4cbbcbddfd42d94d6d8ee6c8b6ad00ef6a0927d3.tar.gz
vcpkg-4cbbcbddfd42d94d6d8ee6c8b6ad00ef6a0927d3.zip
[vcpkg macos ci] Switch to using our own base boxes, to fix bringing up mac machines (#13619)
* [vcpkg ci:osx] Remove brew install * add instructions for creating a new vagrant box * fix the vagrant scripts for the new box * finish fixing the setup * [mecab jxrlib] fix ports for CI mecab needed to use an actual ref that wasn't master, and jxrlib needed a patch for xcode 12 CLTs. Additionally, this fixes the mecab version to be a date, the date of the last commit, since `1.0` is not the correct version (mecab doesn't have released versions) * [many ports] fix compile with Xcode 12 CLTs This mostly means fixing errors on implicit-function-declaration, and removing some Werrors * alac-decoder * apr * argtable2 * arrow * hyperscan * mcpp * minizip * mosquitto * stormlib * [many ports] even more Xcode 12 CLT fixes * [jxrlib darknet] fix the last ports! (hopefully) * CRs, plus minor wip changes to osx scripts
Diffstat (limited to 'ports/mosquitto')
-rw-r--r--ports/mosquitto/0001-add-archive-destination-to-install.patch (renamed from ports/mosquitto/archive-dest.patch)65
-rw-r--r--ports/mosquitto/0002-win64-support.patch (renamed from ports/mosquitto/win64-cmake.patch)23
-rw-r--r--ports/mosquitto/0003-add-find_package-libwebsockets.patch24
-rw-r--r--ports/mosquitto/0004-support-static-build.patch (renamed from ports/mosquitto/support-static-build.patch)89
-rw-r--r--ports/mosquitto/0005-add-mach.h-include.patch27
-rw-r--r--ports/mosquitto/libwebsockets.patch12
-rw-r--r--ports/mosquitto/portfile.cmake9
-rw-r--r--ports/mosquitto/vcpkg.json2
8 files changed, 165 insertions, 86 deletions
diff --git a/ports/mosquitto/archive-dest.patch b/ports/mosquitto/0001-add-archive-destination-to-install.patch
index 40d6c1f6d..5df6128ed 100644
--- a/ports/mosquitto/archive-dest.patch
+++ b/ports/mosquitto/0001-add-archive-destination-to-install.patch
@@ -1,26 +1,39 @@
-diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt
-index e1521f1..bd60b75 100644
---- a/lib/CMakeLists.txt
-+++ b/lib/CMakeLists.txt
-@@ -87,7 +87,7 @@ set_target_properties(libmosquitto PROPERTIES
- SOVERSION 1
- )
-
--install(TARGETS libmosquitto RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}")
-+install(TARGETS libmosquitto RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}")
-
- if (WITH_STATIC_LIBRARIES)
- add_library(libmosquitto_static STATIC ${C_SRC})
-diff --git a/lib/cpp/CMakeLists.txt b/lib/cpp/CMakeLists.txt
-index b39ac3f..5805244 100644
---- a/lib/cpp/CMakeLists.txt
-+++ b/lib/cpp/CMakeLists.txt
-@@ -13,7 +13,7 @@ set_target_properties(mosquittopp PROPERTIES
- VERSION ${VERSION}
- SOVERSION 1
- )
--install(TARGETS mosquittopp RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}")
-+install(TARGETS mosquittopp RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}")
-
- if (WITH_STATIC_LIBRARIES)
- add_library(mosquittopp_static STATIC
+From df5ec7ba4e7b1516a2636e47c33a4a6161b5c422 Mon Sep 17 00:00:00 2001
+From: Nicole Mazzuca <mazzucan@outlook.com>
+Date: Tue, 22 Sep 2020 15:38:44 -0700
+Subject: [PATCH 1/5] add archive destination to install
+
+---
+ lib/CMakeLists.txt | 2 +-
+ lib/cpp/CMakeLists.txt | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt
+index e1521f1..bd60b75 100644
+--- a/lib/CMakeLists.txt
++++ b/lib/CMakeLists.txt
+@@ -87,7 +87,7 @@ set_target_properties(libmosquitto PROPERTIES
+ SOVERSION 1
+ )
+
+-install(TARGETS libmosquitto RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}")
++install(TARGETS libmosquitto RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}")
+
+ if (WITH_STATIC_LIBRARIES)
+ add_library(libmosquitto_static STATIC ${C_SRC})
+diff --git a/lib/cpp/CMakeLists.txt b/lib/cpp/CMakeLists.txt
+index b39ac3f..5805244 100644
+--- a/lib/cpp/CMakeLists.txt
++++ b/lib/cpp/CMakeLists.txt
+@@ -13,7 +13,7 @@ set_target_properties(mosquittopp PROPERTIES
+ VERSION ${VERSION}
+ SOVERSION 1
+ )
+-install(TARGETS mosquittopp RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}")
++install(TARGETS mosquittopp RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}")
+
+ if (WITH_STATIC_LIBRARIES)
+ add_library(mosquittopp_static STATIC
+--
+2.24.3 (Apple Git-128)
+
diff --git a/ports/mosquitto/win64-cmake.patch b/ports/mosquitto/0002-win64-support.patch
index 3fdb93700..8698db81a 100644
--- a/ports/mosquitto/win64-cmake.patch
+++ b/ports/mosquitto/0002-win64-support.patch
@@ -1,8 +1,18 @@
+From 675ba1de6c01b4050ae3cc60916d3f0a72b03105 Mon Sep 17 00:00:00 2001
+From: Nicole Mazzuca <mazzucan@outlook.com>
+Date: Tue, 22 Sep 2020 15:40:55 -0700
+Subject: [PATCH 2/5] win64 support
+
+---
+ CMakeLists.txt | 7 +------
+ config.h | 2 +-
+ 2 files changed, 2 insertions(+), 7 deletions(-)
+
diff --git a/CMakeLists.txt b/CMakeLists.txt
-index e58d072..e582a25 100644
+index e11959c..1a92fe3 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
-@@ -54,12 +54,7 @@ option(WITH_THREADING "Include client library threading support?" ON)
+@@ -57,12 +57,7 @@ option(WITH_THREADING "Include client library threading support?" ON)
if (WITH_THREADING)
add_definitions("-DWITH_THREADING")
if (WIN32)
@@ -17,15 +27,18 @@ index e58d072..e582a25 100644
find_library(LIBPTHREAD pthread)
if (LIBPTHREAD)
diff --git a/config.h b/config.h
-index b7a7616..bceb92a 100644
+index 5cce39e..c673bf4 100644
--- a/config.h
+++ b/config.h
-@@ -27,7 +27,7 @@
+@@ -31,7 +31,7 @@
# define EPROTO ECONNABORTED
#endif
-#ifdef WIN32
-+#if defined(WIN32) || defined(WIN64)
++#ifdef _WIN32
# ifndef strcasecmp
# define strcasecmp strcmpi
# endif
+--
+2.24.3 (Apple Git-128)
+
diff --git a/ports/mosquitto/0003-add-find_package-libwebsockets.patch b/ports/mosquitto/0003-add-find_package-libwebsockets.patch
new file mode 100644
index 000000000..b167b0da5
--- /dev/null
+++ b/ports/mosquitto/0003-add-find_package-libwebsockets.patch
@@ -0,0 +1,24 @@
+From 902ab5bf91937188d3ebf0aece81a704729e5580 Mon Sep 17 00:00:00 2001
+From: Nicole Mazzuca <mazzucan@outlook.com>
+Date: Tue, 22 Sep 2020 15:42:53 -0700
+Subject: [PATCH 3/5] add find_package libwebsockets
+
+---
+ CMakeLists.txt | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 1a92fe3..3c78b2c 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -45,6 +45,7 @@ endif (WITH_TLS)
+
+ option(WITH_SOCKS "Include SOCKS5 support?" ON)
+ if (WITH_SOCKS)
++ find_package(Libwebsockets CONFIG REQUIRED)
+ add_definitions("-DWITH_SOCKS")
+ endif (WITH_SOCKS)
+
+--
+2.24.3 (Apple Git-128)
+
diff --git a/ports/mosquitto/support-static-build.patch b/ports/mosquitto/0004-support-static-build.patch
index 28d7d779a..55606e7d5 100644
--- a/ports/mosquitto/support-static-build.patch
+++ b/ports/mosquitto/0004-support-static-build.patch
@@ -1,38 +1,51 @@
-diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt
-index bd60b75..cc01a2a 100644
---- a/lib/CMakeLists.txt
-+++ b/lib/CMakeLists.txt
-@@ -60,7 +60,7 @@ if (UNIX AND NOT APPLE)
- endif (UNIX AND NOT APPLE)
-
- if (WIN32)
-- set (LIBRARIES ${LIBRARIES} ws2_32)
-+ set (LIBRARIES ${LIBRARIES} ws2_32 crypt32)
- endif (WIN32)
-
- if (WITH_SRV)
-diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
-index 7898ff5..23b3fe8 100644
---- a/src/CMakeLists.txt
-+++ b/src/CMakeLists.txt
-@@ -158,7 +158,7 @@ if (UNIX)
- endif (UNIX)
-
- if (WIN32)
-- set (MOSQ_LIBS ${MOSQ_LIBS} ws2_32)
-+ set (MOSQ_LIBS ${MOSQ_LIBS} ws2_32 crypt32)
- endif (WIN32)
-
- if (WITH_WEBSOCKETS)
-@@ -189,6 +189,10 @@ install(FILES mosquitto_broker.h mosquitto_plugin.h DESTINATION "${CMAKE_INSTALL
-
- if (WITH_TLS)
- add_executable(mosquitto_passwd mosquitto_passwd.c)
-- target_link_libraries(mosquitto_passwd ${OPENSSL_LIBRARIES})
-+ if(WIN32)
-+ target_link_libraries(mosquitto_passwd ${OPENSSL_LIBRARIES} ws2_32 crypt32)
-+ else()
-+ target_link_libraries(mosquitto_passwd ${OPENSSL_LIBRARIES})
-+ endif()
- install(TARGETS mosquitto_passwd RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}")
- endif (WITH_TLS)
+From 4bb19e77e95bc505d32e098190ffbf056810017c Mon Sep 17 00:00:00 2001
+From: Nicole Mazzuca <mazzucan@outlook.com>
+Date: Tue, 22 Sep 2020 15:44:42 -0700
+Subject: [PATCH 4/5] support static build
+
+---
+ lib/CMakeLists.txt | 2 +-
+ src/CMakeLists.txt | 8 ++++++--
+ 2 files changed, 7 insertions(+), 3 deletions(-)
+
+diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt
+index bd60b75..cc01a2a 100644
+--- a/lib/CMakeLists.txt
++++ b/lib/CMakeLists.txt
+@@ -60,7 +60,7 @@ if (UNIX AND NOT APPLE)
+ endif (UNIX AND NOT APPLE)
+
+ if (WIN32)
+- set (LIBRARIES ${LIBRARIES} ws2_32)
++ set (LIBRARIES ${LIBRARIES} ws2_32 crypt32)
+ endif (WIN32)
+
+ if (WITH_SRV)
+diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
+index 7898ff5..f066aea 100644
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -158,7 +158,7 @@ if (UNIX)
+ endif (UNIX)
+
+ if (WIN32)
+- set (MOSQ_LIBS ${MOSQ_LIBS} ws2_32)
++ set (MOSQ_LIBS ${MOSQ_LIBS} ws2_32 crypt32)
+ endif (WIN32)
+
+ if (WITH_WEBSOCKETS)
+@@ -189,6 +189,10 @@ install(FILES mosquitto_broker.h mosquitto_plugin.h DESTINATION "${CMAKE_INSTALL
+
+ if (WITH_TLS)
+ add_executable(mosquitto_passwd mosquitto_passwd.c)
+- target_link_libraries(mosquitto_passwd ${OPENSSL_LIBRARIES})
++ if(WIN32)
++ target_link_libraries(mosquitto_passwd ${OPENSSL_LIBRARIES} ws2_32 crypt32)
++ else()
++ target_link_libraries(mosquitto_passwd ${OPENSSL_LIBRARIES})
++ endif()
+ install(TARGETS mosquitto_passwd RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}")
+ endif (WITH_TLS)
+--
+2.24.3 (Apple Git-128)
+
diff --git a/ports/mosquitto/0005-add-mach.h-include.patch b/ports/mosquitto/0005-add-mach.h-include.patch
new file mode 100644
index 000000000..b01ff534b
--- /dev/null
+++ b/ports/mosquitto/0005-add-mach.h-include.patch
@@ -0,0 +1,27 @@
+From af7d62dceb064b5a8458616536bc27329ad236b1 Mon Sep 17 00:00:00 2001
+From: Nicole Mazzuca <mazzucan@outlook.com>
+Date: Tue, 22 Sep 2020 15:46:06 -0700
+Subject: [PATCH 5/5] add mach.h include
+
+---
+ lib/mosquitto.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/lib/mosquitto.c b/lib/mosquitto.c
+index 795013e..cd00513 100644
+--- a/lib/mosquitto.c
++++ b/lib/mosquitto.c
+@@ -33,6 +33,10 @@ Contributors:
+ #include "packet_mosq.h"
+ #include "will_mosq.h"
+
++#if defined(__APPLE__)
++#include <mach/mach_time.h>
++#endif
++
+
+ void mosquitto__destroy(struct mosquitto *mosq);
+
+--
+2.24.3 (Apple Git-128)
+
diff --git a/ports/mosquitto/libwebsockets.patch b/ports/mosquitto/libwebsockets.patch
deleted file mode 100644
index 647ff5d70..000000000
--- a/ports/mosquitto/libwebsockets.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 473931c8f..a8aa78e5d 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -45,6 +45,7 @@ endif (WITH_TLS)
-
- option(WITH_SOCKS "Include SOCKS5 support?" ON)
- if (WITH_SOCKS)
-+ find_package(Libwebsockets CONFIG REQUIRED)
- add_definitions("-DWITH_SOCKS")
- endif (WITH_SOCKS)
-
diff --git a/ports/mosquitto/portfile.cmake b/ports/mosquitto/portfile.cmake
index 8c83401c9..bf832107b 100644
--- a/ports/mosquitto/portfile.cmake
+++ b/ports/mosquitto/portfile.cmake
@@ -5,10 +5,11 @@ vcpkg_from_github(
SHA512 c192b53f52ce9dc8e02d31acd9e93c00cafbe543b038d7619e6b653f102126872bbd485c94604bca9287e71a5dfe0de2f4d8d3f51cdd5c37f90fd2a6535bd89b
HEAD_REF master
PATCHES
- archive-dest.patch
- win64-cmake.patch
- libwebsockets.patch
- support-static-build.patch
+ 0001-add-archive-destination-to-install.patch
+ 0002-win64-support.patch
+ 0003-add-find_package-libwebsockets.patch
+ 0004-support-static-build.patch
+ 0005-add-mach.h-include.patch
)
vcpkg_configure_cmake(
diff --git a/ports/mosquitto/vcpkg.json b/ports/mosquitto/vcpkg.json
index 2e3654754..4f0c61634 100644
--- a/ports/mosquitto/vcpkg.json
+++ b/ports/mosquitto/vcpkg.json
@@ -1,7 +1,7 @@
{
"name": "mosquitto",
"version-string": "1.6.8",
- "port-version": 2,
+ "port-version": 3,
"description": "Mosquitto is an open source message broker that implements the MQ Telemetry Transport protocol versions 3.1 and 3.1.1, MQTT provides a lightweight method of carrying out messaging using a publish/subscribe model, This makes it suitable for machine to machine messaging such as with low power sensors or mobile devices such as phones, embedded computers or microcontrollers like the Arduino",
"homepage": "https://mosquitto.org/download/",
"dependencies": [