summaryrefslogtreecommitdiff
path: root/databases/foundationdb/files
diff options
context:
space:
mode:
authorDave Cottlehuber <dch@FreeBSD.org>2022-01-04 11:07:33 +0000
committerDave Cottlehuber <dch@FreeBSD.org>2022-01-06 11:59:34 +0000
commitb79db1b778ee60e3d0346e7abcce394d1ae6c9c7 (patch)
tree372569a3fcf3ae45b7f534295b9c09adffbc3ad1 /databases/foundationdb/files
parentdevel/onetbb: Fix build on 13-STABLE and 14-CURRENT (diff)
databases/foundationdb: update to 7.0.0
Diffstat (limited to 'databases/foundationdb/files')
-rw-r--r--databases/foundationdb/files/patch-CMakeLists.txt18
-rw-r--r--databases/foundationdb/files/patch-bindings_c_CMakeLists.txt16
-rw-r--r--databases/foundationdb/files/patch-bindings_c_generate__asm.py29
-rw-r--r--databases/foundationdb/files/patch-bindings_c_test_unit_third__party_CMakeLists.txt22
-rw-r--r--databases/foundationdb/files/patch-cmake_ConfigureCompiler.cmake11
-rw-r--r--databases/foundationdb/files/patch-cmake_FDBComponents.cmake34
-rw-r--r--databases/foundationdb/files/patch-flow_Platform.h24
7 files changed, 82 insertions, 72 deletions
diff --git a/databases/foundationdb/files/patch-CMakeLists.txt b/databases/foundationdb/files/patch-CMakeLists.txt
new file mode 100644
index 000000000000..c39b3c3eb46e
--- /dev/null
+++ b/databases/foundationdb/files/patch-CMakeLists.txt
@@ -0,0 +1,18 @@
+--- CMakeLists.txt.orig 2021-12-29 09:04:08 UTC
++++ CMakeLists.txt
+@@ -172,9 +172,13 @@ else()
+ add_subdirectory(fdbservice)
+ endif()
+ add_subdirectory(fdbbackup)
+-add_subdirectory(contrib)
++if(WITH_CONTRIB)
++ add_subdirectory(contrib)
++endif()
+ add_subdirectory(tests)
+-add_subdirectory(flowbench EXCLUDE_FROM_ALL)
++if(WITH_FLOWBENCH)
++ add_subdirectory(flowbench EXCLUDE_FROM_ALL)
++endif()
+ if(WITH_PYTHON AND WITH_C_BINDING)
+ add_subdirectory(bindings)
+ endif()
diff --git a/databases/foundationdb/files/patch-bindings_c_CMakeLists.txt b/databases/foundationdb/files/patch-bindings_c_CMakeLists.txt
index 03c484c00465..c05798bb5aaa 100644
--- a/databases/foundationdb/files/patch-bindings_c_CMakeLists.txt
+++ b/databases/foundationdb/files/patch-bindings_c_CMakeLists.txt
@@ -1,11 +1,11 @@
---- bindings/c/CMakeLists.txt.orig 2021-11-06 16:00:16 UTC
+--- bindings/c/CMakeLists.txt.orig 2021-12-29 13:15:46 UTC
+++ bindings/c/CMakeLists.txt
-@@ -15,6 +15,8 @@ elseif(WIN32)
- set(asm_file ${CMAKE_CURRENT_BINARY_DIR}/fdb_c.g.asm)
- elseif(CMAKE_SYSTEM_NAME MATCHES "Linux" AND CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64")
- set(platform "linux-aarch64")
-+elseif(CMAKE_SYSTEM_NAME MATCHES "FreeBSD" AND CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64")
-+ set(platform "freebsd-aarch64")
+@@ -65,7 +65,7 @@ if(WIN32)
endif()
- add_custom_command(OUTPUT ${asm_file} ${CMAKE_CURRENT_BINARY_DIR}/fdb_c_function_pointers.g.h
+ # The tests don't build on windows
+-if(NOT WIN32)
++if(NOT WIN32 AND NOT CMAKE_SYSTEM_NAME STREQUAL "FreeBSD")
+ set(MAKO_SRCS
+ test/mako/mako.c
+ test/mako/mako.h
diff --git a/databases/foundationdb/files/patch-bindings_c_generate__asm.py b/databases/foundationdb/files/patch-bindings_c_generate__asm.py
deleted file mode 100644
index dfc0c350a770..000000000000
--- a/databases/foundationdb/files/patch-bindings_c_generate__asm.py
+++ /dev/null
@@ -1,29 +0,0 @@
---- bindings/c/generate_asm.py.orig 2021-11-06 16:01:37 UTC
-+++ bindings/c/generate_asm.py
-@@ -59,7 +59,7 @@ def write_windows_asm(asmfile, functions):
-
-
- def write_unix_asm(asmfile, functions, prefix):
-- if platform != "linux-aarch64":
-+ if platform != "freebsd-aarch64" and platform != "linux-aarch64":
- asmfile.write(".intel_syntax noprefix\n")
-
- if platform.startswith('linux') or platform == "freebsd":
-@@ -104,7 +104,7 @@ def write_unix_asm(asmfile, functions, prefix):
- # .sizeg, .-g
- # .ident"GCC: (GNU) 8.3.1 20190311 (Red Hat 8.3.1-3)"
-
-- if platform == "linux-aarch64":
-+ if platform == "freebsd-aarch64" or platform == "linux-aarch64":
- asmfile.write("\tadrp x8, :got:fdb_api_ptr_%s\n" % (f))
- asmfile.write("\tldr x8, [x8, #:got_lo12:fdb_api_ptr_%s]\n" % (f))
- asmfile.write("\tldr x8, [x8]\n")
-@@ -123,7 +123,7 @@ with open(asm, 'w') as asmfile:
- hfile.write(
- "void fdb_api_ptr_removed() { fprintf(stderr, \"REMOVED FDB API FUNCTION\\n\"); abort(); }\n\n")
-
-- if platform.startswith('linux'):
-+ if platform.startswith('freebsd') or platform.startswith('linux'):
- write_unix_asm(asmfile, functions, '')
- elif platform == "osx":
- write_unix_asm(asmfile, functions, '_')
diff --git a/databases/foundationdb/files/patch-bindings_c_test_unit_third__party_CMakeLists.txt b/databases/foundationdb/files/patch-bindings_c_test_unit_third__party_CMakeLists.txt
new file mode 100644
index 000000000000..4deeb8410767
--- /dev/null
+++ b/databases/foundationdb/files/patch-bindings_c_test_unit_third__party_CMakeLists.txt
@@ -0,0 +1,22 @@
+--- bindings/c/test/unit/third_party/CMakeLists.txt.orig 2021-12-07 03:03:34 UTC
++++ bindings/c/test/unit/third_party/CMakeLists.txt
+@@ -1,18 +1 @@
+-# Download doctest repo.
+-include(ExternalProject)
+-find_package(Git REQUIRED)
+-
+-ExternalProject_Add(
+- doctest
+- PREFIX ${CMAKE_BINARY_DIR}/doctest
+- GIT_REPOSITORY https://github.com/onqtam/doctest.git
+- GIT_TAG 1c8da00c978c19e00a434b2b1f854fcffc9fba35 # v2.4.0
+- TIMEOUT 10
+- CONFIGURE_COMMAND ""
+- BUILD_COMMAND ""
+- INSTALL_COMMAND ""
+- LOG_DOWNLOAD ON
+-)
+-
+-ExternalProject_Get_Property(doctest source_dir)
+-set(DOCTEST_INCLUDE_DIR ${source_dir}/doctest CACHE INTERNAL "Path to include folder for doctest")
++set(DOCTEST_INCLUDE_DIR /usr/local/include/doctest CACHE INTERNAL "Path to include folder for doctest")
diff --git a/databases/foundationdb/files/patch-cmake_ConfigureCompiler.cmake b/databases/foundationdb/files/patch-cmake_ConfigureCompiler.cmake
deleted file mode 100644
index 99b8e24c6765..000000000000
--- a/databases/foundationdb/files/patch-cmake_ConfigureCompiler.cmake
+++ /dev/null
@@ -1,11 +0,0 @@
---- cmake/ConfigureCompiler.cmake.orig 2021-10-21 22:10:27 UTC
-+++ cmake/ConfigureCompiler.cmake
-@@ -233,7 +233,7 @@ else()
- if (STATIC_LINK_LIBCXX)
- add_link_options(-static-libgcc -nostdlib++ -Wl,-Bstatic -lc++ -lc++abi -Wl,-Bdynamic)
- endif()
-- add_link_options(-stdlib=libc++ -Wl,-build-id=sha1)
-+ add_link_options(-Wl,-z,notext)
- endif()
- endif()
- if (OPEN_FOR_IDE)
diff --git a/databases/foundationdb/files/patch-cmake_FDBComponents.cmake b/databases/foundationdb/files/patch-cmake_FDBComponents.cmake
new file mode 100644
index 000000000000..e4b75371774d
--- /dev/null
+++ b/databases/foundationdb/files/patch-cmake_FDBComponents.cmake
@@ -0,0 +1,34 @@
+--- cmake/FDBComponents.cmake.orig 2021-12-07 03:03:34 UTC
++++ cmake/FDBComponents.cmake
+@@ -24,7 +24,7 @@ set(DISABLE_TLS OFF CACHE BOOL "Don't try to find Open
+ if(DISABLE_TLS)
+ set(WITH_TLS OFF)
+ else()
+- set(OPENSSL_USE_STATIC_LIBS TRUE)
++ set(OPENSSL_USE_STATIC_LIBS FALSE)
+ find_package(OpenSSL)
+ if(OPENSSL_FOUND)
+ set(CMAKE_REQUIRED_INCLUDES ${OPENSSL_INCLUDE_DIR})
+@@ -203,6 +203,13 @@ else()
+ endif()
+
+ ################################################################################
++# misc optional components
++################################################################################
++
++set(WITH_CONTRIB ON)
++set(WITH_FLOWBENCH OFF)
++
++################################################################################
+ # Coroutine implementation
+ ################################################################################
+
+@@ -236,6 +243,8 @@ function(print_components)
+ message(STATUS "Build Documentation (make html): ${WITH_DOCUMENTATION}")
+ message(STATUS "Build Python sdist (make package): ${WITH_PYTHON_BINDING}")
+ message(STATUS "Configure CTest (depends on Python): ${WITH_PYTHON}")
++ message(STATUS "Build contrib: ${WITH_CONTRIB}")
++ message(STATUS "Build with FlowBench: ${WITH_FLOWBENCH}")
+ message(STATUS "Build with RocksDB: ${WITH_ROCKSDB_EXPERIMENTAL}")
+ message(STATUS "=========================================")
+ endfunction()
diff --git a/databases/foundationdb/files/patch-flow_Platform.h b/databases/foundationdb/files/patch-flow_Platform.h
deleted file mode 100644
index 7332d3bded60..000000000000
--- a/databases/foundationdb/files/patch-flow_Platform.h
+++ /dev/null
@@ -1,24 +0,0 @@
---- flow/Platform.h.orig 2021-10-21 22:10:27 UTC
-+++ flow/Platform.h
-@@ -434,6 +434,12 @@ dev_t getDeviceId(std::string path);
- #include <features.h>
- #include <sys/stat.h>
- #endif
-+#ifdef __freebsd__
-+#ifndef __aarch64__
-+#include <x86intrin.h>
-+#else
-+#include "sse2neon.h"
-+#endif
-
- #if defined(__APPLE__)
- // Version of CLang bundled with XCode doesn't yet include ia32intrin.h.
-@@ -459,7 +465,7 @@ inline static uint64_t timestampCounter() {
- #define timestampCounter() __rdtsc()
- #endif
-
--#ifdef __FreeBSD__
-+#if defined(__FreeBSD__) && !defined(__aarch64__)
- #if !(__has_builtin(__rdtsc))
- inline static uint64_t __rdtsc() {
- uint64_t lo, hi;