diff options
author | Yi Zhao <yi.zhao@windriver.com> | 2024-03-21 11:13:05 +0800 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2024-03-20 20:16:07 -0700 |
commit | 7cf7c4c7828e9ad673f717f4cad9997314d4b1aa (patch) | |
tree | 6d312f3b628c96e375e01738133ce6455fd8e7e1 | |
parent | 0c19e65a0969dc79093284e98b43fd46468a499f (diff) | |
download | meta-openembedded-7cf7c4c7828e9ad673f717f4cad9997314d4b1aa.tar.gz |
minifi-cpp: upgrade 0.7.0 -> 0.15.0
Release Notes:
https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=65145325#ReleaseNotesMiNiFi(C++)-Versioncpp-0.15.0
* Use external dependencies where possible to get rid of bundled
packages.
* Add PACKAGECONFIGs.
* Use its own systemd service file.
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
33 files changed, 574 insertions, 1063 deletions
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-Add-lxml2-to-linker-cmdline-of-xml-is-found.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-Add-lxml2-to-linker-cmdline-of-xml-is-found.patch deleted file mode 100644 index d813b37f9..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-Add-lxml2-to-linker-cmdline-of-xml-is-found.patch +++ /dev/null | |||
@@ -1,39 +0,0 @@ | |||
1 | From 609e1745d26d6f42d426018a4dd8d2342d6fc170 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Tue, 18 Aug 2020 08:37:57 -0700 | ||
4 | Subject: [PATCH] Add -lxml2 to linker cmdline of xml is found | ||
5 | |||
6 | When cross compiling for systems where static libs | ||
7 | for libxml are not available cmake's detection mechanism | ||
8 | resort to linking with libxml.so but doesnt use -lxml2 | ||
9 | liblldbHost.a however requires libxml on linker | ||
10 | cmdline _after_ itself so its use of symbols from libxml2 | ||
11 | can be resolved. Here check for libxml2 being detected and | ||
12 | add it if its found. | ||
13 | |||
14 | Fixes | ||
15 | minifi-cpp/0.7.0-r0/recipe-sysroot-native/usr/lib/libxml2.so is incompatible with elf32-i386 | ||
16 | | clang-11: error: linker command failed with exit code 1 (use -v to see invocation) | ||
17 | |||
18 | Upstream-Status: Pending | ||
19 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
20 | --- | ||
21 | thirdparty/libarchive-3.3.2/CMakeLists.txt | 2 +- | ||
22 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
23 | |||
24 | diff --git a/thirdparty/libarchive-3.3.2/CMakeLists.txt b/thirdparty/libarchive-3.3.2/CMakeLists.txt | ||
25 | index 0c1ea6f7..cde0cc51 100644 | ||
26 | --- a/thirdparty/libarchive-3.3.2/CMakeLists.txt | ||
27 | +++ b/thirdparty/libarchive-3.3.2/CMakeLists.txt | ||
28 | @@ -1031,7 +1031,7 @@ ENDIF() | ||
29 | IF(LIBXML2_FOUND) | ||
30 | CMAKE_PUSH_CHECK_STATE() # Save the state of the variables | ||
31 | INCLUDE_DIRECTORIES(${LIBXML2_INCLUDE_DIR}) | ||
32 | - LIST(APPEND ADDITIONAL_LIBS ${LIBXML2_LIBRARIES}) | ||
33 | + LIST(APPEND ADDITIONAL_LIBS xml2) | ||
34 | SET(HAVE_LIBXML2 1) | ||
35 | # libxml2's include files use iconv.h | ||
36 | SET(CMAKE_REQUIRED_INCLUDES ${ICONV_INCLUDE_DIR} ${LIBXML2_INCLUDE_DIR}) | ||
37 | -- | ||
38 | 2.28.0 | ||
39 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-Add-missing-includes-cstdint-and-cstdio.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-Add-missing-includes-cstdint-and-cstdio.patch deleted file mode 100644 index 0fce8dc64..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-Add-missing-includes-cstdint-and-cstdio.patch +++ /dev/null | |||
@@ -1,70 +0,0 @@ | |||
1 | From 6e376601c990abaa5e261d1311f92acb3b370b8f Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Tue, 24 Jan 2023 21:40:43 -0800 | ||
4 | Subject: [PATCH] Add missing includes <cstdint> and <cstdio> | ||
5 | |||
6 | This is needed with GCC 13 and newer [1] | ||
7 | |||
8 | [1] https://www.gnu.org/software/gcc/gcc-13/porting_to.html | ||
9 | |||
10 | Upstream-Status: Backport [https://github.com/facebook/rocksdb/commit/88edfbfb5e1cac228f7cc31fbec24bb637fe54b1] | ||
11 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
12 | --- | ||
13 | .../rocksdb/rocksdb/db/compaction/compaction_iteration_stats.h | 1 + | ||
14 | storage/rocksdb/rocksdb/include/rocksdb/utilities/checkpoint.h | 1 + | ||
15 | .../rocksdb/rocksdb/table/block_based/data_block_hash_index.h | 1 + | ||
16 | storage/rocksdb/rocksdb/util/slice.cc | 1 + | ||
17 | storage/rocksdb/rocksdb/util/string_util.h | 1 + | ||
18 | tpool/aio_linux.cc | 1 + | ||
19 | 6 files changed, 6 insertions(+) | ||
20 | |||
21 | --- a/thirdparty/rocksdb/include/rocksdb/utilities/checkpoint.h | ||
22 | +++ b/thirdparty/rocksdb/include/rocksdb/utilities/checkpoint.h | ||
23 | @@ -8,6 +8,7 @@ | ||
24 | #pragma once | ||
25 | #ifndef ROCKSDB_LITE | ||
26 | |||
27 | +#include <cstdint> | ||
28 | #include <string> | ||
29 | #include "rocksdb/status.h" | ||
30 | |||
31 | --- a/thirdparty/rocksdb/util/string_util.h | ||
32 | +++ b/thirdparty/rocksdb/util/string_util.h | ||
33 | @@ -6,6 +6,7 @@ | ||
34 | |||
35 | #pragma once | ||
36 | |||
37 | +#include <cstdint> | ||
38 | #include <sstream> | ||
39 | #include <string> | ||
40 | #include <unordered_map> | ||
41 | --- a/extensions/expression-language/common/Value.h | ||
42 | +++ b/extensions/expression-language/common/Value.h | ||
43 | @@ -15,6 +15,7 @@ | ||
44 | * limitations under the License. | ||
45 | */ | ||
46 | |||
47 | +#include <cstdint> | ||
48 | #include <string> | ||
49 | #include <sstream> | ||
50 | #include <iomanip> | ||
51 | --- a/libminifi/include/utils/StringUtils.h | ||
52 | +++ b/libminifi/include/utils/StringUtils.h | ||
53 | @@ -18,6 +18,7 @@ | ||
54 | #define LIBMINIFI_INCLUDE_IO_STRINGUTILS_H_ | ||
55 | #include <iostream> | ||
56 | #include <cstring> | ||
57 | +#include <cstdint> | ||
58 | #include <functional> | ||
59 | #ifdef WIN32 | ||
60 | #include <cwctype> | ||
61 | --- a/thirdparty/rocksdb/db/compaction_iteration_stats.h | ||
62 | +++ b/thirdparty/rocksdb/db/compaction_iteration_stats.h | ||
63 | @@ -5,6 +5,7 @@ | ||
64 | |||
65 | #pragma once | ||
66 | |||
67 | +#include <cstdint> | ||
68 | struct CompactionIterationStats { | ||
69 | // Compaction statistics | ||
70 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-BundledOSSPUUID.cmake-Pass-CFLAGS-to-compiler.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-BundledOSSPUUID.cmake-Pass-CFLAGS-to-compiler.patch deleted file mode 100644 index ceb8ec34b..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-BundledOSSPUUID.cmake-Pass-CFLAGS-to-compiler.patch +++ /dev/null | |||
@@ -1,35 +0,0 @@ | |||
1 | From ab031c2b1f8c03e23a8dc8a95c9c9e9b8ce397b2 Mon Sep 17 00:00:00 2001 | ||
2 | From: Mingli Yu <mingli.yu@windriver.com> | ||
3 | Date: Fri, 15 Sep 2023 11:32:11 +0800 | ||
4 | Subject: [PATCH] BundledOSSPUUID.cmake: Pass CFLAGS to compiler | ||
5 | |||
6 | Make sure -fdebug-prefix-map options are passed to compiler to fix the | ||
7 | below warning: | ||
8 | WARNING: minifi-cpp-0.7.0-r0 do_package_qa: QA Issue: File /usr/bin/.debug/minificontroller in package minifi-cpp-dbg contains reference to TMPDIR | ||
9 | File /usr/bin/.debug/minifi in package minifi-cpp-dbg contains reference to TMPDIR [buildpaths] | ||
10 | |||
11 | Upsteam-Status: Pending | ||
12 | |||
13 | Signed-off-by: Mingli Yu <mingli.yu@windriver.com> | ||
14 | --- | ||
15 | Upstream-Status: Pending | ||
16 | |||
17 | cmake/BundledOSSPUUID.cmake | 2 +- | ||
18 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
19 | |||
20 | diff --git a/cmake/BundledOSSPUUID.cmake b/cmake/BundledOSSPUUID.cmake | ||
21 | index 0cf4bac0..ec57ef51 100644 | ||
22 | --- a/cmake/BundledOSSPUUID.cmake | ||
23 | +++ b/cmake/BundledOSSPUUID.cmake | ||
24 | @@ -37,7 +37,7 @@ function(use_bundled_osspuuid SOURCE_DIR BINARY_DIR) | ||
25 | ENDFOREACH(BYPRODUCT) | ||
26 | |||
27 | # Build project | ||
28 | - set(CONFIGURE_COMMAND ac_cv_va_copy=C99 ./configure CFLAGS=-fPIC CXXFLAGS=-fPIC --host=${HOST_SYS} | ||
29 | + set(CONFIGURE_COMMAND ac_cv_va_copy=C99 ./configure CXXFLAGS=-fPIC --host=${HOST_SYS} | ||
30 | --with-cxx --without-perl --without-php --without-pgsql | ||
31 | --prefix=${BINARY_DIR}/thirdparty/ossp-uuid-install) | ||
32 | string(TOLOWER "${CMAKE_BUILD_TYPE}" build_type) | ||
33 | -- | ||
34 | 2.25.1 | ||
35 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-CMakeLists.txt-Pass-the-OPENSSLDIR.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-CMakeLists.txt-Pass-the-OPENSSLDIR.patch deleted file mode 100644 index 158fed559..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-CMakeLists.txt-Pass-the-OPENSSLDIR.patch +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | From 0c5735a0a02e15c3eae94d25fb8756285d121ddb Mon Sep 17 00:00:00 2001 | ||
2 | From: Mingli Yu <mingli.yu@windriver.com> | ||
3 | Date: Fri, 15 Sep 2023 10:59:05 +0800 | ||
4 | Subject: [PATCH] CMakeLists.txt: Pass the OPENSSLDIR | ||
5 | |||
6 | Fixes: | ||
7 | WARNING: minifi-cpp-0.7.0-r0 do_package_qa: QA Issue: File /usr/bin/minificontroller in package minifi-cpp contains reference to TMPDIR | ||
8 | File /usr/bin/minifi in package minifi-cpp contains reference to TMPDIR [buildpaths] | ||
9 | |||
10 | Upstream-Status: Pending | ||
11 | |||
12 | Signed-off-by: Mingli Yu <mingli.yu@windriver.com> | ||
13 | --- | ||
14 | CMakeLists.txt | 1 + | ||
15 | 1 file changed, 1 insertion(+) | ||
16 | |||
17 | diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
18 | index 215a4ef4..6fe8101f 100644 | ||
19 | --- a/CMakeLists.txt | ||
20 | +++ b/CMakeLists.txt | ||
21 | @@ -75,6 +75,7 @@ set(PASSTHROUGH_CMAKE_ARGS -DANDROID_ABI=${ANDROID_ABI} | ||
22 | -DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=${CMAKE_FIND_ROOT_PATH_MODE_LIBRARY} | ||
23 | -DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=${CMAKE_FIND_ROOT_PATH_MODE_INCLUDE} | ||
24 | -DCMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX} | ||
25 | + -DOPENSSLDIR=${OPENSSLDIR} | ||
26 | ${OPENSSL_PASSTHROUGH} | ||
27 | -G${CMAKE_GENERATOR}) | ||
28 | |||
29 | -- | ||
30 | 2.25.1 | ||
31 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-CMakeLists.txt-use-curl-local-source-tarball.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-CMakeLists.txt-use-curl-local-source-tarball.patch deleted file mode 100644 index 183a006e8..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-CMakeLists.txt-use-curl-local-source-tarball.patch +++ /dev/null | |||
@@ -1,34 +0,0 @@ | |||
1 | From 8d99edeefb23c9d7574a0b5a0e2e3f41b0433490 Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Thu, 10 Sep 2020 16:14:10 +0800 | ||
4 | Subject: [PATCH] CMakeLists.txt: use curl local source tarball | ||
5 | |||
6 | Do not download curl source during compile. | ||
7 | |||
8 | Upstream-Status: Inappropriate [embedded specific] | ||
9 | |||
10 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
11 | --- | ||
12 | CMakeLists.txt | 6 +----- | ||
13 | 1 file changed, 1 insertion(+), 5 deletions(-) | ||
14 | |||
15 | diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
16 | index 7cd550fb..215a4ef4 100644 | ||
17 | --- a/CMakeLists.txt | ||
18 | +++ b/CMakeLists.txt | ||
19 | @@ -314,11 +314,7 @@ endif() | ||
20 | |||
21 | ExternalProject_Add( | ||
22 | curl-external | ||
23 | - GIT_REPOSITORY "https://github.com/curl/curl.git" | ||
24 | - GIT_TAG "f3294d9d86e6a7915a967efff2842089b8b0d071" # Version 7.64.0 | ||
25 | - SOURCE_DIR "${CMAKE_CURRENT_BINARY_DIR}/thirdparty/curl-src" | ||
26 | - LIST_SEPARATOR % # This is needed for passing semicolon-separated lists | ||
27 | - TLS_VERIFY OFF | ||
28 | + SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/thirdparty/curl-7.64.0" | ||
29 | CMAKE_ARGS ${PASSTHROUGH_CMAKE_ARGS} | ||
30 | "-DCMAKE_INSTALL_PREFIX=${CMAKE_CURRENT_BINARY_DIR}/thirdparty/curl-install" | ||
31 | "-DCMAKE_INSTALL_LIBDIR=lib${LIBSUFFIX}" | ||
32 | -- | ||
33 | 2.17.1 | ||
34 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-Do-not-use-LFS64-functions-on-linux-musl.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-Do-not-use-LFS64-functions-on-linux-musl.patch deleted file mode 100644 index 29f5b94a0..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-Do-not-use-LFS64-functions-on-linux-musl.patch +++ /dev/null | |||
@@ -1,35 +0,0 @@ | |||
1 | From 6690e7fe566445e20fec178e9e209e5f9f2fdde3 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Wed, 5 Apr 2023 23:33:46 -0700 | ||
4 | Subject: [PATCH] Do not use LFS64 functions on linux/musl | ||
5 | |||
6 | On musl, off_t is 64bit always ( even on 32bit platforms ), therefore using | ||
7 | LFS64 funcitons is not needed on such platforms. Moreover, musl has stopped | ||
8 | providing aliases for these functions [1] which means it wont compile on | ||
9 | newer musl systems. Therefore only use it on 32bit glibc/linux platforms | ||
10 | and exclude musl like cygwin or OSX | ||
11 | |||
12 | [1] https://git.musl-libc.org/cgit/musl/commit/?id=246f1c811448f37a44b41cd8df8d0ef9736d95f4 | ||
13 | |||
14 | Upstream-Status: Submitted [https://github.com/gabime/spdlog/pull/2589] | ||
15 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
16 | --- | ||
17 | thirdparty/spdlog-20170710/include/spdlog/details/os.h | 2 +- | ||
18 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
19 | |||
20 | diff --git a/thirdparty/spdlog-20170710/include/spdlog/details/os.h b/thirdparty/spdlog-20170710/include/spdlog/details/os.h | ||
21 | index 735f60147..639b07a79 100644 | ||
22 | --- a/thirdparty/spdlog-20170710/include/spdlog/details/os.h | ||
23 | +++ b/thirdparty/spdlog-20170710/include/spdlog/details/os.h | ||
24 | @@ -237,7 +237,7 @@ inline size_t filesize(FILE *f) | ||
25 | #else // unix | ||
26 | int fd = fileno(f); | ||
27 | //64 bits(but not in osx, where fstat64 is deprecated) | ||
28 | -#if !defined(__FreeBSD__) && !defined(__APPLE__) && (defined(__x86_64__) || defined(__ppc64__)) | ||
29 | +#if !defined(__FreeBSD__) && !defined(__APPLE__) && ((defined(__x86_64__) || defined(__ppc64__)) && (!defined(__linux__))) | ||
30 | struct stat64 st; | ||
31 | if (fstat64(fd, &st) == 0) | ||
32 | return static_cast<size_t>(st.st_size); | ||
33 | -- | ||
34 | 2.40.0 | ||
35 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-Do-not-use-bundled-packages.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-Do-not-use-bundled-packages.patch new file mode 100644 index 000000000..b997d6ce7 --- /dev/null +++ b/meta-oe/recipes-extended/minifi-cpp/files/0001-Do-not-use-bundled-packages.patch | |||
@@ -0,0 +1,108 @@ | |||
1 | From 65923a872e44cb461ef1a03374057351f0bc5efe Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Tue, 19 Mar 2024 19:39:04 +0800 | ||
4 | Subject: [PATCH] Do not use bundled packages | ||
5 | |||
6 | Use external dependencies for openssl, curl, bzip2, zlib, libarchive, | ||
7 | xz, yaml-cpp and libxml2. | ||
8 | |||
9 | Upstream-Status: Inappropriate [embedded specific] | ||
10 | |||
11 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
12 | --- | ||
13 | CMakeLists.txt | 23 ++++++----------------- | ||
14 | extensions/libarchive/CMakeLists.txt | 7 ++----- | ||
15 | 2 files changed, 8 insertions(+), 22 deletions(-) | ||
16 | |||
17 | diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
18 | index 13a2b992..8a1dd6d9 100644 | ||
19 | --- a/CMakeLists.txt | ||
20 | +++ b/CMakeLists.txt | ||
21 | @@ -222,9 +222,7 @@ else() | ||
22 | endif() | ||
23 | |||
24 | if (NOT DISABLE_BZIP2 AND (NOT DISABLE_LIBARCHIVE OR (NOT DISABLE_ROCKSDB AND NOT WIN32))) | ||
25 | - include(BundledBZip2) | ||
26 | - use_bundled_bzip2(${CMAKE_SOURCE_DIR} ${CMAKE_BINARY_DIR}) | ||
27 | - list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/bzip2/dummy") | ||
28 | + find_package(BZip2 REQUIRED) | ||
29 | endif() | ||
30 | |||
31 | if(NOT WIN32) | ||
32 | @@ -247,9 +245,7 @@ endif() | ||
33 | |||
34 | # OpenSSL | ||
35 | if (NOT OPENSSL_OFF) | ||
36 | - include(BundledOpenSSL) | ||
37 | - use_openssl("${CMAKE_CURRENT_SOURCE_DIR}" "${CMAKE_CURRENT_BINARY_DIR}") | ||
38 | - list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/ssl") | ||
39 | + find_package(OpenSSL REQUIRED) | ||
40 | |||
41 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DOPENSSL_SUPPORT") | ||
42 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DOPENSSL_SUPPORT") | ||
43 | @@ -262,9 +258,7 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DSODIUM_STATIC=1") | ||
44 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DSODIUM_STATIC=1") | ||
45 | |||
46 | # zlib | ||
47 | -include(BundledZLIB) | ||
48 | -use_bundled_zlib(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR}) | ||
49 | -list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/zlib/dummy") | ||
50 | +find_package(ZLIB REQUIRED) | ||
51 | |||
52 | # uthash | ||
53 | add_library(ut INTERFACE) | ||
54 | @@ -272,9 +266,7 @@ target_include_directories(ut SYSTEM INTERFACE "${CMAKE_CURRENT_SOURCE_DIR}/thir | ||
55 | |||
56 | # cURL | ||
57 | if(NOT DISABLE_CURL) | ||
58 | - include(BundledLibcURL) | ||
59 | - use_bundled_curl(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR}) | ||
60 | - list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/curl/dummy") | ||
61 | + find_package(CURL REQUIRED) | ||
62 | else() | ||
63 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DDISABLE_CURL") | ||
64 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DDISABLE_CURL") | ||
65 | @@ -285,8 +277,7 @@ include(BundledSpdlog) | ||
66 | use_bundled_spdlog(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR}) | ||
67 | |||
68 | # yaml-cpp | ||
69 | -include(BundledYamlCpp) | ||
70 | -use_bundled_yamlcpp(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR}) | ||
71 | +find_package(yaml-cpp REQUIRED) | ||
72 | |||
73 | # concurrentqueue | ||
74 | add_library(concurrentqueue INTERFACE) | ||
75 | @@ -357,9 +348,7 @@ include(Extensions) | ||
76 | add_subdirectory(libminifi) | ||
77 | |||
78 | if ((ENABLE_OPENWSMAN AND NOT DISABLE_CIVET AND NOT DISABLE_CURL) OR ENABLE_ALL OR ENABLE_AZURE) | ||
79 | - include(BundledLibXml2) | ||
80 | - use_bundled_libxml2(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR}) | ||
81 | - list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/libxml2/dummy") | ||
82 | + find_package(LibXml2 REQUIRED) | ||
83 | endif() | ||
84 | |||
85 | if (ENABLE_ALL OR ENABLE_PROMETHEUS OR NOT DISABLE_CIVET) | ||
86 | diff --git a/extensions/libarchive/CMakeLists.txt b/extensions/libarchive/CMakeLists.txt | ||
87 | index 2b89d3ea..49e13e21 100644 | ||
88 | --- a/extensions/libarchive/CMakeLists.txt | ||
89 | +++ b/extensions/libarchive/CMakeLists.txt | ||
90 | @@ -22,13 +22,10 @@ if (DISABLE_LIBARCHIVE) | ||
91 | endif() | ||
92 | |||
93 | if (NOT DISABLE_LZMA) | ||
94 | - include(BundledLibLZMA) | ||
95 | - use_bundled_liblzma(${CMAKE_SOURCE_DIR} ${CMAKE_BINARY_DIR}) | ||
96 | - list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/liblzma/dummy") | ||
97 | + find_package(LibLZMA REQUIRED) | ||
98 | endif() | ||
99 | |||
100 | -include(BundledLibArchive) | ||
101 | -use_bundled_libarchive(${CMAKE_SOURCE_DIR} ${CMAKE_BINARY_DIR}) | ||
102 | +find_package(LibArchive REQUIRED) | ||
103 | |||
104 | include(${CMAKE_SOURCE_DIR}/extensions/ExtensionHeader.txt) | ||
105 | |||
106 | -- | ||
107 | 2.25.1 | ||
108 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-Fix-build-with-libc.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-Fix-build-with-libc.patch deleted file mode 100644 index c1c118196..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-Fix-build-with-libc.patch +++ /dev/null | |||
@@ -1,36 +0,0 @@ | |||
1 | From 72e0fe484444169007e481c9b33d8f78ebe03674 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Thu, 27 May 2021 15:44:10 -0700 | ||
4 | Subject: [PATCH] Fix build with libc++ | ||
5 | |||
6 | In libc++ on 32-bit platforms, int64_t is defined as alias of long long. On 64-bit platforms: long. | ||
7 | |||
8 | On the other hand in definition of std::chrono::duration aliases, that you can find here long long is used | ||
9 | |||
10 | Therefore create custom unit to avoid incompatibility between libstdc++ | ||
11 | and libc++ | ||
12 | |||
13 | Upstream-Status: Pending | ||
14 | |||
15 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
16 | --- | ||
17 | extensions/expression-language/Expression.cpp | 3 ++- | ||
18 | 1 file changed, 2 insertions(+), 1 deletion(-) | ||
19 | |||
20 | diff --git a/extensions/expression-language/Expression.cpp b/extensions/expression-language/Expression.cpp | ||
21 | index a25e1d3f..68d6320c 100644 | ||
22 | --- a/extensions/expression-language/Expression.cpp | ||
23 | +++ b/extensions/expression-language/Expression.cpp | ||
24 | @@ -629,7 +629,8 @@ Value expr_toDate(const std::vector<Value> &args) { | ||
25 | #endif // EXPRESSION_LANGUAGE_USE_DATE | ||
26 | |||
27 | Value expr_now(const std::vector<Value> &args) { | ||
28 | - return Value(std::chrono::duration_cast<std::chrono::milliseconds>(std::chrono::system_clock::now().time_since_epoch()).count()); | ||
29 | + using Milliseconds = std::chrono::duration<std::int64_t, std::chrono::milliseconds::period>; | ||
30 | + return Value(std::chrono::duration_cast<Milliseconds>(std::chrono::system_clock::now().time_since_epoch()).count()); | ||
31 | } | ||
32 | |||
33 | Value expr_unescapeCsv(const std::vector<Value> &args) { | ||
34 | -- | ||
35 | 2.31.1 | ||
36 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-Fix-the-constness-issues-around-autovector-iterator_.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-Fix-the-constness-issues-around-autovector-iterator_.patch deleted file mode 100644 index cd837d8de..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-Fix-the-constness-issues-around-autovector-iterator_.patch +++ /dev/null | |||
@@ -1,65 +0,0 @@ | |||
1 | From 787d5052a6034cc722b073c652cc610ae037f933 Mon Sep 17 00:00:00 2001 | ||
2 | From: Levi Tamasi <ltamasi@fb.com> | ||
3 | Date: Fri, 22 Nov 2019 18:12:35 -0800 | ||
4 | Subject: [PATCH 1/2] Fix the constness issues around | ||
5 | autovector::iterator_impl's dereference operators (#6057) | ||
6 | |||
7 | Summary: | ||
8 | As described in detail in issue https://github.com/facebook/rocksdb/issues/6048, iterators' dereference operators | ||
9 | (`*`, `->`, and `[]`) should return `pointer`s/`reference`s (as opposed to | ||
10 | `const_pointer`s/`const_reference`s) even if the iterator itself is `const` | ||
11 | to be in sync with the standard's iterator concept. | ||
12 | Pull Request resolved: https://github.com/facebook/rocksdb/pull/6057 | ||
13 | |||
14 | Test Plan: make check | ||
15 | |||
16 | Differential Revision: D18623235 | ||
17 | |||
18 | Pulled By: ltamasi | ||
19 | |||
20 | fbshipit-source-id: 04e82d73bc0c67fb0ded018383af8dfc332050cc | ||
21 | --- | ||
22 | Upstream-Status: Pending | ||
23 | |||
24 | thirdparty/rocksdb/util/autovector.h | 15 ++++----------- | ||
25 | 1 file changed, 4 insertions(+), 11 deletions(-) | ||
26 | |||
27 | diff --git a/thirdparty/rocksdb/util/autovector.h b/thirdparty/rocksdb/util/autovector.h | ||
28 | index b5c84712..6d337908 100644 | ||
29 | --- a/thirdparty/rocksdb/util/autovector.h | ||
30 | +++ b/thirdparty/rocksdb/util/autovector.h | ||
31 | @@ -120,27 +120,20 @@ class autovector { | ||
32 | } | ||
33 | |||
34 | // -- Reference | ||
35 | - reference operator*() { | ||
36 | + reference operator*() const { | ||
37 | assert(vect_->size() >= index_); | ||
38 | return (*vect_)[index_]; | ||
39 | } | ||
40 | |||
41 | - const_reference operator*() const { | ||
42 | - assert(vect_->size() >= index_); | ||
43 | - return (*vect_)[index_]; | ||
44 | - } | ||
45 | - | ||
46 | - pointer operator->() { | ||
47 | + pointer operator->() const { | ||
48 | assert(vect_->size() >= index_); | ||
49 | return &(*vect_)[index_]; | ||
50 | } | ||
51 | |||
52 | - const_pointer operator->() const { | ||
53 | - assert(vect_->size() >= index_); | ||
54 | - return &(*vect_)[index_]; | ||
55 | + reference operator[](difference_type len) const { | ||
56 | + return *(*this + len); | ||
57 | } | ||
58 | |||
59 | - | ||
60 | // -- Logical Operators | ||
61 | bool operator==(const self_type& other) const { | ||
62 | assert(vect_ == other.vect_); | ||
63 | -- | ||
64 | 2.41.0 | ||
65 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-civetweb-CMakeLists.txt-do-not-search-gcc-ar-and-gcc.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-civetweb-CMakeLists.txt-do-not-search-gcc-ar-and-gcc.patch deleted file mode 100644 index bc480d969..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-civetweb-CMakeLists.txt-do-not-search-gcc-ar-and-gcc.patch +++ /dev/null | |||
@@ -1,34 +0,0 @@ | |||
1 | From 0eee3fb85dad084b6b42f7b219d8aa3a62620a27 Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Wed, 28 Oct 2020 09:52:40 +0800 | ||
4 | Subject: [PATCH] civetweb/CMakeLists.txt: do not search gcc-ar and gcc-ranlib | ||
5 | |||
6 | Do not search gcc-ar and gcc-ranlib. Specify GCC_AR and GCC_RANLIB in | ||
7 | EXTRA_OECMAKE to avoid host contamination. | ||
8 | |||
9 | Upstream-Status: Inappropriate [embedded specific] | ||
10 | |||
11 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
12 | --- | ||
13 | thirdparty/civetweb-1.10/CMakeLists.txt | 2 -- | ||
14 | 1 file changed, 2 deletions(-) | ||
15 | |||
16 | diff --git a/thirdparty/civetweb-1.10/CMakeLists.txt b/thirdparty/civetweb-1.10/CMakeLists.txt | ||
17 | index f559a04e..0689e3f6 100644 | ||
18 | --- a/thirdparty/civetweb-1.10/CMakeLists.txt | ||
19 | +++ b/thirdparty/civetweb-1.10/CMakeLists.txt | ||
20 | @@ -246,11 +246,9 @@ set_property(CACHE CIVETWEB_CXX_STANDARD PROPERTY STRINGS auto c++14 c++11 c++98 | ||
21 | |||
22 | # Configure the linker | ||
23 | if ("${CMAKE_C_COMPILER_ID}" STREQUAL "GNU") | ||
24 | - find_program(GCC_AR gcc-ar) | ||
25 | if (GCC_AR) | ||
26 | set(CMAKE_AR ${GCC_AR}) | ||
27 | endif() | ||
28 | - find_program(GCC_RANLIB gcc-ranlib) | ||
29 | if (GCC_RANLIB) | ||
30 | set(CMAKE_RANLIB ${GCC_RANLIB}) | ||
31 | endif() | ||
32 | -- | ||
33 | 2.17.1 | ||
34 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-civetweb-Disable-lto.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-civetweb-Disable-lto.patch deleted file mode 100644 index ec4e6ffc4..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-civetweb-Disable-lto.patch +++ /dev/null | |||
@@ -1,33 +0,0 @@ | |||
1 | From 120c708d51f72ade4a31d3d8f35bcfad7b12e723 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Tue, 6 Sep 2022 20:38:03 -0700 | ||
4 | Subject: [PATCH] civetweb: Disable lto | ||
5 | |||
6 | lto does not work everywhere, therefore disable it atleast in the cmake | ||
7 | file, we can still enable it via environment | ||
8 | |||
9 | Upstream-Status: Pending | ||
10 | |||
11 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
12 | --- | ||
13 | thirdparty/civetweb-1.10/CMakeLists.txt | 4 ---- | ||
14 | 1 file changed, 4 deletions(-) | ||
15 | |||
16 | --- a/thirdparty/civetweb-1.10/CMakeLists.txt | ||
17 | +++ b/thirdparty/civetweb-1.10/CMakeLists.txt | ||
18 | @@ -298,7 +298,6 @@ add_c_compiler_flag(/WX) | ||
19 | add_c_compiler_flag(-pedantic-errors) | ||
20 | add_c_compiler_flag(-fvisibility=hidden) | ||
21 | add_c_compiler_flag(-fstack-protector-strong RELEASE) | ||
22 | -add_c_compiler_flag(-flto RELEASE) | ||
23 | |||
24 | add_c_compiler_flag(-fstack-protector-all DEBUG) | ||
25 | if (MINGW) | ||
26 | @@ -361,7 +360,6 @@ if (CIVETWEB_ENABLE_CXX) | ||
27 | add_cxx_compiler_flag(-pedantic-errors) | ||
28 | add_cxx_compiler_flag(-fvisibility=hidden) | ||
29 | add_cxx_compiler_flag(-fstack-protector-strong RELEASE) | ||
30 | - add_cxx_compiler_flag(-flto RELEASE) | ||
31 | |||
32 | add_cxx_compiler_flag(-fstack-protector-all DEBUG) | ||
33 | if (MINGW) | ||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-config.guess-Support-build-on-aarch64.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-config.guess-Support-build-on-aarch64.patch deleted file mode 100644 index 3086a7045..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-config.guess-Support-build-on-aarch64.patch +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | From 92fdbfdd6b55ff0b65edd9a283ac85ad349e325b Mon Sep 17 00:00:00 2001 | ||
2 | From: Robert Yang <liezhi.yang@windriver.com> | ||
3 | Date: Tue, 12 Dec 2023 07:27:52 +0000 | ||
4 | Subject: [PATCH] config.guess: Fix do_configure error builder aarch64 | ||
5 | |||
6 | Fixed configure error when build on aarch64 host: | ||
7 | error: cannot guess build type; you must specify one | ||
8 | |||
9 | Upstream-Status: Pending | ||
10 | |||
11 | Signed-off-by: Robert Yang <liezhi.yang@windriver.com> | ||
12 | --- | ||
13 | config.guess | 2 +- | ||
14 | 1 files changed, 1 insertion(+), 1 deletion(-) | ||
15 | |||
16 | diff --git a/thirdparty/uuid-1.6.2/config.guess b/thirdparty/uuid-1.6.2/config.guess | ||
17 | index ca2a03c..a858bfd 100755 | ||
18 | --- a/thirdparty/uuid-1.6.2/config.guess | ||
19 | +++ b/thirdparty/uuid-1.6.2/config.guess | ||
20 | @@ -835,7 +835,7 @@ EOF | ||
21 | i*86:Minix:*:*) | ||
22 | echo ${UNAME_MACHINE}-pc-minix | ||
23 | exit ;; | ||
24 | - arm*:Linux:*:*) | ||
25 | + arm*:Linux:*:*|aarch64:Linux:*:*) | ||
26 | eval $set_cc_for_build | ||
27 | if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | ||
28 | | grep -q __ARM_EABI__ | ||
29 | -- | ||
30 | 2.34.1 | ||
31 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0001-cxxopts-Add-limits-header.patch b/meta-oe/recipes-extended/minifi-cpp/files/0001-cxxopts-Add-limits-header.patch deleted file mode 100644 index ef26c475d..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0001-cxxopts-Add-limits-header.patch +++ /dev/null | |||
@@ -1,34 +0,0 @@ | |||
1 | From fda0713ce3e07786757a057abe7ebf2146d33780 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Tue, 2 Mar 2021 18:31:45 -0800 | ||
4 | Subject: [PATCH] cxxopts: Add limits header | ||
5 | |||
6 | needed for numeric_limits | ||
7 | |||
8 | Upstream-Status: Submitted [https://github.com/apache/nifi-minifi-cpp/pull/1021] | ||
9 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
10 | --- | ||
11 | thirdparty/cxxopts/include/cxxopts.hpp | 1 + | ||
12 | 1 file changed, 1 insertion(+) | ||
13 | |||
14 | --- a/thirdparty/cxxopts/include/cxxopts.hpp | ||
15 | +++ b/thirdparty/cxxopts/include/cxxopts.hpp | ||
16 | @@ -29,6 +29,7 @@ THE SOFTWARE. | ||
17 | #include <cctype> | ||
18 | #include <exception> | ||
19 | #include <iostream> | ||
20 | +#include <limits> | ||
21 | #include <map> | ||
22 | #include <memory> | ||
23 | #include <regex> | ||
24 | --- a/libminifi/src/utils/StringUtils.cpp | ||
25 | +++ b/libminifi/src/utils/StringUtils.cpp | ||
26 | @@ -21,6 +21,8 @@ | ||
27 | #include <Windows.h> | ||
28 | #endif | ||
29 | |||
30 | +#include <limits> | ||
31 | + | ||
32 | namespace org { | ||
33 | namespace apache { | ||
34 | namespace nifi { | ||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0002-Fix-build-with-clang-17.patch b/meta-oe/recipes-extended/minifi-cpp/files/0002-Fix-build-with-clang-17.patch deleted file mode 100644 index 7581efc76..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0002-Fix-build-with-clang-17.patch +++ /dev/null | |||
@@ -1,37 +0,0 @@ | |||
1 | From a784973e500753747992a51dc0fb1caabbbb03be Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Thu, 6 Jul 2023 17:52:38 -0700 | ||
4 | Subject: [PATCH 2/2] Fix build with clang 17 | ||
5 | |||
6 | Part of https://github.com/jarro2783/cxxopts/commit/513afbc6dcfe2952cb2ffab0dae2415b11bba2d0 | ||
7 | |||
8 | Upstream-Status: Backport [https://github.com/jarro2783/cxxopts/commit/513afbc6dcfe2952cb2ffab0dae2415b11bba2d0] | ||
9 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
10 | --- | ||
11 | thirdparty/cxxopts/include/cxxopts.hpp | 4 ++-- | ||
12 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
13 | |||
14 | diff --git a/thirdparty/cxxopts/include/cxxopts.hpp b/thirdparty/cxxopts/include/cxxopts.hpp | ||
15 | index e87416f1..bd2d81cf 100644 | ||
16 | --- a/thirdparty/cxxopts/include/cxxopts.hpp | ||
17 | +++ b/thirdparty/cxxopts/include/cxxopts.hpp | ||
18 | @@ -468,14 +468,14 @@ namespace cxxopts | ||
19 | { | ||
20 | if (negative) | ||
21 | { | ||
22 | - if (u > static_cast<U>(-std::numeric_limits<T>::min())) | ||
23 | + if (u > static_cast<U>((std::numeric_limits<T>::min)())) | ||
24 | { | ||
25 | throw argument_incorrect_type(text); | ||
26 | } | ||
27 | } | ||
28 | else | ||
29 | { | ||
30 | - if (u > static_cast<U>(std::numeric_limits<T>::max())) | ||
31 | + if (u > static_cast<U>((std::numeric_limits<T>::max)())) | ||
32 | { | ||
33 | throw argument_incorrect_type(text); | ||
34 | } | ||
35 | -- | ||
36 | 2.41.0 | ||
37 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0002-Fix-osspuuid-build.patch b/meta-oe/recipes-extended/minifi-cpp/files/0002-Fix-osspuuid-build.patch new file mode 100644 index 000000000..65c52c633 --- /dev/null +++ b/meta-oe/recipes-extended/minifi-cpp/files/0002-Fix-osspuuid-build.patch | |||
@@ -0,0 +1,78 @@ | |||
1 | From 4e8e1943541d3b887ba86dc1b488cbb058c7d1cd Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Tue, 19 Mar 2024 20:48:25 +0800 | ||
4 | Subject: [PATCH] Fix osspuuid build | ||
5 | |||
6 | * Specify correct configure options to fix osspuuid cross build. | ||
7 | * Do not download osspuuid source during compile. | ||
8 | |||
9 | Upstream-Status: Inappropriate [embedded specific] | ||
10 | |||
11 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
12 | --- | ||
13 | cmake/BundledOSSPUUID.cmake | 10 +++++----- | ||
14 | .../ossp-uuid/ossp-uuid-cross-compile-fix.patch | 13 +++++++++++++ | ||
15 | 2 files changed, 18 insertions(+), 5 deletions(-) | ||
16 | create mode 100644 thirdparty/ossp-uuid/ossp-uuid-cross-compile-fix.patch | ||
17 | |||
18 | diff --git a/cmake/BundledOSSPUUID.cmake b/cmake/BundledOSSPUUID.cmake | ||
19 | index c4fa1523..1faf2e5c 100644 | ||
20 | --- a/cmake/BundledOSSPUUID.cmake | ||
21 | +++ b/cmake/BundledOSSPUUID.cmake | ||
22 | @@ -23,10 +23,12 @@ function(use_bundled_osspuuid SOURCE_DIR BINARY_DIR) | ||
23 | set(PATCH_FILE1 "${SOURCE_DIR}/thirdparty/ossp-uuid/ossp-uuid-mac-fix.patch") | ||
24 | set(PATCH_FILE2 "${SOURCE_DIR}/thirdparty/ossp-uuid/ossp-uuid-no-prog.patch") | ||
25 | set(PATCH_FILE3 "${SOURCE_DIR}/thirdparty/ossp-uuid/ossp-uuid-update-config-guess.patch") | ||
26 | + set(PATCH_FILE4 "${SOURCE_DIR}/thirdparty/ossp-uuid/ossp-uuid-cross-compile-fix.patch") | ||
27 | set(PC ${Bash_EXECUTABLE} -c "set -x &&\ | ||
28 | (\"${Patch_EXECUTABLE}\" -p1 -R -s -f --dry-run -i \"${PATCH_FILE1}\" || \"${Patch_EXECUTABLE}\" -p1 -N -i \"${PATCH_FILE1}\") &&\ | ||
29 | (\"${Patch_EXECUTABLE}\" -p1 -R -s -f --dry-run -i \"${PATCH_FILE2}\" || \"${Patch_EXECUTABLE}\" -p1 -N -i \"${PATCH_FILE2}\") &&\ | ||
30 | - (\"${Patch_EXECUTABLE}\" -p1 -R -s -f --dry-run -i \"${PATCH_FILE3}\" || \"${Patch_EXECUTABLE}\" -p1 -N -i \"${PATCH_FILE3}\") ") | ||
31 | + (\"${Patch_EXECUTABLE}\" -p1 -R -s -f --dry-run -i \"${PATCH_FILE3}\" || \"${Patch_EXECUTABLE}\" -p1 -N -i \"${PATCH_FILE3}\") &&\ | ||
32 | + (\"${Patch_EXECUTABLE}\" -p1 -R -s -f --dry-run -i \"${PATCH_FILE4}\" || \"${Patch_EXECUTABLE}\" -p1 -N -i \"${PATCH_FILE4}\") ") | ||
33 | |||
34 | # Define byproducts | ||
35 | set(BYPRODUCTS "lib/libuuid.a" | ||
36 | @@ -39,7 +41,7 @@ function(use_bundled_osspuuid SOURCE_DIR BINARY_DIR) | ||
37 | ENDFOREACH(BYPRODUCT) | ||
38 | |||
39 | # Build project | ||
40 | - set(CONFIGURE_COMMAND ./configure "CC=${CMAKE_C_COMPILER}" "CXX=${CMAKE_CXX_COMPILER}" "CFLAGS=${PASSTHROUGH_CMAKE_C_FLAGS} -fPIC" "CXXFLAGS=${PASSTHROUGH_CMAKE_CXX_FLAGS} -fPIC" --enable-shared=no --with-cxx --without-perl --without-php --without-pgsql "--prefix=${BINARY_DIR}/thirdparty/ossp-uuid-install") | ||
41 | + set(CONFIGURE_COMMAND ac_cv_va_copy=C99 ./configure --host=${HOST_SYS} --build=${BUILD_SYS} "CC=${CMAKE_C_COMPILER}" "CXX=${CMAKE_CXX_COMPILER}" "CFLAGS=${PASSTHROUGH_CMAKE_C_FLAGS} -fPIC" "CXXFLAGS=${PASSTHROUGH_CMAKE_CXX_FLAGS} -fPIC" --enable-shared=no --with-cxx --without-perl --without-php --without-pgsql "--prefix=${BINARY_DIR}/thirdparty/ossp-uuid-install") | ||
42 | string(TOLOWER "${CMAKE_BUILD_TYPE}" build_type) | ||
43 | if(NOT build_type MATCHES debug) | ||
44 | list(APPEND CONFIGURE_COMMAND --enable-debug=yes) | ||
45 | @@ -47,10 +49,8 @@ function(use_bundled_osspuuid SOURCE_DIR BINARY_DIR) | ||
46 | |||
47 | ExternalProject_Add( | ||
48 | ossp-uuid-external | ||
49 | - URL "https://deb.debian.org/debian/pool/main/o/ossp-uuid/ossp-uuid_1.6.2.orig.tar.gz" | ||
50 | - URL_HASH "SHA256=11a615225baa5f8bb686824423f50e4427acd3f70d394765bdff32801f0fd5b0" | ||
51 | BUILD_IN_SOURCE true | ||
52 | - SOURCE_DIR "${BINARY_DIR}/thirdparty/ossp-uuid-src" | ||
53 | + SOURCE_DIR "${SOURCE_DIR}/thirdparty/uuid-1.6.2" | ||
54 | BUILD_COMMAND make | ||
55 | CMAKE_COMMAND "" | ||
56 | UPDATE_COMMAND "" | ||
57 | diff --git a/thirdparty/ossp-uuid/ossp-uuid-cross-compile-fix.patch b/thirdparty/ossp-uuid/ossp-uuid-cross-compile-fix.patch | ||
58 | new file mode 100644 | ||
59 | index 00000000..b8d7b0bb | ||
60 | --- /dev/null | ||
61 | +++ b/thirdparty/ossp-uuid/ossp-uuid-cross-compile-fix.patch | ||
62 | @@ -0,0 +1,13 @@ | ||
63 | +diff --git a/shtool b/shtool | ||
64 | +index a2d2567..ab4fe17 100755 | ||
65 | +--- a/shtool | ||
66 | ++++ b/shtool | ||
67 | +@@ -1400,7 +1400,7 @@ install ) | ||
68 | + if [ ".$opt_t" = .yes ]; then | ||
69 | + echo "strip $dsttmp" 1>&2 | ||
70 | + fi | ||
71 | +- strip $dsttmp || shtool_exit $? | ||
72 | ++ $STRIP $dsttmp || shtool_exit $? | ||
73 | + fi | ||
74 | + if [ ".$opt_o" != . ]; then | ||
75 | + if [ ".$opt_t" = .yes ]; then | ||
76 | -- | ||
77 | 2.25.1 | ||
78 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0002-cmake-LibreSSL.cmake-use-libressl-local-source-tarba.patch b/meta-oe/recipes-extended/minifi-cpp/files/0002-cmake-LibreSSL.cmake-use-libressl-local-source-tarba.patch deleted file mode 100644 index da5ee9754..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0002-cmake-LibreSSL.cmake-use-libressl-local-source-tarba.patch +++ /dev/null | |||
@@ -1,32 +0,0 @@ | |||
1 | From 5a5317044b0039e9e19aabcecb7b666a3f13e136 Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Thu, 10 Sep 2020 15:08:19 +0800 | ||
4 | Subject: [PATCH] cmake/LibreSSL.cmake: use libressl local source tarball | ||
5 | |||
6 | Do not download libressl source during compile. | ||
7 | |||
8 | Upstream-Status: Inappropriate [embedded specific] | ||
9 | |||
10 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
11 | --- | ||
12 | cmake/LibreSSL.cmake | 4 +--- | ||
13 | 1 file changed, 1 insertion(+), 3 deletions(-) | ||
14 | |||
15 | diff --git a/cmake/LibreSSL.cmake b/cmake/LibreSSL.cmake | ||
16 | index 57319e40..bab30129 100644 | ||
17 | --- a/cmake/LibreSSL.cmake | ||
18 | +++ b/cmake/LibreSSL.cmake | ||
19 | @@ -43,9 +43,7 @@ function(use_libre_ssl SOURCE_DIR BINARY_DIR) | ||
20 | |||
21 | ExternalProject_Add( | ||
22 | libressl-portable | ||
23 | - URL https://cdn.openbsd.org/pub/OpenBSD/LibreSSL/libressl-2.8.3.tar.gz https://ftp.openbsd.org/pub/OpenBSD/LibreSSL/libressl-2.8.3.tar.gz https://gentoo.osuosl.org/distfiles/libressl-2.8.3.tar.gz | ||
24 | - URL_HASH "SHA256=9b640b13047182761a99ce3e4f000be9687566e0828b4a72709e9e6a3ef98477" | ||
25 | - SOURCE_DIR "${BINARY_DIR}/thirdparty/libressl-src" | ||
26 | + SOURCE_DIR "${SOURCE_DIR}/thirdparty/libressl-2.8.3" | ||
27 | PATCH_COMMAND ${PATCH} | ||
28 | CMAKE_ARGS ${PASSTHROUGH_CMAKE_ARGS} | ||
29 | "-DCMAKE_INSTALL_PREFIX=${BINARY_DIR}/thirdparty/libressl-install" | ||
30 | -- | ||
31 | 2.17.1 | ||
32 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0003-Fix-libsodium-build.patch b/meta-oe/recipes-extended/minifi-cpp/files/0003-Fix-libsodium-build.patch new file mode 100644 index 000000000..a08962724 --- /dev/null +++ b/meta-oe/recipes-extended/minifi-cpp/files/0003-Fix-libsodium-build.patch | |||
@@ -0,0 +1,39 @@ | |||
1 | From 1c697e4d75f0045d5364d622960ff8047a4ad3ec Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Tue, 19 Mar 2024 20:56:05 +0800 | ||
4 | Subject: [PATCH] Fix libsodium build | ||
5 | |||
6 | * Specify correct configure options to fix libsodium cross build. | ||
7 | * Do not download libsodium source during compile. | ||
8 | |||
9 | Upstream-Status: Inappropriate [embedded specific] | ||
10 | |||
11 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
12 | --- | ||
13 | cmake/BundledLibSodium.cmake | 6 ++---- | ||
14 | 1 file changed, 2 insertions(+), 4 deletions(-) | ||
15 | |||
16 | diff --git a/cmake/BundledLibSodium.cmake b/cmake/BundledLibSodium.cmake | ||
17 | index 3a3daf41..d851f753 100644 | ||
18 | --- a/cmake/BundledLibSodium.cmake | ||
19 | +++ b/cmake/BundledLibSodium.cmake | ||
20 | @@ -58,14 +58,12 @@ function(use_bundled_libsodium SOURCE_DIR BINARY_DIR) | ||
21 | EXCLUDE_FROM_ALL TRUE | ||
22 | ) | ||
23 | else() | ||
24 | - set(CONFIGURE_COMMAND ./configure --disable-pie --enable-minimal "--prefix=${LIBSODIUM_BIN_DIR}") | ||
25 | + set(CONFIGURE_COMMAND ./configure --host=${HOST_SYS} --build=${BUILD_SYS} --disable-pie --enable-minimal "--prefix=${LIBSODIUM_BIN_DIR}") | ||
26 | |||
27 | ExternalProject_Add( | ||
28 | libsodium-external | ||
29 | - URL "${LIBSODIUM_OFFICIAL_MIRROR_URL} ${LIBSODIUM_GITHUB_MIRROR_URL} ${LIBSODIUM_GENTOO_MIRROR_URL}" | ||
30 | - URL_HASH ${LIBSODIUM_URL_HASH} | ||
31 | BUILD_IN_SOURCE true | ||
32 | - SOURCE_DIR "${BINARY_DIR}/thirdparty/libsodium-src" | ||
33 | + SOURCE_DIR "${SOURCE_DIR}/thirdparty/libsodium-stable" | ||
34 | BUILD_COMMAND make | ||
35 | CMAKE_COMMAND "" | ||
36 | UPDATE_COMMAND "" | ||
37 | -- | ||
38 | 2.25.1 | ||
39 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0003-cmake-BundledOSSPUUID.cmake-use-ossp-uuid-local-sour.patch b/meta-oe/recipes-extended/minifi-cpp/files/0003-cmake-BundledOSSPUUID.cmake-use-ossp-uuid-local-sour.patch deleted file mode 100644 index a39e15b79..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/0003-cmake-BundledOSSPUUID.cmake-use-ossp-uuid-local-sour.patch +++ /dev/null | |||
@@ -1,34 +0,0 @@ | |||
1 | From 74ade26f7ccd0dbc4ad97cb3082204118a67c92b Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Thu, 10 Sep 2020 15:12:41 +0800 | ||
4 | Subject: [PATCH] cmake/BundledOSSPUUID.cmake: use ossp-uuid local source | ||
5 | tarball | ||
6 | |||
7 | Do not download ossp-uuid source during compile. | ||
8 | |||
9 | Upstream-Status: Inappropriate [embedded specific] | ||
10 | |||
11 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
12 | --- | ||
13 | cmake/BundledOSSPUUID.cmake | 4 +--- | ||
14 | 1 file changed, 1 insertion(+), 3 deletions(-) | ||
15 | |||
16 | diff --git a/cmake/BundledOSSPUUID.cmake b/cmake/BundledOSSPUUID.cmake | ||
17 | index 1103156d..0cf4bac0 100644 | ||
18 | --- a/cmake/BundledOSSPUUID.cmake | ||
19 | +++ b/cmake/BundledOSSPUUID.cmake | ||
20 | @@ -47,10 +47,8 @@ function(use_bundled_osspuuid SOURCE_DIR BINARY_DIR) | ||
21 | |||
22 | ExternalProject_Add( | ||
23 | ossp-uuid-external | ||
24 | - URL "https://deb.debian.org/debian/pool/main/o/ossp-uuid/ossp-uuid_1.6.2.orig.tar.gz" | ||
25 | - URL_HASH "SHA256=11a615225baa5f8bb686824423f50e4427acd3f70d394765bdff32801f0fd5b0" | ||
26 | BUILD_IN_SOURCE true | ||
27 | - SOURCE_DIR "${BINARY_DIR}/thirdparty/ossp-uuid-src" | ||
28 | + SOURCE_DIR "${SOURCE_DIR}/thirdparty/uuid-1.6.2" | ||
29 | BUILD_COMMAND make | ||
30 | CMAKE_COMMAND "" | ||
31 | UPDATE_COMMAND "" | ||
32 | -- | ||
33 | 2.17.1 | ||
34 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0004-Fix-spdlog-build.patch b/meta-oe/recipes-extended/minifi-cpp/files/0004-Fix-spdlog-build.patch new file mode 100644 index 000000000..177c6adee --- /dev/null +++ b/meta-oe/recipes-extended/minifi-cpp/files/0004-Fix-spdlog-build.patch | |||
@@ -0,0 +1,44 @@ | |||
1 | From 8a5fe73f722718aa5c9a467c28a26913771f7208 Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Tue, 19 Mar 2024 20:57:37 +0800 | ||
4 | Subject: [PATCH] Fix spdlog build | ||
5 | |||
6 | * Specify CMAKE_INSTALL_LIBDIR to fix multilib build. | ||
7 | * Do not download spdlog source during compile. | ||
8 | |||
9 | Upstream-Status: Inappropriate [embedded specific] | ||
10 | |||
11 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
12 | --- | ||
13 | cmake/BundledSpdlog.cmake | 4 ++-- | ||
14 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
15 | |||
16 | diff --git a/cmake/BundledSpdlog.cmake b/cmake/BundledSpdlog.cmake | ||
17 | index 974cbbaa..c0c45688 100644 | ||
18 | --- a/cmake/BundledSpdlog.cmake | ||
19 | +++ b/cmake/BundledSpdlog.cmake | ||
20 | @@ -35,11 +35,12 @@ function(use_bundled_spdlog SOURCE_DIR BINARY_DIR) | ||
21 | endif() | ||
22 | |||
23 | # Set build options | ||
24 | - set(SPDLOG_SOURCE_DIR "${BINARY_DIR}/thirdparty/spdlog-src") | ||
25 | + set(SPDLOG_SOURCE_DIR "${SOURCE_DIR}/thirdparty/spdlog-src") | ||
26 | set(SPDLOG_INSTALL_DIR "${BINARY_DIR}/thirdparty/spdlog-install") | ||
27 | set(SPDLOG_LIBRARY "${SPDLOG_INSTALL_DIR}/${BYPRODUCT}") | ||
28 | set(SPDLOG_CMAKE_ARGS ${PASSTHROUGH_CMAKE_ARGS} | ||
29 | "-DCMAKE_INSTALL_PREFIX=${SPDLOG_INSTALL_DIR}" | ||
30 | + "-DCMAKE_INSTALL_LIBDIR=${LIBDIR}" | ||
31 | "-DSPDLOG_BUILD_EXAMPLE=OFF" | ||
32 | "-DSPDLOG_BUILD_TESTS=OFF" | ||
33 | "-DSPDLOG_BUILD_TESTING=OFF" | ||
34 | @@ -49,7 +50,6 @@ function(use_bundled_spdlog SOURCE_DIR BINARY_DIR) | ||
35 | # Build project | ||
36 | ExternalProject_Add( | ||
37 | spdlog-external | ||
38 | - URL "https://github.com/gabime/spdlog/archive/v1.8.0.zip" | ||
39 | SOURCE_DIR "${SPDLOG_SOURCE_DIR}" | ||
40 | CMAKE_ARGS ${SPDLOG_CMAKE_ARGS} | ||
41 | BUILD_BYPRODUCTS "${SPDLOG_LIBRARY}" | ||
42 | -- | ||
43 | 2.25.1 | ||
44 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0005-Pass-noline-flag-to-flex.patch b/meta-oe/recipes-extended/minifi-cpp/files/0005-Pass-noline-flag-to-flex.patch new file mode 100644 index 000000000..53939131f --- /dev/null +++ b/meta-oe/recipes-extended/minifi-cpp/files/0005-Pass-noline-flag-to-flex.patch | |||
@@ -0,0 +1,31 @@ | |||
1 | From 083babbd6c6cc6f31530fbac0227c1d426fb0863 Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Tue, 19 Mar 2024 21:00:59 +0800 | ||
4 | Subject: [PATCH] Pass --noline flag to flex | ||
5 | |||
6 | This ensures that line directive is not emitted into lexer output which | ||
7 | could be absolute build paths. | ||
8 | |||
9 | Upstream-Status: Inappropriate [embedded specific] | ||
10 | |||
11 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
12 | --- | ||
13 | extensions/expression-language/CMakeLists.txt | 2 +- | ||
14 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
15 | |||
16 | diff --git a/extensions/expression-language/CMakeLists.txt b/extensions/expression-language/CMakeLists.txt | ||
17 | index 775b4116..84edc617 100644 | ||
18 | --- a/extensions/expression-language/CMakeLists.txt | ||
19 | +++ b/extensions/expression-language/CMakeLists.txt | ||
20 | @@ -77,7 +77,7 @@ flex_target( | ||
21 | el-scanner | ||
22 | ${CMAKE_CURRENT_SOURCE_DIR}/Scanner.ll | ||
23 | ${CMAKE_CURRENT_SOURCE_DIR}/Scanner.cpp | ||
24 | - COMPILE_FLAGS --c++ | ||
25 | + COMPILE_FLAGS "--c++ --noline" | ||
26 | ) | ||
27 | |||
28 | add_flex_bison_dependency(el-scanner el-parser) | ||
29 | -- | ||
30 | 2.25.1 | ||
31 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0006-OsUtils.h-add-missing-header-cstdint-for-int64_t.patch b/meta-oe/recipes-extended/minifi-cpp/files/0006-OsUtils.h-add-missing-header-cstdint-for-int64_t.patch new file mode 100644 index 000000000..38893e74a --- /dev/null +++ b/meta-oe/recipes-extended/minifi-cpp/files/0006-OsUtils.h-add-missing-header-cstdint-for-int64_t.patch | |||
@@ -0,0 +1,36 @@ | |||
1 | From 08d1b4b66fedde97eefb5e3ff6aa98fd02be7c21 Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Wed, 20 Mar 2024 10:03:14 +0800 | ||
4 | Subject: [PATCH] OsUtils.h: add missing header <cstdint> for int64_t | ||
5 | |||
6 | Fix build with musl: | ||
7 | libminifi/include/utils/OsUtils.h:31:1: error: 'int64_t' does not name a type | ||
8 | 31 | int64_t getCurrentProcessPhysicalMemoryUsage(); | ||
9 | | ^~~~~~~ | ||
10 | libminifi/include/utils/OsUtils.h:22:1: note: 'int64_t' is defined in header '<cstdint>'; did you forget to '#include <cstdint>'? | ||
11 | 21 | #include <system_error> | ||
12 | +++ |+#include <cstdint> | ||
13 | 22 | | ||
14 | |||
15 | Upstream-Status: Pending | ||
16 | |||
17 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
18 | --- | ||
19 | libminifi/include/utils/OsUtils.h | 1 + | ||
20 | 1 file changed, 1 insertion(+) | ||
21 | |||
22 | diff --git a/libminifi/include/utils/OsUtils.h b/libminifi/include/utils/OsUtils.h | ||
23 | index a7117233..5e623d1a 100644 | ||
24 | --- a/libminifi/include/utils/OsUtils.h | ||
25 | +++ b/libminifi/include/utils/OsUtils.h | ||
26 | @@ -19,6 +19,7 @@ | ||
27 | #include <string> | ||
28 | #include <optional> | ||
29 | #include <system_error> | ||
30 | +#include <cstdint> | ||
31 | |||
32 | struct sockaddr; | ||
33 | |||
34 | -- | ||
35 | 2.25.1 | ||
36 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/0007-CMakeLists.txt-do-not-use-ccache.patch b/meta-oe/recipes-extended/minifi-cpp/files/0007-CMakeLists.txt-do-not-use-ccache.patch new file mode 100644 index 000000000..73a59f2a8 --- /dev/null +++ b/meta-oe/recipes-extended/minifi-cpp/files/0007-CMakeLists.txt-do-not-use-ccache.patch | |||
@@ -0,0 +1,38 @@ | |||
1 | From 44867a8e4100a7296b98e0e850d950d24b980959 Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Thu, 21 Mar 2024 10:18:39 +0800 | ||
4 | Subject: [PATCH] CMakeLists.txt: do not use ccache | ||
5 | |||
6 | Upstream-Status: Inappropriate [embedded specific] | ||
7 | |||
8 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
9 | --- | ||
10 | CMakeLists.txt | 12 ++++++------ | ||
11 | 1 file changed, 6 insertions(+), 6 deletions(-) | ||
12 | |||
13 | diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
14 | index 8a1dd6d91..8a5314544 100644 | ||
15 | --- a/CMakeLists.txt | ||
16 | +++ b/CMakeLists.txt | ||
17 | @@ -82,12 +82,12 @@ if (USE_REAL_ODBC_TEST_DRIVER) | ||
18 | endif() | ||
19 | |||
20 | # Use ccache if present | ||
21 | -find_program(CCACHE_FOUND ccache) | ||
22 | -if(CCACHE_FOUND) | ||
23 | - set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache) | ||
24 | - set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache) | ||
25 | - message("-- Found ccache: ${CCACHE_FOUND}") | ||
26 | -endif(CCACHE_FOUND) | ||
27 | +#find_program(CCACHE_FOUND ccache) | ||
28 | +#if(CCACHE_FOUND) | ||
29 | +# set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache) | ||
30 | +# set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache) | ||
31 | +# message("-- Found ccache: ${CCACHE_FOUND}") | ||
32 | +#endif(CCACHE_FOUND) | ||
33 | |||
34 | # Use gold linker if instructed | ||
35 | if (UNIX AND USE_GOLD_LINKER AND NOT APPLE ) | ||
36 | -- | ||
37 | 2.25.1 | ||
38 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/fix-libressl-avoid-BSWAP-assembly-for-ARM-v6.patch b/meta-oe/recipes-extended/minifi-cpp/files/fix-libressl-avoid-BSWAP-assembly-for-ARM-v6.patch deleted file mode 100644 index a7dc35ae5..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/fix-libressl-avoid-BSWAP-assembly-for-ARM-v6.patch +++ /dev/null | |||
@@ -1,36 +0,0 @@ | |||
1 | Upstream-Status: Pending | ||
2 | |||
3 | diff -urN -x .git orig/thirdparty/libressl/avoid-BSWAP-assembly-for-ARM-v6.patch patched/thirdparty/libressl/avoid-BSWAP-assembly-for-ARM-v6.patch | ||
4 | --- orig/thirdparty/libressl/avoid-BSWAP-assembly-for-ARM-v6.patch 1970-01-01 09:00:00.000000000 +0900 | ||
5 | +++ patched/thirdparty/libressl/avoid-BSWAP-assembly-for-ARM-v6.patch 2020-08-07 23:14:46.196764271 +0900 | ||
6 | @@ -0,0 +1,30 @@ | ||
7 | +This patch was imported from the libressl potable. | ||
8 | +https://github.com/libressl-portable/portable/commit/a9332ccecfce63bf54924e70c11f420edd3ae312 | ||
9 | + | ||
10 | +From a9332ccecfce63bf54924e70c11f420edd3ae312 Mon Sep 17 00:00:00 2001 | ||
11 | +From: Brent Cook <bcook@openbsd.org> | ||
12 | +Date: Sun, 17 Jul 2016 18:12:23 -0500 | ||
13 | +Subject: [PATCH] avoid BSWAP assembly for ARM <= v6 | ||
14 | + | ||
15 | +diff -urN orig/crypto/modes/modes_lcl.h patched/crypto/modes/modes_lcl.h | ||
16 | +--- orig/crypto/modes/modes_lcl.h 2018-11-18 21:27:10.000000000 +0900 | ||
17 | ++++ patched/crypto/modes/modes_lcl.h 2020-08-07 23:11:01.960764745 +0900 | ||
18 | +@@ -45,14 +45,16 @@ | ||
19 | + asm ("bswapl %0" \ | ||
20 | + : "+r"(ret)); ret; }) | ||
21 | + # elif (defined(__arm__) || defined(__arm)) && !defined(__STRICT_ALIGNMENT) | ||
22 | +-# define BSWAP8(x) ({ u32 lo=(u64)(x)>>32,hi=(x); \ | ||
23 | ++# if (__ARM_ARCH >= 6) | ||
24 | ++# define BSWAP8(x) ({ u32 lo=(u64)(x)>>32,hi=(x); \ | ||
25 | + asm ("rev %0,%0; rev %1,%1" \ | ||
26 | + : "+r"(hi),"+r"(lo)); \ | ||
27 | + (u64)hi<<32|lo; }) | ||
28 | +-# define BSWAP4(x) ({ u32 ret; \ | ||
29 | ++# define BSWAP4(x) ({ u32 ret; \ | ||
30 | + asm ("rev %0,%1" \ | ||
31 | + : "=r"(ret) : "r"((u32)(x))); \ | ||
32 | + ret; }) | ||
33 | ++# endif | ||
34 | + # endif | ||
35 | + #endif | ||
36 | + #endif | ||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/fix-libressl-compile.patch b/meta-oe/recipes-extended/minifi-cpp/files/fix-libressl-compile.patch deleted file mode 100644 index 32bcfbd2b..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/fix-libressl-compile.patch +++ /dev/null | |||
@@ -1,45 +0,0 @@ | |||
1 | Upstream-Status: Pending | ||
2 | |||
3 | diff -urN -x .git orig/cmake/LibreSSL.cmake patched/cmake/LibreSSL.cmake | ||
4 | --- orig/cmake/LibreSSL.cmake 2020-08-07 21:58:34.660773928 +0900 | ||
5 | +++ patched/cmake/LibreSSL.cmake 2020-08-07 22:51:18.620767245 +0900 | ||
6 | @@ -18,6 +18,9 @@ | ||
7 | function(use_libre_ssl SOURCE_DIR BINARY_DIR) | ||
8 | message("Using bundled LibreSSL from release") | ||
9 | |||
10 | + find_package(Patch REQUIRED) | ||
11 | + set(PATCH "${Patch_EXECUTABLE}" -p1 -i "${SOURCE_DIR}/thirdparty/libressl/avoid-BSWAP-assembly-for-ARM-v6.patch") | ||
12 | + | ||
13 | set(BYPRODUCT_PREFIX "lib" CACHE STRING "" FORCE) | ||
14 | set(BYPRODUCT_SUFFIX ".a" CACHE STRING "" FORCE) | ||
15 | |||
16 | @@ -27,16 +30,29 @@ | ||
17 | set(BYPRODUCT_PREFIX "" CACHE STRING "" FORCE) | ||
18 | set(BUILD_ARGS " -GVisual Studio 15 2017") | ||
19 | endif(WIN32) | ||
20 | + | ||
21 | + set(BYPRODUCTS | ||
22 | + "lib/${BYPRODUCT_PREFIX}crypto${BYPRODUCT_SUFFIX}" | ||
23 | + "lib/${BYPRODUCT_PREFIX}ssl${BYPRODUCT_SUFFIX}" | ||
24 | + "lib/${BYPRODUCT_PREFIX}tls${BYPRODUCT_SUFFIX}" | ||
25 | + ) | ||
26 | + set(LIBRESSL_INSTALL_DIR "${BINARY_DIR}/thirdparty/libressl-install" CACHE STRING "" FORCE) | ||
27 | + FOREACH(BYPRODUCT ${BYPRODUCTS}) | ||
28 | + LIST(APPEND LIBRESSL_LIBRARIES_LIST "${LIBRESSL_INSTALL_DIR}/${BYPRODUCT}") | ||
29 | + ENDFOREACH(BYPRODUCT) | ||
30 | + | ||
31 | ExternalProject_Add( | ||
32 | libressl-portable | ||
33 | URL https://cdn.openbsd.org/pub/OpenBSD/LibreSSL/libressl-2.8.3.tar.gz https://ftp.openbsd.org/pub/OpenBSD/LibreSSL/libressl-2.8.3.tar.gz https://gentoo.osuosl.org/distfiles/libressl-2.8.3.tar.gz | ||
34 | URL_HASH "SHA256=9b640b13047182761a99ce3e4f000be9687566e0828b4a72709e9e6a3ef98477" | ||
35 | SOURCE_DIR "${BINARY_DIR}/thirdparty/libressl-src" | ||
36 | + PATCH_COMMAND ${PATCH} | ||
37 | CMAKE_ARGS ${PASSTHROUGH_CMAKE_ARGS} | ||
38 | "-DCMAKE_INSTALL_PREFIX=${BINARY_DIR}/thirdparty/libressl-install" | ||
39 | "-DLIBRESSL_APPS=OFF" | ||
40 | "-DLIBRESSL_TESTS=OFF" | ||
41 | "${BUILD_ARGS}" | ||
42 | + BUILD_BYPRODUCTS ${LIBRESSL_LIBRARIES_LIST} | ||
43 | ) | ||
44 | |||
45 | add_library(crypto STATIC IMPORTED) | ||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/fix-minifi-compile.patch b/meta-oe/recipes-extended/minifi-cpp/files/fix-minifi-compile.patch deleted file mode 100644 index d5b4449b8..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/fix-minifi-compile.patch +++ /dev/null | |||
@@ -1,62 +0,0 @@ | |||
1 | Upstream-Status: Pending | ||
2 | |||
3 | diff -urN -x .git orig/CMakeLists.txt patched/CMakeLists.txt | ||
4 | --- orig/CMakeLists.txt 2020-08-07 21:58:34.656773928 +0900 | ||
5 | +++ patched/CMakeLists.txt 2020-08-10 15:08:31.800278357 +0900 | ||
6 | @@ -119,13 +119,28 @@ | ||
7 | endif() | ||
8 | endif() | ||
9 | |||
10 | +include(CheckCXXSourceCompiles) | ||
11 | +CHECK_CXX_SOURCE_COMPILES(" | ||
12 | + #include <atomic> | ||
13 | + int main(int argc, char **argv) { | ||
14 | + uint8_t m; | ||
15 | + __atomic_load_8(&m, 0); | ||
16 | + __atomic_fetch_add_1(&m , 0, 0); | ||
17 | + return 0; | ||
18 | + }" | ||
19 | + HAVE_ATOMIC | ||
20 | +) | ||
21 | +if(NOT HAVE_ATOMIC) | ||
22 | + set(LIB_ATOMIC atomic) | ||
23 | +endif() | ||
24 | + | ||
25 | # Use ccache if present | ||
26 | -find_program(CCACHE_FOUND ccache) | ||
27 | -if(CCACHE_FOUND) | ||
28 | - set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache) | ||
29 | - set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache) | ||
30 | - message("-- Found ccache: ${CCACHE_FOUND}") | ||
31 | -endif(CCACHE_FOUND) | ||
32 | +#find_program(CCACHE_FOUND ccache) | ||
33 | +#if(CCACHE_FOUND) | ||
34 | +# set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache) | ||
35 | +# set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache) | ||
36 | +# message("-- Found ccache: ${CCACHE_FOUND}") | ||
37 | +#endif(CCACHE_FOUND) | ||
38 | |||
39 | if (UNIX AND USE_GOLD_LINKER AND NOT APPLE ) | ||
40 | execute_process(COMMAND ${CMAKE_C_COMPILER} -fuse-ld=gold -Wl,--version ERROR_QUIET OUTPUT_VARIABLE ld_version) | ||
41 | @@ -303,8 +318,10 @@ | ||
42 | GIT_TAG "f3294d9d86e6a7915a967efff2842089b8b0d071" # Version 7.64.0 | ||
43 | SOURCE_DIR "${CMAKE_CURRENT_BINARY_DIR}/thirdparty/curl-src" | ||
44 | LIST_SEPARATOR % # This is needed for passing semicolon-separated lists | ||
45 | + TLS_VERIFY OFF | ||
46 | CMAKE_ARGS ${PASSTHROUGH_CMAKE_ARGS} | ||
47 | "-DCMAKE_INSTALL_PREFIX=${CMAKE_CURRENT_BINARY_DIR}/thirdparty/curl-install" | ||
48 | + "-DCMAKE_INSTALL_LIBDIR=lib${LIBSUFFIX}" | ||
49 | -DCMAKE_POSITION_INDEPENDENT_CODE=ON | ||
50 | -DBUILD_CURL_EXE=OFF | ||
51 | -DBUILD_TESTING=OFF | ||
52 | diff -urN -x .git orig/libminifi/CMakeLists.txt patched/libminifi/CMakeLists.txt | ||
53 | --- orig/libminifi/CMakeLists.txt 2020-08-07 21:58:34.676773928 +0900 | ||
54 | +++ patched/libminifi/CMakeLists.txt 2020-08-10 15:06:17.124278642 +0900 | ||
55 | @@ -108,6 +108,7 @@ | ||
56 | add_library(spdlog STATIC ${SPD_SOURCES}) | ||
57 | add_library(core-minifi STATIC ${SOURCES}) | ||
58 | target_link_libraries(core-minifi ${CMAKE_DL_LIBS} yaml-cpp) | ||
59 | +target_link_libraries(core-minifi ${LIB_ATOMIC}) | ||
60 | |||
61 | #target_link_libraries(core-minifi PRIVATE bsdiff ) | ||
62 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/fix-osspuuid-compile.patch b/meta-oe/recipes-extended/minifi-cpp/files/fix-osspuuid-compile.patch deleted file mode 100644 index 903e72e07..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/fix-osspuuid-compile.patch +++ /dev/null | |||
@@ -1,38 +0,0 @@ | |||
1 | Upstream-Status: Pending | ||
2 | |||
3 | diff -urN -x .git orig/cmake/BundledOSSPUUID.cmake patched/cmake/BundledOSSPUUID.cmake | ||
4 | --- orig/cmake/BundledOSSPUUID.cmake 2020-08-07 21:58:34.660773928 +0900 | ||
5 | +++ patched/cmake/BundledOSSPUUID.cmake 2020-08-07 22:05:57.404772993 +0900 | ||
6 | @@ -22,7 +22,9 @@ | ||
7 | |||
8 | # Define patch step | ||
9 | find_package(Patch REQUIRED) | ||
10 | - set(PC "${Patch_EXECUTABLE}" -p1 -i "${SOURCE_DIR}/thirdparty/ossp-uuid/ossp-uuid-mac-fix.patch") | ||
11 | + set(PATCH1 "${Patch_EXECUTABLE}" -p1 -i "${SOURCE_DIR}/thirdparty/ossp-uuid/ossp-uuid-mac-fix.patch") | ||
12 | + set(PATCH2 "${Patch_EXECUTABLE}" -p1 -i "${SOURCE_DIR}/thirdparty/ossp-uuid/ossp-uuid-cross-compile-fix.patch") | ||
13 | + set(PATCH3 "${Patch_EXECUTABLE}" -p1 -i "${SOURCE_DIR}/thirdparty/ossp-uuid/ossp-uuid-musl-compile-fix.patch") | ||
14 | |||
15 | # Define byproducts | ||
16 | set(BYPRODUCTS "lib/libuuid.a" | ||
17 | @@ -35,7 +37,9 @@ | ||
18 | ENDFOREACH(BYPRODUCT) | ||
19 | |||
20 | # Build project | ||
21 | - set(CONFIGURE_COMMAND ./configure "CFLAGS=-fPIC" "CXXFLAGS=-fPIC" --with-cxx --without-perl --without-php --without-pgsql "--prefix=${BINARY_DIR}/thirdparty/ossp-uuid-install") | ||
22 | + set(CONFIGURE_COMMAND ac_cv_va_copy=C99 ./configure CFLAGS=-fPIC CXXFLAGS=-fPIC --host=${HOST_SYS} | ||
23 | + --with-cxx --without-perl --without-php --without-pgsql | ||
24 | + --prefix=${BINARY_DIR}/thirdparty/ossp-uuid-install) | ||
25 | string(TOLOWER "${CMAKE_BUILD_TYPE}" build_type) | ||
26 | if(NOT build_type MATCHES debug) | ||
27 | list(APPEND CONFIGURE_COMMAND --enable-debug=yes) | ||
28 | @@ -52,8 +56,8 @@ | ||
29 | UPDATE_COMMAND "" | ||
30 | INSTALL_COMMAND make install | ||
31 | BUILD_BYPRODUCTS ${OSSPUUID_LIBRARIES_LIST} | ||
32 | - CONFIGURE_COMMAND "" | ||
33 | - PATCH_COMMAND ${PC} && ${CONFIGURE_COMMAND} | ||
34 | + CONFIGURE_COMMAND ${CONFIGURE_COMMAND} | ||
35 | + PATCH_COMMAND ${PATCH1} && ${PATCH2} && ${PATCH3} | ||
36 | STEP_TARGETS build | ||
37 | EXCLUDE_FROM_ALL TRUE | ||
38 | ) | ||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/fix-osspuuid-cross-compile.patch b/meta-oe/recipes-extended/minifi-cpp/files/fix-osspuuid-cross-compile.patch deleted file mode 100644 index add1f6f2d..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/fix-osspuuid-cross-compile.patch +++ /dev/null | |||
@@ -1,39 +0,0 @@ | |||
1 | Upstream-Status: Pending | ||
2 | |||
3 | diff -urN -x .git orig/thirdparty/ossp-uuid/ossp-uuid-cross-compile-fix.patch patched/thirdparty/ossp-uuid/ossp-uuid-cross-compile-fix.patch | ||
4 | --- orig/thirdparty/ossp-uuid/ossp-uuid-cross-compile-fix.patch 1970-01-01 09:00:00.000000000 +0900 | ||
5 | +++ patched/thirdparty/ossp-uuid/ossp-uuid-cross-compile-fix.patch 2020-08-07 22:28:04.396770190 +0900 | ||
6 | @@ -0,0 +1,33 @@ | ||
7 | +diff -urN orig/config.sub patched/config.sub | ||
8 | +--- orig/config.sub 2008-07-05 06:43:08.000000000 +0900 | ||
9 | ++++ patched/config.sub 2020-08-07 22:23:48.412770731 +0900 | ||
10 | +@@ -238,6 +238,8 @@ | ||
11 | + # Some are omitted here because they have special meanings below. | ||
12 | + 1750a | 580 \ | ||
13 | + | a29k \ | ||
14 | ++ | aarch64 | aarch64_be \ | ||
15 | ++ | riscv32 | riscv64 \ | ||
16 | + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | ||
17 | + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | ||
18 | + | am33_2.0 \ | ||
19 | +@@ -314,6 +316,8 @@ | ||
20 | + # Recognize the basic CPU types with company name. | ||
21 | + 580-* \ | ||
22 | + | a29k-* \ | ||
23 | ++ | aarch64-* | aarch64_be-* \ | ||
24 | ++ | riscv32-* | riscv64-* \ | ||
25 | + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | ||
26 | + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | ||
27 | + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | ||
28 | +diff -urN orig/shtool patched/shtool | ||
29 | +--- orig/shtool 2008-07-05 06:43:08.000000000 +0900 | ||
30 | ++++ patched/shtool 2020-08-07 22:21:23.192771037 +0900 | ||
31 | +@@ -1400,7 +1400,7 @@ | ||
32 | + if [ ".$opt_t" = .yes ]; then | ||
33 | + echo "strip $dsttmp" 1>&2 | ||
34 | + fi | ||
35 | +- strip $dsttmp || shtool_exit $? | ||
36 | ++ $STRIP $dsttmp || shtool_exit $? | ||
37 | + fi | ||
38 | + if [ ".$opt_o" != . ]; then | ||
39 | + if [ ".$opt_t" = .yes ]; then | ||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/fix-osspuuid-musl-compile.patch b/meta-oe/recipes-extended/minifi-cpp/files/fix-osspuuid-musl-compile.patch deleted file mode 100644 index f8ba89dc3..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/fix-osspuuid-musl-compile.patch +++ /dev/null | |||
@@ -1,27 +0,0 @@ | |||
1 | Upstream-Status: Pending | ||
2 | |||
3 | diff -urN -x .git orig/thirdparty/ossp-uuid/ossp-uuid-musl-compile-fix.patch patched/thirdparty/ossp-uuid/ossp-uuid-musl-compile-fix.patch | ||
4 | --- orig/thirdparty/ossp-uuid/ossp-uuid-musl-compile-fix.patch 1970-01-01 09:00:00.000000000 +0900 | ||
5 | +++ patched/thirdparty/ossp-uuid/ossp-uuid-musl-compile-fix.patch 2020-08-07 11:22:49.344854508 +0900 | ||
6 | @@ -0,0 +1,21 @@ | ||
7 | +diff -urN orig/config.sub patched/config.sub | ||
8 | +--- orig/config.sub 2008-07-05 06:43:08.000000000 +0900 | ||
9 | ++++ patched/config.sub 2020-08-07 11:19:25.948854937 +0900 | ||
10 | +@@ -120,7 +120,7 @@ | ||
11 | + # Here we must recognize all the valid KERNEL-OS combinations. | ||
12 | + maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` | ||
13 | + case $maybe_os in | ||
14 | +- nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \ | ||
15 | ++ nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | linux-musl* | \ | ||
16 | + uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \ | ||
17 | + storm-chaos* | os2-emx* | rtmk-nova*) | ||
18 | + os=-$maybe_os | ||
19 | +@@ -1250,7 +1250,7 @@ | ||
20 | + | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | ||
21 | + | -chorusos* | -chorusrdb* \ | ||
22 | + | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | ||
23 | +- | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \ | ||
24 | ++ | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* | -linux-musl* \ | ||
25 | + | -uxpv* | -beos* | -mpeix* | -udk* \ | ||
26 | + | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | ||
27 | + | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | ||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/fix-rocksdb-cross-compile.patch b/meta-oe/recipes-extended/minifi-cpp/files/fix-rocksdb-cross-compile.patch deleted file mode 100644 index 0a3194da9..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/fix-rocksdb-cross-compile.patch +++ /dev/null | |||
@@ -1,14 +0,0 @@ | |||
1 | Upstream-Status: Pending | ||
2 | |||
3 | diff -urN orig/thirdparty/rocksdb/CMakeLists.txt patched/thirdparty/rocksdb/CMakeLists.txt | ||
4 | --- orig/thirdparty/rocksdb/CMakeLists.txt 2020-07-28 11:39:40.254677515 +0900 | ||
5 | +++ patched/thirdparty/rocksdb/CMakeLists.txt 2020-07-28 11:51:11.898676054 +0900 | ||
6 | @@ -618,6 +618,7 @@ | ||
7 | add_library(${ROCKSDB_STATIC_LIB} STATIC ${SOURCES}) | ||
8 | target_link_libraries(${ROCKSDB_STATIC_LIB} | ||
9 | ${THIRDPARTY_LIBS} ${SYSTEM_LIBS}) | ||
10 | +target_link_libraries(${ROCKSDB_STATIC_LIB} ${LIB_ATOMIC}) | ||
11 | |||
12 | if(WIN32) | ||
13 | # add_library(${ROCKSDB_IMPORT_LIB} SHARED ${SOURCES}) | ||
14 | |||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/minifi.service b/meta-oe/recipes-extended/minifi-cpp/files/minifi.service deleted file mode 100644 index 059cdbcc2..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/minifi.service +++ /dev/null | |||
@@ -1,13 +0,0 @@ | |||
1 | [Unit] | ||
2 | Description=MiNiFi Service | ||
3 | After=network.target | ||
4 | RequiresMountsFor=/var | ||
5 | |||
6 | [Service] | ||
7 | Type=simple | ||
8 | WorkingDirectory=@LOCALSTATEDIR@/lib/minifi | ||
9 | Environment=MINIFI_HOME=@SYSCONFDIR@/minifi | ||
10 | ExecStart=@BINDIR@/minifi | ||
11 | |||
12 | [Install] | ||
13 | WantedBy=multi-user.target | ||
diff --git a/meta-oe/recipes-extended/minifi-cpp/files/remove_const_due_to_std_lock_guard.patch b/meta-oe/recipes-extended/minifi-cpp/files/remove_const_due_to_std_lock_guard.patch deleted file mode 100644 index 365dec9d4..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/files/remove_const_due_to_std_lock_guard.patch +++ /dev/null | |||
@@ -1,40 +0,0 @@ | |||
1 | From bfce136fa9ff1e955928539484ba4dd55f98f05b Mon Sep 17 00:00:00 2001 | ||
2 | From: Willem Jan Withagen <wjw@digiware.nl> | ||
3 | Date: Sun, 16 Aug 2020 23:38:55 +0200 | ||
4 | Subject: [PATCH] Update channel.h | ||
5 | |||
6 | Compiling this on FreeBSD with CLang fails due to: | ||
7 | ```In file included from /usr/ports/net/ceph15/work/ceph-15.2.4/src/rocksdb/utilities/backupable/backupable_db.cc:16: | ||
8 | /usr/ports/net/ceph15/work/ceph-15.2.4/src/rocksdb/util/channel.h:35:33: error: no matching constructor for initialization of 'std::lock_guard<std::mutex>' | ||
9 | std::lock_guard<std::mutex> lk(lock_); | ||
10 | ^ ~~~~~ | ||
11 | /usr/include/c++/v1/__mutex_base:90:14: note: candidate constructor not viable: 1st argument ('const std::mutex') would lose const qualifier | ||
12 | explicit lock_guard(mutex_type& __m) _LIBCPP_THREAD_SAFETY_ANNOTATION(acquire_capability(__m)) | ||
13 | ^ | ||
14 | /usr/include/c++/v1/__mutex_base:100:5: note: candidate constructor not viable: no known conversion from 'const std::mutex' to 'const std::__1::lock_guard<std::__1::mutex>' for 1st argument | ||
15 | lock_guard(lock_guard const&) _LIBCPP_EQUAL_DELETE; | ||
16 | ^ | ||
17 | /usr/include/c++/v1/__mutex_base:94:5: note: candidate constructor not viable: requires 2 arguments, but 1 was provided | ||
18 | lock_guard(mutex_type& __m, adopt_lock_t) _LIBCPP_THREAD_SAFETY_ANNOTATION(requires_capability(__m)) | ||
19 | ^ | ||
20 | 1 error generated. | ||
21 | ``` | ||
22 | --- | ||
23 | Upstream-Status: Pending | ||
24 | |||
25 | thirdparty/rocksdb/util/channel.h | 2 +- | ||
26 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
27 | |||
28 | diff --git a/thirdparty/rocksdb/util/channel.h b/thirdparty/rocksdb/util/channel.h | ||
29 | index 705fa2d28f..993bef5bc0 100644 | ||
30 | --- a/thirdparty/rocksdb/util/channel.h | ||
31 | +++ b/thirdparty/rocksdb/util/channel.h | ||
32 | @@ -31,7 +31,7 @@ class channel { | ||
33 | return buffer_.empty() && eof_; | ||
34 | } | ||
35 | |||
36 | - size_t size() const { | ||
37 | + size_t size() { | ||
38 | std::lock_guard<std::mutex> lk(lock_); | ||
39 | return buffer_.size(); | ||
40 | } | ||
diff --git a/meta-oe/recipes-extended/minifi-cpp/minifi-cpp_0.15.0.bb b/meta-oe/recipes-extended/minifi-cpp/minifi-cpp_0.15.0.bb new file mode 100644 index 000000000..0667fdaec --- /dev/null +++ b/meta-oe/recipes-extended/minifi-cpp/minifi-cpp_0.15.0.bb | |||
@@ -0,0 +1,200 @@ | |||
1 | SUMMARY = "A subproject of Apache NiFi to collect data where it originates." | ||
2 | DESCRIPTION = "MiNiFi--a subproject of Apache NiFi--is a complementary \ | ||
3 | data collection approach that supplements the core tenets of NiFi in dataflow \ | ||
4 | management, focusing on the collection of data at the source of its creation." | ||
5 | HOMEPAGE = "https://nifi.apache.org/minifi/index.html" | ||
6 | SECTION = "console/network" | ||
7 | LICENSE = "Apache-2.0" | ||
8 | LIC_FILES_CHKSUM = "file://LICENSE;md5=c62efdfb90a8aa4cc3bc15f56baa30b7" | ||
9 | |||
10 | SRC_URI = "git://github.com/apache/nifi-minifi-cpp.git;protocol=https;branch=main \ | ||
11 | git://github.com/martinmoene/expected-lite.git;protocol=https;branch=master;name=expected-lite;destsuffix=${S}/thirdparty/expected-lite-src \ | ||
12 | git://github.com/ericniebler/range-v3.git;protocol=https;branch=master;name=range-v3;destsuffix=${S}/thirdparty/range-v3-src \ | ||
13 | git://github.com/Neargye/magic_enum.git;protocol=https;branch=master;name=magic-enum;destsuffix=${S}/thirdparty/magic-enum-src \ | ||
14 | git://github.com/jarro2783/cxxopts.git;protocol=https;branch=v2_2;name=cxxopts;destsuffix=${S}/thirdparty/cxxopts-src \ | ||
15 | git://github.com/gsl-lite/gsl-lite.git;protocol=https;branch=master;name=gsl-lite;destsuffix=${S}/thirdparty/gsl-lite-src \ | ||
16 | git://github.com/HowardHinnant/date.git;protocol=https;branch=master;name=date;destsuffix=${S}/thirdparty/date-src \ | ||
17 | git://github.com/chriskohlhoff/asio.git;protocol=https;branch=master;name=asio;destsuffix=${S}/thirdparty/asio-src \ | ||
18 | git://github.com/gabime/spdlog.git;protocol=https;branch=v1.x;name=spdlog;destsuffix=${S}/thirdparty/spdlog-src \ | ||
19 | git://github.com/civetweb/civetweb.git;protocol=https;branch=master;name=civetweb;destsuffix=${S}/thirdparty/civetweb-src \ | ||
20 | ${DEBIAN_MIRROR}/main/o/ossp-uuid/ossp-uuid_1.6.2.orig.tar.gz;name=ossp-uuid;subdir=${S}/thirdparty \ | ||
21 | https://download.libsodium.org/libsodium/releases/libsodium-1.0.19.tar.gz;name=libsodium;subdir=${S}/thirdparty \ | ||
22 | file://0001-Do-not-use-bundled-packages.patch \ | ||
23 | file://0002-Fix-osspuuid-build.patch \ | ||
24 | file://0003-Fix-libsodium-build.patch \ | ||
25 | file://0004-Fix-spdlog-build.patch \ | ||
26 | file://0005-Pass-noline-flag-to-flex.patch \ | ||
27 | file://0006-OsUtils.h-add-missing-header-cstdint-for-int64_t.patch \ | ||
28 | file://0007-CMakeLists.txt-do-not-use-ccache.patch \ | ||
29 | file://systemd-volatile.conf \ | ||
30 | file://sysvinit-volatile.conf \ | ||
31 | " | ||
32 | |||
33 | SRCREV = "9b55dc0c0f17a190f3e9ade87070a28faf542c25" | ||
34 | SRCREV_expected-lite = "c8ffab649ba56e43c731b7017a69ddaebe2e1893" | ||
35 | SRCREV_range-v3 = "a81477931a8aa2ad025c6bda0609f38e09e4d7ec" | ||
36 | SRCREV_magic-enum = "e1ea11a93d0bdf6aae415124ded6126220fa4f28" | ||
37 | SRCREV_cxxopts = "302302b30839505703d37fb82f536c53cf9172fa" | ||
38 | SRCREV_gsl-lite = "755ba124b54914e672737acace6a9314f59e8d6f" | ||
39 | SRCREV_date = "6e921e1b1d21e84a5c82416ba7ecd98e33a436d0" | ||
40 | SRCREV_asio = "814f67e730e154547aea3f4d99f709cbdf1ea4a0" | ||
41 | SRCREV_spdlog = "7c02e204c92545f869e2f04edaab1f19fe8b19fd" | ||
42 | SRCREV_civetweb = "d7ba35bbb649209c66e582d5a0244ba988a15159" | ||
43 | |||
44 | SRCREV_FORMAT .= "_expected-lite_range-v3_magic-enum_cxxopts_gsl-lite_date_asio_spdlog_civetweb" | ||
45 | |||
46 | SRC_URI[ossp-uuid.sha256sum] = "11a615225baa5f8bb686824423f50e4427acd3f70d394765bdff32801f0fd5b0" | ||
47 | SRC_URI[libsodium.sha256sum] = "018d79fe0a045cca07331d37bd0cb57b2e838c51bc48fd837a1472e50068bbea" | ||
48 | |||
49 | S = "${WORKDIR}/git" | ||
50 | |||
51 | inherit pkgconfig cmake systemd | ||
52 | |||
53 | DEPENDS = "virtual/crypt bison-native flex-native flex openssl curl zlib xz bzip2 yaml-cpp" | ||
54 | |||
55 | OECMAKE_FIND_ROOT_PATH_MODE_PROGRAM = "BOTH" | ||
56 | |||
57 | EXTRA_OECMAKE = " \ | ||
58 | -DCMAKE_BUILD_TYPE=Release \ | ||
59 | -DHOST_SYS=${HOST_SYS} -DBUILD_SYS=${BUILD_SYS} \ | ||
60 | -DGCC_AR=${STAGING_BINDIR_TOOLCHAIN}/${AR} \ | ||
61 | -DGCC_RANLIB=${STAGING_BINDIR_TOOLCHAIN}/${RANLIB} \ | ||
62 | -DFLEX_TARGET_ARG_COMPILE_FLAGS='--noline' \ | ||
63 | -DBISON_TARGET_ARG_COMPILE_FLAGS='--no-lines --file-prefix-map=${S}=${TARGET_DBGSRC_DIR}' \ | ||
64 | -DENABLE_ENCRYPT_CONFIG=ON \ | ||
65 | -DENABLE_LUA_SCRIPTING=OFF \ | ||
66 | -DENABLE_PYTHON_SCRIPTING=OFF \ | ||
67 | -DENABLE_AWS=OFF \ | ||
68 | -DENABLE_AZURE=OFF \ | ||
69 | -DENABLE_GCP=OFF \ | ||
70 | -DENABLE_KUBERNETES=OFF \ | ||
71 | -DENABLE_MQTT=OFF \ | ||
72 | -DENABLE_ELASTICSEARCH=OFF \ | ||
73 | -DENABLE_SQL=OFF \ | ||
74 | -DENABLE_PROMETHEUS=OFF \ | ||
75 | -DENABLE_PROCFS=OFF \ | ||
76 | -DENABLE_SPLUNK=OFF \ | ||
77 | -DENABLE_OPC=OFF \ | ||
78 | -DENABLE_LIBRDKAFKA=OFF \ | ||
79 | -DDISABLE_CURL=OFF \ | ||
80 | -DDISABLE_BZIP2=OFF \ | ||
81 | -DDISABLE_LZMA=OFF \ | ||
82 | -DDISABLE_JEMALLOC=ON \ | ||
83 | -DSKIP_TESTS=ON \ | ||
84 | -DFETCHCONTENT_SOURCE_DIR_GSL-LITE=${S}/thirdparty/gsl-lite-src \ | ||
85 | -DFETCHCONTENT_SOURCE_DIR_DATE_SRC=${S}/thirdparty/date-src \ | ||
86 | -DFETCHCONTENT_SOURCE_DIR_EXPECTED-LITE=${S}/thirdparty/expected-lite-src \ | ||
87 | -DFETCHCONTENT_SOURCE_DIR_RANGE-V3_SRC=${S}/thirdparty/range-v3-src \ | ||
88 | -DFETCHCONTENT_SOURCE_DIR_MAGIC_ENUM=${S}/thirdparty/magic-enum-src \ | ||
89 | -DFETCHCONTENT_SOURCE_DIR_ASIO=${S}/thirdparty/asio-src \ | ||
90 | -DFETCHCONTENT_SOURCE_DIR_CXXOPTS_SRC=${S}/thirdparty/cxxopts-src \ | ||
91 | -DFETCHCONTENT_SOURCE_DIR_CIVETWEB=${S}/thirdparty/civetweb-src \ | ||
92 | ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '-DENABLE_SYSTEMD=ON', '-DENABLE_SYSTEMD=OFF', d)} \ | ||
93 | " | ||
94 | |||
95 | PACKAGECONFIG ??= "civetweb libarchive rocksdb expression-language" | ||
96 | PACKAGECONFIG[civetweb] = "-DDISABLE_CIVET=OFF,-DDISABLE_CIVET=ON" | ||
97 | PACKAGECONFIG[openwsman] = "-DENABLE_OPENWSMAN=ON,-DENABLE_OPENWSMAN=OFF,libxml2" | ||
98 | PACKAGECONFIG[libarchive] = "-DDISABLE_LIBARCHIVE=OFF,-DDISABLE_LIBARCHIVE=ON,libarchive" | ||
99 | PACKAGECONFIG[rocksdb] = "-DDISABLE_ROCKSDB=OFF -DBUILD_ROCKSDB=OFF,-DDISABLE_ROCKSDB=ON,rocksdb" | ||
100 | PACKAGECONFIG[expression-language] = "-DDISABLE_EXPRESSION_LANGUAGE=OFF, -DDISABLE_EXPRESSION_LANGUAGE=ON" | ||
101 | |||
102 | SYSTEMD_PACKAGES = "minifi-cpp" | ||
103 | SYSTEMD_SERVICE:${PN} = "minifi.service" | ||
104 | SYSTEMD_AUTO_ENABLE = "disable" | ||
105 | |||
106 | do_install[cleandirs] += "${WORKDIR}/minifi-install" | ||
107 | PSEUDO_CONSIDER_PATHS .= ",${WORKDIR}/minifi-install" | ||
108 | |||
109 | do_compile:prepend() { | ||
110 | # Remove build host references | ||
111 | sed -i -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \ | ||
112 | -e 's|${DEBUG_PREFIX_MAP}||g' \ | ||
113 | -e 's:${RECIPE_SYSROOT_NATIVE}::g' \ | ||
114 | ${B}/libminifi/agent_version.cpp | ||
115 | } | ||
116 | |||
117 | do_install() { | ||
118 | DESTDIR='${WORKDIR}/minifi-install' cmake_runcmake_build --target ${OECMAKE_TARGET_INSTALL} | ||
119 | MINIFI_BIN=${bindir} | ||
120 | MINIFI_HOME=${sysconfdir}/minifi | ||
121 | MINIFI_RUN=${localstatedir}/lib/minifi | ||
122 | MINIFI_LOG=${localstatedir}/log/minifi | ||
123 | |||
124 | install -m 755 -d ${D}${MINIFI_BIN} | ||
125 | install -m 755 -d ${D}${MINIFI_HOME}/conf | ||
126 | install -m 755 -d ${D}${localstatedir}/lib/minifi | ||
127 | |||
128 | for i in encrypt-config minifi minifi.sh minificontroller; do | ||
129 | install -m 755 ${WORKDIR}/minifi-install/usr/bin/${i} ${D}${MINIFI_BIN} | ||
130 | done | ||
131 | for i in config.yml minifi-log.properties minifi.properties minifi-uid.properties; do | ||
132 | install -m 644 ${WORKDIR}/minifi-install/usr/conf/${i} ${D}${MINIFI_HOME}/conf | ||
133 | done | ||
134 | |||
135 | install -m 755 -d ${D}${libdir}/minifi-extensions | ||
136 | install -m 755 ${WORKDIR}/minifi-install/usr/bin/libcore-minifi.so ${D}${libdir} | ||
137 | install -m 755 ${WORKDIR}/minifi-install/usr/extensions/*.so ${D}${libdir}/minifi-extensions | ||
138 | |||
139 | install -m 755 -d ${D}${libexecdir}/minifi-python | ||
140 | for i in examples google h2o; do | ||
141 | cp -rf ${WORKDIR}/minifi-install/usr/minifi-python/${i} ${D}${libexecdir}/minifi-python | ||
142 | done | ||
143 | |||
144 | sed -i "s|MINIFI_HOME=.*|MINIFI_HOME=${MINIFI_HOME}|g" ${D}${MINIFI_BIN}/minifi.sh | ||
145 | sed -i "s|bin_dir=.*|bin_dir=${MINIFI_BIN}|g" ${D}${MINIFI_BIN}/minifi.sh | ||
146 | |||
147 | sed -i "s|#appender.rolling.directory=.*|appender.rolling.directory=${MINIFI_LOG}|g" \ | ||
148 | ${D}${MINIFI_HOME}/conf/minifi-log.properties | ||
149 | sed -i "s|nifi.provenance.repository.directory.default=.*|nifi.provenance.repository.directory.default=${MINIFI_RUN}/provenance_repository|g" \ | ||
150 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
151 | sed -i "s|nifi.flowfile.repository.directory.default=.*|nifi.flowfile.repository.directory.default=${MINIFI_RUN}/flowfile_repository|g" \ | ||
152 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
153 | sed -i "s|nifi.database.content.repository.directory.default=.*|nifi.database.content.repository.directory.default=${MINIFI_RUN}/content_repository|g" \ | ||
154 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
155 | sed -i "s|nifi.flow.configuration.file=.*|nifi.flow.configuration.file=${MINIFI_HOME}/conf/config.yml|g" \ | ||
156 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
157 | sed -i "s|nifi.python.processor.dir=.*|nifi.python.processor.dir=${libexecdir}/minifi-python|g" \ | ||
158 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
159 | sed -i "s|nifi.extension.path=.*|nifi.extension.path=${libdir}/minifi-extensions/*|g" \ | ||
160 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
161 | |||
162 | if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then | ||
163 | install -m 755 -d ${D}${sysconfdir}/tmpfiles.d | ||
164 | install -m 644 ${WORKDIR}/systemd-volatile.conf ${D}${sysconfdir}/tmpfiles.d/minifi.conf | ||
165 | sed -i "s|@MINIFI_LOG@|${MINIFI_LOG}|g" ${D}${sysconfdir}/tmpfiles.d/minifi.conf | ||
166 | |||
167 | install -m 755 -d ${D}${systemd_system_unitdir} | ||
168 | install -m 644 ${WORKDIR}/minifi-install/usr/bin/minifi.service ${D}${systemd_system_unitdir} | ||
169 | |||
170 | sed -i -e "s|^Environment=.*|Environment=MINIFI_HOME=${MINIFI_HOME}|g" ${D}${systemd_system_unitdir}/minifi.service | ||
171 | sed -i -e "s|^ExecStart=.*|ExecStart=${MINIFI_BIN}/minifi|g" ${D}${systemd_system_unitdir}/minifi.service | ||
172 | fi | ||
173 | |||
174 | if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then | ||
175 | install -d ${D}${sysconfdir}/default/volatiles | ||
176 | install -m 0644 ${WORKDIR}/sysvinit-volatile.conf ${D}${sysconfdir}/default/volatiles/99_minifi | ||
177 | |||
178 | sed -i "s|@MINIFI_LOG@|${MINIFI_LOG}|g" ${D}${sysconfdir}/default/volatiles/99_minifi | ||
179 | fi | ||
180 | } | ||
181 | |||
182 | pkg_postinst:${PN}() { | ||
183 | if [ -z "$D" ]; then | ||
184 | if type systemd-tmpfiles >/dev/null; then | ||
185 | systemd-tmpfiles --create | ||
186 | elif [ -e ${sysconfdir}/init.d/populate-volatile.sh ]; then | ||
187 | ${sysconfdir}/init.d/populate-volatile.sh update | ||
188 | fi | ||
189 | fi | ||
190 | } | ||
191 | |||
192 | FILES:${PN}-dev = "" | ||
193 | FILES:${PN} += "${libdir}/libcore-minifi.so \ | ||
194 | ${libdir}/minifi-extensions \ | ||
195 | ${libexecdir}/minifi-python \ | ||
196 | " | ||
197 | |||
198 | INSANE_SKIP:${PN} += "dev-deps" | ||
199 | |||
200 | CLEANBROKEN = "1" | ||
diff --git a/meta-oe/recipes-extended/minifi-cpp/minifi-cpp_0.7.0.bb b/meta-oe/recipes-extended/minifi-cpp/minifi-cpp_0.7.0.bb deleted file mode 100644 index 5059b6321..000000000 --- a/meta-oe/recipes-extended/minifi-cpp/minifi-cpp_0.7.0.bb +++ /dev/null | |||
@@ -1,169 +0,0 @@ | |||
1 | SUMMARY = "A subproject of Apache NiFi to collect data where it originates." | ||
2 | DESCRIPTION = "MiNiFi--a subproject of Apache NiFi--is a complementary \ | ||
3 | data collection approach that supplements the core tenets of NiFi in dataflow \ | ||
4 | management, focusing on the collection of data at the source of its creation." | ||
5 | HOMEPAGE = "https://nifi.apache.org/minifi/index.html" | ||
6 | SECTION = "console/network" | ||
7 | LICENSE = "Apache-2.0" | ||
8 | LIC_FILES_CHKSUM = "file://LICENSE;md5=f9534eb5f4ab800b573a37bffc62f3a7" | ||
9 | |||
10 | DEPENDS = "virtual/crypt expat flex python3 bison-native libxml2 nettle lz4" | ||
11 | RDEPENDS:${PN} = "python3-core" | ||
12 | |||
13 | SRCREV = "aa42957a2e227df41510047cece3cd606dc1cb6a" | ||
14 | SRC_URI = "git://github.com/apache/nifi-minifi-cpp.git;branch=master;protocol=https \ | ||
15 | https://curl.haxx.se/download/curl-7.64.0.tar.bz2;name=curl;subdir=git/thirdparty \ | ||
16 | https://ftp.openbsd.org/pub/OpenBSD/LibreSSL/libressl-2.8.3.tar.gz;name=libressl;subdir=git/thirdparty \ | ||
17 | ${DEBIAN_MIRROR}/main/o/ossp-uuid/ossp-uuid_1.6.2.orig.tar.gz;name=ossp-uuid;subdir=git/thirdparty \ | ||
18 | file://fix-minifi-compile.patch \ | ||
19 | file://fix-libressl-compile.patch \ | ||
20 | file://fix-libressl-avoid-BSWAP-assembly-for-ARM-v6.patch \ | ||
21 | file://fix-osspuuid-compile.patch \ | ||
22 | file://fix-osspuuid-cross-compile.patch \ | ||
23 | file://fix-osspuuid-musl-compile.patch \ | ||
24 | file://fix-rocksdb-cross-compile.patch \ | ||
25 | file://remove_const_due_to_std_lock_guard.patch \ | ||
26 | file://0001-Add-lxml2-to-linker-cmdline-of-xml-is-found.patch \ | ||
27 | file://0001-CMakeLists.txt-use-curl-local-source-tarball.patch \ | ||
28 | file://0002-cmake-LibreSSL.cmake-use-libressl-local-source-tarba.patch \ | ||
29 | file://0003-cmake-BundledOSSPUUID.cmake-use-ossp-uuid-local-sour.patch \ | ||
30 | file://0001-civetweb-CMakeLists.txt-do-not-search-gcc-ar-and-gcc.patch \ | ||
31 | file://0001-cxxopts-Add-limits-header.patch \ | ||
32 | file://0001-Fix-build-with-libc.patch \ | ||
33 | file://0001-civetweb-Disable-lto.patch \ | ||
34 | file://0001-Add-missing-includes-cstdint-and-cstdio.patch \ | ||
35 | file://0001-Do-not-use-LFS64-functions-on-linux-musl.patch \ | ||
36 | file://0001-Fix-the-constness-issues-around-autovector-iterator_.patch \ | ||
37 | file://0002-Fix-build-with-clang-17.patch \ | ||
38 | file://0001-CMakeLists.txt-Pass-the-OPENSSLDIR.patch \ | ||
39 | file://0001-BundledOSSPUUID.cmake-Pass-CFLAGS-to-compiler.patch \ | ||
40 | file://minifi.service \ | ||
41 | file://systemd-volatile.conf \ | ||
42 | file://sysvinit-volatile.conf \ | ||
43 | file://0001-config.guess-Support-build-on-aarch64.patch \ | ||
44 | " | ||
45 | |||
46 | SRC_URI[curl.md5sum] = "d0bcc586873cfef08b4b9594e5395a33" | ||
47 | SRC_URI[curl.sha256sum] = "d573ba1c2d1cf9d8533fadcce480d778417964e8d04ccddcc76e591d544cf2eb" | ||
48 | SRC_URI[libressl.md5sum] = "0f1127bd21b4aa8495a910379c2ad936" | ||
49 | SRC_URI[libressl.sha256sum] = "9b640b13047182761a99ce3e4f000be9687566e0828b4a72709e9e6a3ef98477" | ||
50 | SRC_URI[ossp-uuid.md5sum] = "5db0d43a9022a6ebbbc25337ae28942f" | ||
51 | SRC_URI[ossp-uuid.sha256sum] = "11a615225baa5f8bb686824423f50e4427acd3f70d394765bdff32801f0fd5b0" | ||
52 | |||
53 | S = "${WORKDIR}/git" | ||
54 | |||
55 | inherit pkgconfig cmake systemd | ||
56 | |||
57 | SYSTEMD_PACKAGES = "minifi-cpp" | ||
58 | SYSTEMD_SERVICE:${PN} = "minifi.service" | ||
59 | SYSTEMD_AUTO_ENABLE = "disable" | ||
60 | |||
61 | OECMAKE_FIND_ROOT_PATH_MODE_PROGRAM = "BOTH" | ||
62 | |||
63 | EXTRA_OECMAKE += " \ | ||
64 | -DHOST_SYS=${HOST_SYS} -DBUILD_SYS=${BUILD_SYS} \ | ||
65 | -DSKIP_TESTS=ON \ | ||
66 | -DGCC_AR=${STAGING_BINDIR_TOOLCHAIN}/${AR} \ | ||
67 | -DGCC_RANLIB=${STAGING_BINDIR_TOOLCHAIN}/${RANLIB} \ | ||
68 | -DDISABLE_PYTHON_SCRIPTING=ON \ | ||
69 | -DFLEX_TARGET_ARG_COMPILE_FLAGS='--noline' \ | ||
70 | -DBISON_TARGET_ARG_COMPILE_FLAGS='--no-lines --file-prefix-map=${S}=${TARGET_DBGSRC_DIR}' \ | ||
71 | -DOPENSSLDIR=${sysconfdir}/libressl \ | ||
72 | " | ||
73 | |||
74 | CFLAGS:append = " -fPIC" | ||
75 | EXTRA_OECMAKE:append:toolchain-clang = " -DCMAKE_RANLIB=${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}llvm-ranlib" | ||
76 | LDFLAGS:append:toolchain-clang = " -fuse-ld=lld" | ||
77 | |||
78 | # RV lld errors out: | ||
79 | # riscv64-yoe-linux-ld.lld: error: init.c:(.text+0x0): relocation R_RISCV_ALIGN requires unimplemented linker relaxation; recompile with -mno-relax | ||
80 | LDFLAGS:remove:riscv32 = "-fuse-ld=lld" | ||
81 | LDFLAGS:remove:riscv64 = "-fuse-ld=lld" | ||
82 | |||
83 | # There are endian issues when communicating with the x86 nifi on the the mips and the ppc machines. | ||
84 | COMPATIBLE_MACHINE:mips = "(!.*mips).*" | ||
85 | COMPATIBLE_MACHINE:mips64 = "(!.*mips64).*" | ||
86 | COMPATIBLE_MACHINE:powerpc = "(!.*ppc).*" | ||
87 | |||
88 | TARGET_CFLAGS:append:riscv32 = " -fpic" | ||
89 | TARGET_CXXFLAGS:append:riscv32 = " -fpic" | ||
90 | TARGET_CFLAGS:append:riscv64 = " -fpic" | ||
91 | TARGET_CXXFLAGS:append:riscv64 = " -fpic" | ||
92 | |||
93 | do_install[cleandirs] += "${WORKDIR}/minifi-install" | ||
94 | PSEUDO_CONSIDER_PATHS .= ",${WORKDIR}/minifi-install" | ||
95 | |||
96 | do_configure:prepend:libc-musl() { | ||
97 | sed -i -e 's/-DHAVE_GLIBC_STRERROR_R=1/-DHAVE_GLIBC_STRERROR_R=0/' ${S}/CMakeLists.txt | ||
98 | sed -i -e 's/-DHAVE_POSIX_STRERROR_R=0/-DHAVE_POSIX_STRERROR_R=1/' ${S}/CMakeLists.txt | ||
99 | } | ||
100 | |||
101 | do_configure:append() { | ||
102 | sed -i -e 's|${WORKDIR}|<WORKDIR>|g' ${S}/libminifi/include/agent/agent_version.h | ||
103 | } | ||
104 | |||
105 | CFLAGS:append:libc-glibc = " -D_GNU_SOURCE" | ||
106 | CXXFLAGS:append:libc-glibc = " -D_GNU_SOURCE" | ||
107 | |||
108 | do_install() { | ||
109 | DESTDIR='${WORKDIR}/minifi-install' cmake_runcmake_build --target ${OECMAKE_TARGET_INSTALL} | ||
110 | MINIFI_BIN=${bindir} | ||
111 | MINIFI_HOME=${sysconfdir}/minifi | ||
112 | MINIFI_RUN=${localstatedir}/lib/minifi | ||
113 | MINIFI_LOG=${localstatedir}/log/minifi | ||
114 | |||
115 | install -d ${D}${MINIFI_BIN} | ||
116 | install -d ${D}${MINIFI_HOME}/conf | ||
117 | install -m 755 -d ${D}${localstatedir}/lib/minifi | ||
118 | install -m 755 -d ${D}${libexecdir}/minifi-python | ||
119 | cp -a ${WORKDIR}/minifi-install/usr/bin/* ${D}${MINIFI_BIN}/ | ||
120 | cp -a ${WORKDIR}/minifi-install/usr/conf/* ${D}${MINIFI_HOME}/conf/ | ||
121 | |||
122 | sed -i 's|#appender.rolling.directory=.*|appender.rolling.directory='${MINIFI_LOG}'|g' \ | ||
123 | ${D}${MINIFI_HOME}/conf/minifi-log.properties | ||
124 | sed -i 's|nifi.provenance.repository.directory.default=.*|nifi.provenance.repository.directory.default='${MINIFI_RUN}'/provenance_repository|g' \ | ||
125 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
126 | sed -i 's|nifi.flowfile.repository.directory.default=.*|nifi.flowfile.repository.directory.default='${MINIFI_RUN}'/flowfile_repository|g' \ | ||
127 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
128 | sed -i 's|nifi.database.content.repository.directory.default=.*|nifi.database.content.repository.directory.default='${MINIFI_RUN}'/content_repository|g' \ | ||
129 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
130 | sed -i 's|nifi.flow.configuration.file=.*|nifi.flow.configuration.file='${MINIFI_HOME}'/conf/config.yml|g' \ | ||
131 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
132 | sed -i 's|nifi.python.processor.dir=.*|nifi.python.processor.dir=${libexecdir}/minifi-python|g' \ | ||
133 | ${D}${MINIFI_HOME}/conf/minifi.properties | ||
134 | |||
135 | sed -i 's|export MINIFI_HOME=.*|export MINIFI_HOME='${MINIFI_HOME}'|g' ${D}${MINIFI_BIN}/minifi.sh | ||
136 | sed -i 's|bin_dir=${MINIFI_HOME}/bin|bin_dir='${MINIFI_BIN}'|g' ${D}${MINIFI_BIN}/minifi.sh | ||
137 | sed -i 's|pid_file=${bin_dir}/.|pid_file='${localstatedir}/run/'|g' ${D}${MINIFI_BIN}/minifi.sh | ||
138 | |||
139 | if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then | ||
140 | install -d ${D}${sysconfdir}/tmpfiles.d/ | ||
141 | install -m 0644 ${WORKDIR}/systemd-volatile.conf ${D}${sysconfdir}/tmpfiles.d/minifi.conf | ||
142 | install -m 0755 -d ${D}${systemd_unitdir}/system | ||
143 | install -m 0644 ${WORKDIR}/minifi.service ${D}${systemd_unitdir}/system/ | ||
144 | |||
145 | sed -i 's|@LOCALSTATEDIR@|${localstatedir}|g' ${D}${systemd_unitdir}/system/minifi.service | ||
146 | sed -i 's|@SYSCONFDIR@|${sysconfdir}|g' ${D}${systemd_unitdir}/system/minifi.service | ||
147 | sed -i 's|@BINDIR@|${bindir}|g' ${D}${systemd_unitdir}/system/minifi.service | ||
148 | |||
149 | sed -i 's|@MINIFI_LOG@|'${MINIFI_LOG}'|g' ${D}${sysconfdir}/tmpfiles.d/minifi.conf | ||
150 | |||
151 | elif ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then | ||
152 | install -d ${D}${sysconfdir}/default/volatiles | ||
153 | install -m 0644 ${WORKDIR}/sysvinit-volatile.conf ${D}${sysconfdir}/default/volatiles/99_minifi | ||
154 | |||
155 | sed -i 's|@MINIFI_LOG@|'${MINIFI_LOG}'|g' ${D}${sysconfdir}/default/volatiles/99_minifi | ||
156 | fi | ||
157 | } | ||
158 | |||
159 | pkg_postinst:${PN}() { | ||
160 | if [ -z "$D" ]; then | ||
161 | if type systemd-tmpfiles >/dev/null; then | ||
162 | systemd-tmpfiles --create | ||
163 | elif [ -e ${sysconfdir}/init.d/populate-volatile.sh ]; then | ||
164 | ${sysconfdir}/init.d/populate-volatile.sh update | ||
165 | fi | ||
166 | fi | ||
167 | } | ||
168 | |||
169 | CLEANBROKEN = "1" | ||