couchbase 4.4.2 → 4.4.4
Sign up to get free protection for your applications and to get access to all the features.
- package/BUILDING.md +182 -0
- package/CMakeLists.txt +13 -0
- package/CONTRIBUTING.md +1 -1
- package/README.md +4 -2
- package/deps/couchbase-cxx-cache/boringssl/e31ea00c1ea52052d2d78d44006cc88c80fa24a9/boringssl/src/BUILDING.md +206 -0
- package/deps/couchbase-cxx-client/CMakeLists.txt +18 -13
- package/deps/couchbase-cxx-client/README.md +2 -2
- package/deps/couchbase-cxx-client/cmake/APKBUILD.in +54 -0
- package/deps/couchbase-cxx-client/cmake/CompilerWarnings.cmake +0 -5
- package/deps/couchbase-cxx-client/cmake/Packaging.cmake +177 -10
- package/deps/couchbase-cxx-client/cmake/RPath.cmake +10 -0
- package/deps/couchbase-cxx-client/cmake/Testing.cmake +1 -1
- package/deps/couchbase-cxx-client/cmake/VersionInfo.cmake +28 -2
- package/deps/couchbase-cxx-client/cmake/build_version.hxx.in +1 -0
- package/deps/couchbase-cxx-client/cmake/couchbase-cxx-client.spec.in +45 -6
- package/deps/couchbase-cxx-client/cmake/couchbase_cxx_client.pc.in +2 -2
- package/deps/couchbase-cxx-client/cmake/debian/changelog.in +5 -0
- package/deps/couchbase-cxx-client/cmake/debian/compat +1 -0
- package/deps/couchbase-cxx-client/cmake/debian/control +40 -0
- package/deps/couchbase-cxx-client/cmake/debian/rules +41 -0
- package/deps/couchbase-cxx-client/cmake/debian/source/format +1 -0
- package/deps/couchbase-cxx-client/core/agent_group.cxx +8 -0
- package/deps/couchbase-cxx-client/core/agent_group.hxx +4 -0
- package/deps/couchbase-cxx-client/core/bucket.cxx +16 -20
- package/deps/couchbase-cxx-client/core/bucket.hxx +12 -12
- package/deps/couchbase-cxx-client/core/cluster.cxx +44 -52
- package/deps/couchbase-cxx-client/core/cluster_agent.cxx +8 -0
- package/deps/couchbase-cxx-client/core/cluster_agent.hxx +4 -0
- package/deps/couchbase-cxx-client/core/collections_component.cxx +2 -2
- package/deps/couchbase-cxx-client/core/columnar/agent.cxx +2 -2
- package/deps/couchbase-cxx-client/core/columnar/agent.hxx +1 -1
- package/deps/couchbase-cxx-client/core/columnar/management_component.cxx +3 -3
- package/deps/couchbase-cxx-client/core/columnar/query_component.cxx +103 -45
- package/deps/couchbase-cxx-client/core/columnar/query_component.hxx +1 -0
- package/deps/couchbase-cxx-client/core/free_form_http_request.hxx +8 -0
- package/deps/couchbase-cxx-client/core/http_component.cxx +55 -24
- package/deps/couchbase-cxx-client/core/http_component.hxx +4 -0
- package/deps/couchbase-cxx-client/core/impl/analytics.cxx +1 -0
- package/deps/couchbase-cxx-client/core/impl/analytics_index_manager.cxx +15 -15
- package/deps/couchbase-cxx-client/core/impl/bootstrap_error.hxx +10 -2
- package/deps/couchbase-cxx-client/core/impl/bucket.cxx +1 -1
- package/deps/couchbase-cxx-client/core/impl/bucket_manager.cxx +6 -6
- package/deps/couchbase-cxx-client/core/impl/cluster.cxx +36 -40
- package/deps/couchbase-cxx-client/core/impl/collection.cxx +29 -5
- package/deps/couchbase-cxx-client/core/impl/collection_manager.cxx +5 -5
- package/deps/couchbase-cxx-client/core/impl/error.cxx +24 -3
- package/deps/couchbase-cxx-client/core/impl/get_replica.hxx +2 -0
- package/deps/couchbase-cxx-client/core/impl/lookup_in_replica.hxx +2 -0
- package/deps/couchbase-cxx-client/core/impl/observe_poll.cxx +13 -5
- package/deps/couchbase-cxx-client/core/impl/observe_poll.hxx +1 -3
- package/deps/couchbase-cxx-client/core/impl/observe_seqno.hxx +2 -0
- package/deps/couchbase-cxx-client/core/impl/query.cxx +1 -0
- package/deps/couchbase-cxx-client/core/impl/query_index_manager.cxx +6 -6
- package/deps/couchbase-cxx-client/core/impl/scan_result.cxx +1 -1
- package/deps/couchbase-cxx-client/core/impl/search.cxx +2 -0
- package/deps/couchbase-cxx-client/core/impl/search_index_manager.cxx +12 -12
- package/deps/couchbase-cxx-client/core/io/http_command.hxx +31 -20
- package/deps/couchbase-cxx-client/core/io/http_session.cxx +5 -0
- package/deps/couchbase-cxx-client/core/io/http_session.hxx +17 -4
- package/deps/couchbase-cxx-client/core/io/http_session_manager.hxx +97 -49
- package/deps/couchbase-cxx-client/core/io/mcbp_command.hxx +15 -14
- package/deps/couchbase-cxx-client/core/io/mcbp_session.cxx +48 -33
- package/deps/couchbase-cxx-client/core/io/streams.cxx +256 -0
- package/deps/couchbase-cxx-client/core/io/streams.hxx +31 -155
- package/deps/couchbase-cxx-client/core/logger/configuration.hxx +5 -0
- package/deps/couchbase-cxx-client/core/logger/custom_rotating_file_sink.cxx +2 -3
- package/deps/couchbase-cxx-client/core/logger/logger.cxx +39 -7
- package/deps/couchbase-cxx-client/core/logger/logger.hxx +7 -0
- package/deps/couchbase-cxx-client/core/meta/features.hxx +11 -0
- package/deps/couchbase-cxx-client/core/meta/version.cxx +47 -6
- package/deps/couchbase-cxx-client/core/metrics/meter_wrapper.cxx +188 -0
- package/deps/couchbase-cxx-client/core/metrics/meter_wrapper.hxx +73 -0
- package/deps/couchbase-cxx-client/core/operations/document_analytics.cxx +23 -17
- package/deps/couchbase-cxx-client/core/operations/document_analytics.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/document_append.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_decrement.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_exists.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get_all_replicas.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get_and_lock.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get_and_touch.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get_any_replica.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get_projected.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_increment.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_insert.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_lookup_in.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_lookup_in_all_replicas.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_lookup_in_any_replica.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_mutate_in.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_prepend.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_query.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/document_remove.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_replace.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_search.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/document_touch.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_unlock.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_upsert.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_view.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/http_noop.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_dataset_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_dataset_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_dataset_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_dataverse_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_dataverse_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_get_pending_mutations.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_index_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_index_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_index_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_connect.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_disconnect.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_get_all.cxx +23 -15
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_get_all.hxx +4 -3
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_replace.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_describe.cxx +2 -1
- package/deps/couchbase-cxx-client/core/operations/management/bucket_describe.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_drop.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/bucket_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_flush.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/bucket_flush.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_get.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/bucket_get.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_update.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/bucket_update.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/change_password.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/cluster_describe.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/cluster_developer_preview_enable.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/collection_create.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/collection_create.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/collection_drop.cxx +5 -2
- package/deps/couchbase-cxx-client/core/operations/management/collection_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/collection_update.cxx +4 -2
- package/deps/couchbase-cxx-client/core/operations/management/collection_update.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/collections_manifest_get.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/eventing_deploy_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_drop_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_get_all_functions.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_get_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_get_status.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_pause_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_resume_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_undeploy_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_upsert_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/freeform.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/group_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/group_get.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/group_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/group_upsert.cxx +3 -3
- package/deps/couchbase-cxx-client/core/operations/management/group_upsert.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_build.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_build_deferred.hxx +3 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_get_all.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_get_all_deferred.hxx +3 -0
- package/deps/couchbase-cxx-client/core/operations/management/role_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/scope_create.cxx +2 -1
- package/deps/couchbase-cxx-client/core/operations/management/scope_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/scope_drop.cxx +4 -1
- package/deps/couchbase-cxx-client/core/operations/management/scope_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/scope_get_all.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/scope_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_get_stats.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_analyze_document.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_analyze_document.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_ingest.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_ingest.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_plan_freeze.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_plan_freeze.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_query.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_query.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_drop.cxx +5 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get.cxx +5 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get_all.cxx +4 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get_documents_count.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get_documents_count.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get_stats.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_upsert.cxx +5 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_upsert.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/user_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/user_get.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/user_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/user_upsert.cxx +3 -3
- package/deps/couchbase-cxx-client/core/operations/management/user_upsert.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/view_index_drop.cxx +2 -1
- package/deps/couchbase-cxx-client/core/operations/management/view_index_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/view_index_get.cxx +2 -1
- package/deps/couchbase-cxx-client/core/operations/management/view_index_get.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/view_index_get_all.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/view_index_get_all.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/view_index_upsert.cxx +2 -1
- package/deps/couchbase-cxx-client/core/operations/management/view_index_upsert.hxx +1 -0
- package/deps/couchbase-cxx-client/core/origin.cxx +37 -17
- package/deps/couchbase-cxx-client/core/platform/base64.cc +1 -1
- package/deps/couchbase-cxx-client/core/platform/random.cc +2 -0
- package/deps/couchbase-cxx-client/core/platform/uuid.h +6 -6
- package/deps/couchbase-cxx-client/core/row_streamer.cxx +1 -1
- package/deps/couchbase-cxx-client/core/sasl/scram-sha/stringutils.cc +1 -1
- package/deps/couchbase-cxx-client/core/sasl/scram-sha/stringutils.h +4 -4
- package/deps/couchbase-cxx-client/core/topology/configuration.hxx +2 -0
- package/deps/couchbase-cxx-client/core/topology/configuration_json.hxx +8 -0
- package/deps/couchbase-cxx-client/core/tracing/constants.hxx +3 -0
- package/deps/couchbase-cxx-client/core/tracing/tracer_wrapper.cxx +87 -0
- package/deps/couchbase-cxx-client/core/tracing/tracer_wrapper.hxx +57 -0
- package/deps/couchbase-cxx-client/core/transactions/async_attempt_context.hxx +9 -21
- package/deps/couchbase-cxx-client/core/transactions/attempt_context.hxx +6 -33
- package/deps/couchbase-cxx-client/core/transactions/attempt_context_impl.cxx +57 -56
- package/deps/couchbase-cxx-client/core/transactions/attempt_context_impl.hxx +17 -18
- package/deps/couchbase-cxx-client/core/transactions/staged_mutation.cxx +2 -2
- package/deps/couchbase-cxx-client/core/transactions/transaction_context.cxx +2 -2
- package/deps/couchbase-cxx-client/core/transactions/transaction_get_result.hxx +0 -20
- package/deps/couchbase-cxx-client/core/transactions/transactions.cxx +2 -2
- package/deps/couchbase-cxx-client/core/utils/connection_string.cxx +128 -52
- package/deps/couchbase-cxx-client/couchbase/analytics_options.hxx +4 -3
- package/deps/couchbase-cxx-client/couchbase/codec/tao_json_serializer.hxx +1 -1
- package/deps/couchbase-cxx-client/couchbase/common_options.hxx +16 -1
- package/deps/couchbase-cxx-client/couchbase/metrics/otel_meter.hxx +16 -20
- package/deps/couchbase-cxx-client/couchbase/mutate_in_specs.hxx +2 -2
- package/deps/couchbase-cxx-client/couchbase/query_options.hxx +4 -3
- package/deps/couchbase-cxx-client/couchbase/search_options.hxx +1 -1
- package/dist/analyticsindexmanager.d.ts +98 -14
- package/dist/analyticsindexmanager.js +452 -411
- package/dist/binding.d.ts +53 -4
- package/dist/bindingutilities.d.ts +26 -1
- package/dist/bindingutilities.js +108 -1
- package/dist/couchbase.d.ts +3 -1
- package/dist/couchbase.js +2 -0
- package/dist/rangeScan.d.ts +1 -1
- package/dist/rangeScan.js +1 -1
- package/dist/transactions.d.ts +34 -3
- package/dist/transactions.js +25 -18
- package/dist/transcoders.d.ts +68 -0
- package/dist/transcoders.js +194 -1
- package/dist/usermanager.d.ts +14 -14
- package/dist/usermanager.js +178 -228
- package/dist/utilities.js +4 -6
- package/dist/utilities_internal.js +1 -2
- package/package.json +9 -8
- package/src/binding.cpp +13 -13
- package/src/connection.cpp +22 -0
- package/src/connection.hpp +12 -0
- package/src/connection_autogen.cpp +100 -0
- package/src/jstocbpp_autogen.hpp +315 -8
- package/src/jstocbpp_transactions.hpp +1 -2
- package/tools/gen-bindings-js.js +38 -3
- package/tools/gen-bindings-json.py +575 -328
@@ -4,6 +4,7 @@ include(CMakePackageConfigHelpers)
|
|
4
4
|
install(DIRECTORY ${PROJECT_SOURCE_DIR}/couchbase DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
|
5
5
|
install(FILES LICENSE.txt DESTINATION ${CMAKE_INSTALL_DOCDIR})
|
6
6
|
|
7
|
+
set(COUCHBASE_CXX_CLIENT_PKGCONFIG_VERSION "${COUCHBASE_CXX_CLIENT_SEMVER}" CACHE STRING "The version to use in couchbase_cxx_client.pc")
|
7
8
|
configure_file(${PROJECT_SOURCE_DIR}/cmake/couchbase_cxx_client.pc.in
|
8
9
|
${PROJECT_BINARY_DIR}/packaging/couchbase_cxx_client.pc @ONLY)
|
9
10
|
install(FILES ${PROJECT_BINARY_DIR}/packaging/couchbase_cxx_client.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
|
@@ -40,9 +41,13 @@ set(COUCHBASE_CXX_CLIENT_MANIFEST "${PROJECT_BINARY_DIR}/packaging/MANIFEST")
|
|
40
41
|
if(APPLE)
|
41
42
|
find_program(TAR gtar)
|
42
43
|
find_program(SED gsed)
|
44
|
+
find_program(XARGS gxargs)
|
45
|
+
find_program(CP gcp)
|
43
46
|
else()
|
44
47
|
find_program(TAR tar)
|
45
48
|
find_program(SED sed)
|
49
|
+
find_program(XARGS xargs)
|
50
|
+
find_program(CP cp)
|
46
51
|
endif()
|
47
52
|
|
48
53
|
add_custom_command(
|
@@ -62,6 +67,7 @@ set(CPM_USE_LOCAL_PACKAGES OFF CACHE BOOL \"\" FORCE)
|
|
62
67
|
set(CPM_SOURCE_CACHE \"\${PROJECT_SOURCE_DIR}/third_party_cache\" CACHE STRING \"\" FORCE)
|
63
68
|
set(COUCHBASE_CXX_CLIENT_GIT_REVISION \"${COUCHBASE_CXX_CLIENT_GIT_REVISION}\")
|
64
69
|
set(COUCHBASE_CXX_CLIENT_GIT_DESCRIBE \"${COUCHBASE_CXX_CLIENT_GIT_DESCRIBE}\")
|
70
|
+
set(COUCHBASE_CXX_CLIENT_BUILD_TIMESTAMP \"${COUCHBASE_CXX_CLIENT_BUILD_TIMESTAMP}\")
|
65
71
|
set(COUCHBASE_CXX_CLIENT_EMBED_MOZILLA_CA_BUNDLE_ROOT \"\${PROJECT_SOURCE_DIR}/third_party_cache\" CACHE STRING \"\" FORCE)
|
66
72
|
message(STATUS \"Building from Tarball: ${COUCHBASE_CXX_CLIENT_TARBALL_NAME}.tar.gz\")
|
67
73
|
")
|
@@ -84,12 +90,12 @@ add_custom_command(
|
|
84
90
|
-DCPM_USE_LOCAL_PACKAGES=OFF -DCOUCHBASE_CXX_CLIENT_BUILD_STATIC=OFF -DCOUCHBASE_CXX_CLIENT_INSTALL=ON
|
85
91
|
-DCOUCHBASE_CXX_RECORD_BUILD_INFO_FOR_TARBALL=ON
|
86
92
|
COMMAND
|
87
|
-
|
93
|
+
${XARGS} --arg-file=${COUCHBASE_CXX_TARBALL_THIRD_PARTY_GLOB_FILE} -I {} find
|
88
94
|
"${COUCHBASE_CXX_CLIENT_TARBALL_NAME}/tmp/cache" -wholename "${COUCHBASE_CXX_CLIENT_TARBALL_NAME}/tmp/cache/{}"
|
89
95
|
-type f | grep -v "crypto_test_data\\|googletest" | uniq >
|
90
96
|
"${COUCHBASE_CXX_CLIENT_TARBALL_NAME}/tmp/third_party_manifest.txt"
|
91
97
|
COMMAND ${CMAKE_COMMAND} -E make_directory "${COUCHBASE_CXX_CLIENT_TARBALL_NAME}/tmp/filtered_cache"
|
92
|
-
COMMAND
|
98
|
+
COMMAND ${XARGS} --arg-file="${COUCHBASE_CXX_CLIENT_TARBALL_NAME}/tmp/third_party_manifest.txt" -I {} ${CP} --parents {}
|
93
99
|
"${COUCHBASE_CXX_CLIENT_TARBALL_NAME}/tmp/filtered_cache"
|
94
100
|
COMMAND
|
95
101
|
${CMAKE_COMMAND} -E rename
|
@@ -106,6 +112,116 @@ add_custom_command(
|
|
106
112
|
|
107
113
|
add_custom_target(packaging_tarball DEPENDS ${COUCHBASE_CXX_CLIENT_TARBALL})
|
108
114
|
|
115
|
+
option(COUCHBASE_CXX_CLIENT_DEB_TARGETS "Enable targets for building DEBs" FALSE)
|
116
|
+
if(COUCHBASE_CXX_CLIENT_DEB_TARGETS)
|
117
|
+
find_program(DPKG_BUILDPACKAGE dpkg-buildpackage REQUIRED) # apt install -y dpkg-dev
|
118
|
+
find_program(SUDO sudo REQUIRED) # apt install -y sudo
|
119
|
+
find_program(COWBUILDER cowbuilder REQUIRED) # apt install -y cowbuilder
|
120
|
+
|
121
|
+
string(TIMESTAMP COUCHBASE_CXX_CLIENT_DEB_DATE "%a, %d %b %Y %H:%M:%S %z" UTC)
|
122
|
+
|
123
|
+
file(MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/packaging/workspace/debian/source/")
|
124
|
+
|
125
|
+
set(COUCHBASE_CXX_CLIENT_DEBIAN_CHANGELOG "${PROJECT_BINARY_DIR}/packaging/workspace/debian/changelog")
|
126
|
+
configure_file(${PROJECT_SOURCE_DIR}/cmake/debian/changelog.in "${COUCHBASE_CXX_CLIENT_DEBIAN_CHANGELOG}" @ONLY)
|
127
|
+
|
128
|
+
file(COPY ${PROJECT_SOURCE_DIR}/cmake/debian/compat ${PROJECT_SOURCE_DIR}/cmake/debian/control
|
129
|
+
${PROJECT_SOURCE_DIR}/cmake/debian/rules DESTINATION "${PROJECT_BINARY_DIR}/packaging/workspace/debian/")
|
130
|
+
file(COPY ${PROJECT_SOURCE_DIR}/cmake/debian/source/format
|
131
|
+
DESTINATION "${PROJECT_BINARY_DIR}/packaging/workspace/debian/source/")
|
132
|
+
|
133
|
+
set(COUCHBASE_CXX_CLIENT_DEBIAN_ORIG_TARBALL
|
134
|
+
"${PROJECT_BINARY_DIR}/packaging/couchbase-cxx-client_${COUCHBASE_CXX_CLIENT_PACKAGE_VERSION}.orig.tar.gz")
|
135
|
+
add_custom_command(
|
136
|
+
OUTPUT ${COUCHBASE_CXX_CLIENT_DEBIAN_ORIG_TARBALL}
|
137
|
+
WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/packaging"
|
138
|
+
COMMAND ${CMAKE_COMMAND} -E copy "${COUCHBASE_CXX_CLIENT_TARBALL}" "${COUCHBASE_CXX_CLIENT_DEBIAN_ORIG_TARBALL}"
|
139
|
+
DEPENDS ${COUCHBASE_CXX_CLIENT_TARBALL})
|
140
|
+
|
141
|
+
set(COUCHBASE_CXX_CLIENT_DEBIAN_TARBALL_EXTRACTED "${PROJECT_BINARY_DIR}/packaging/tarball_extracted.txt")
|
142
|
+
add_custom_command(
|
143
|
+
OUTPUT ${COUCHBASE_CXX_CLIENT_DEBIAN_TARBALL_EXTRACTED}
|
144
|
+
WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/packaging/workspace"
|
145
|
+
COMMAND ${TAR} --strip-components=1 -xf "${COUCHBASE_CXX_CLIENT_TARBALL}"
|
146
|
+
COMMAND touch ${COUCHBASE_CXX_CLIENT_DEBIAN_TARBALL_EXTRACTED}
|
147
|
+
DEPENDS ${COUCHBASE_CXX_CLIENT_TARBALL})
|
148
|
+
|
149
|
+
set(COUCHBASE_CXX_CLIENT_DEBIAN_DSC
|
150
|
+
"${PROJECT_BINARY_DIR}/packaging/couchbase-cxx-client_${COUCHBASE_CXX_CLIENT_PACKAGE_VERSION}-${COUCHBASE_CXX_CLIENT_PACKAGE_RELEASE}.dsc"
|
151
|
+
)
|
152
|
+
add_custom_command(
|
153
|
+
OUTPUT ${COUCHBASE_CXX_CLIENT_DEBIAN_DSC}
|
154
|
+
WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/packaging/workspace"
|
155
|
+
COMMAND ${DPKG_BUILDPACKAGE} -us -uc
|
156
|
+
DEPENDS ${COUCHBASE_CXX_CLIENT_DEBIAN_ORIG_TARBALL} ${COUCHBASE_CXX_CLIENT_DEBIAN_TARBALL_EXTRACTED})
|
157
|
+
|
158
|
+
function(select_mirror_options distro options)
|
159
|
+
if(${distro} STREQUAL "bookworm")
|
160
|
+
set(${options}
|
161
|
+
--components
|
162
|
+
main
|
163
|
+
--mirror
|
164
|
+
https://ftp.debian.org/debian
|
165
|
+
PARENT_SCOPE)
|
166
|
+
else()
|
167
|
+
if(${CMAKE_SYSTEM_PROCESSOR} STREQUAL "aarch64")
|
168
|
+
set(${options}
|
169
|
+
--components
|
170
|
+
"main universe"
|
171
|
+
--mirror
|
172
|
+
http://ports.ubuntu.com/ubuntu-ports
|
173
|
+
PARENT_SCOPE)
|
174
|
+
else()
|
175
|
+
set(${options}
|
176
|
+
--components
|
177
|
+
"main universe"
|
178
|
+
--mirror
|
179
|
+
http://archive.ubuntu.com/ubuntu
|
180
|
+
PARENT_SCOPE)
|
181
|
+
endif()
|
182
|
+
endif()
|
183
|
+
endfunction()
|
184
|
+
|
185
|
+
set(cowbuilder_results "${PROJECT_BINARY_DIR}/packaging/results")
|
186
|
+
file(MAKE_DIRECTORY "${cowbuilder_results}")
|
187
|
+
|
188
|
+
list(
|
189
|
+
APPEND
|
190
|
+
COUCHBASE_CXX_CLIENT_SUPPORTED_DISTROS
|
191
|
+
"jammy"
|
192
|
+
"noble"
|
193
|
+
"bookworm")
|
194
|
+
|
195
|
+
set(cowbuilder_root "${PROJECT_BINARY_DIR}/packaging/root.cow")
|
196
|
+
set(last_output "")
|
197
|
+
foreach(distro ${COUCHBASE_CXX_CLIENT_SUPPORTED_DISTROS})
|
198
|
+
select_mirror_options(${distro} mirror_options)
|
199
|
+
set(timestamp "${PROJECT_BINARY_DIR}/packaging/${distro}_done.txt")
|
200
|
+
set(dependencies ${COUCHBASE_CXX_CLIENT_DEBIAN_DSC})
|
201
|
+
|
202
|
+
if(last_output)
|
203
|
+
list(APPEND dependencies ${last_output})
|
204
|
+
endif()
|
205
|
+
|
206
|
+
add_custom_command(
|
207
|
+
COMMENT "Building DEB for ${distro}"
|
208
|
+
OUTPUT ${timestamp}
|
209
|
+
WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/packaging"
|
210
|
+
COMMAND ${SUDO} ${CMAKE_COMMAND} -E rm -rf "${cowbuilder_root}"
|
211
|
+
COMMAND ${SUDO} ${COWBUILDER} --create --basepath "${cowbuilder_root}" --distribution ${distro} ${mirror_options}
|
212
|
+
COMMAND
|
213
|
+
${SUDO} ${COWBUILDER} --build --basepath "${cowbuilder_root}" --buildresult
|
214
|
+
"${cowbuilder_results}/couchbase-cxx-client-${COUCHBASE_CXX_CLIENT_PACKAGE_VERSION}-${COUCHBASE_CXX_CLIENT_PACKAGE_RELEASE}.${distro}.${CMAKE_SYSTEM_PROCESSOR}"
|
215
|
+
--debbuildopts -j8 --debbuildopts "-us -uc" ${COUCHBASE_CXX_CLIENT_DEBIAN_DSC}
|
216
|
+
COMMAND touch ${timestamp}
|
217
|
+
DEPENDS ${dependencies})
|
218
|
+
|
219
|
+
set(last_output ${timestamp})
|
220
|
+
endforeach()
|
221
|
+
|
222
|
+
add_custom_target(packaging_deb DEPENDS ${last_output})
|
223
|
+
endif()
|
224
|
+
|
109
225
|
option(COUCHBASE_CXX_CLIENT_RPM_TARGETS "Enable targets for building RPMs" FALSE)
|
110
226
|
if(COUCHBASE_CXX_CLIENT_RPM_TARGETS)
|
111
227
|
find_program(MOCK mock REQUIRED) # dnf install -y mock
|
@@ -131,22 +247,26 @@ if(COUCHBASE_CXX_CLIENT_RPM_TARGETS)
|
|
131
247
|
|
132
248
|
add_custom_target(packaging_srpm DEPENDS ${COUCHBASE_CXX_CLIENT_SRPM})
|
133
249
|
|
134
|
-
list(
|
250
|
+
list(
|
251
|
+
APPEND
|
252
|
+
COUCHBASE_CXX_CLIENT_SUPPORTED_ROOTS
|
253
|
+
"opensuse-leap-15.5-${CMAKE_SYSTEM_PROCESSOR}"
|
135
254
|
"rocky-9-${CMAKE_SYSTEM_PROCESSOR}"
|
255
|
+
"rocky-8-${CMAKE_SYSTEM_PROCESSOR}"
|
136
256
|
"amazonlinux-2023-${CMAKE_SYSTEM_PROCESSOR}"
|
137
|
-
|
257
|
+
"fedora-41-${CMAKE_SYSTEM_PROCESSOR}"
|
258
|
+
"fedora-40-${CMAKE_SYSTEM_PROCESSOR}")
|
138
259
|
|
139
260
|
message(STATUS "Supported build roots for RPM packages: ${COUCHBASE_CXX_CLIENT_SUPPORTED_ROOTS}")
|
140
261
|
|
141
|
-
# Build the chain of the dependencies from the timestamps, so that everything
|
142
|
-
#
|
143
|
-
# roots simultaneously
|
262
|
+
# Build the chain of the dependencies from the timestamps, so that everything will be executed one-by-one in order,
|
263
|
+
# because the mock cannot run multiple roots simultaneously
|
144
264
|
set(last_output "")
|
145
265
|
foreach(root ${COUCHBASE_CXX_CLIENT_SUPPORTED_ROOTS})
|
146
266
|
set(timestamp "${PROJECT_BINARY_DIR}/packaging/rpm/${root}/done.txt")
|
147
267
|
set(dependencies ${COUCHBASE_CXX_CLIENT_SRPM})
|
148
268
|
|
149
|
-
if
|
269
|
+
if(last_output)
|
150
270
|
list(APPEND dependencies ${last_output})
|
151
271
|
endif()
|
152
272
|
|
@@ -154,8 +274,8 @@ if(COUCHBASE_CXX_CLIENT_RPM_TARGETS)
|
|
154
274
|
COMMENT "Building RPM for ${root}"
|
155
275
|
OUTPUT ${timestamp}
|
156
276
|
WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/packaging"
|
157
|
-
COMMAND ${MOCK} --rebuild --root=${root}
|
158
|
-
|
277
|
+
COMMAND ${MOCK} --rebuild --root=${root} --resultdir=${PROJECT_BINARY_DIR}/packaging/rpm/${root}
|
278
|
+
"${COUCHBASE_CXX_CLIENT_SRPM}"
|
159
279
|
COMMAND touch ${timestamp}
|
160
280
|
DEPENDS ${dependencies})
|
161
281
|
|
@@ -165,3 +285,50 @@ if(COUCHBASE_CXX_CLIENT_RPM_TARGETS)
|
|
165
285
|
# add target that depends on the last root
|
166
286
|
add_custom_target(packaging_rpm DEPENDS ${last_output})
|
167
287
|
endif()
|
288
|
+
|
289
|
+
option(COUCHBASE_CXX_CLIENT_APK_TARGETS "Enable targets for building APKs (for Alpine Linux)" FALSE)
|
290
|
+
if(COUCHBASE_CXX_CLIENT_APK_TARGETS)
|
291
|
+
find_program(ABUILD abuild REQUIRED) # apk add alpine-sdk
|
292
|
+
|
293
|
+
set(COUCHBASE_CXX_CLIENT_TARBALL_NAME_ALPINE "${COUCHBASE_CXX_CLIENT_TARBALL_NAME}")
|
294
|
+
set(COUCHBASE_CXX_CLIENT_TARBALL_ALPINE
|
295
|
+
"${PROJECT_BINARY_DIR}/packaging/${COUCHBASE_CXX_CLIENT_TARBALL_NAME_ALPINE}.tar.gz")
|
296
|
+
if(${COUCHBASE_CXX_CLIENT_NUMBER_OF_COMMITS} GREATER 0)
|
297
|
+
set(COUCHBASE_CXX_CLIENT_TARBALL_NAME_ALPINE
|
298
|
+
"couchbase-cxx-client-${COUCHBASE_CXX_CLIENT_PACKAGE_VERSION}_p${COUCHBASE_CXX_CLIENT_NUMBER_OF_COMMITS}")
|
299
|
+
set(COUCHBASE_CXX_CLIENT_TARBALL_ALPINE
|
300
|
+
"${PROJECT_BINARY_DIR}/packaging/${COUCHBASE_CXX_CLIENT_TARBALL_NAME_ALPINE}.tar.gz")
|
301
|
+
endif()
|
302
|
+
|
303
|
+
set(cxxcbc_apkbuild_file "${PROJECT_BINARY_DIR}/packaging/APKBUILD")
|
304
|
+
configure_file(${PROJECT_SOURCE_DIR}/cmake/APKBUILD.in "${cxxcbc_apkbuild_file}" @ONLY)
|
305
|
+
|
306
|
+
if(NOT
|
307
|
+
"${COUCHBASE_CXX_CLIENT_TARBALL}"
|
308
|
+
STREQUAL
|
309
|
+
"${COUCHBASE_CXX_CLIENT_TARBALL_ALPINE}")
|
310
|
+
add_custom_command(
|
311
|
+
OUTPUT ${COUCHBASE_CXX_CLIENT_TARBALL_ALPINE}
|
312
|
+
WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/packaging"
|
313
|
+
COMMAND ${CMAKE_COMMAND} -E copy "${COUCHBASE_CXX_CLIENT_TARBALL}" "${COUCHBASE_CXX_CLIENT_TARBALL_ALPINE}"
|
314
|
+
DEPENDS ${COUCHBASE_CXX_CLIENT_TARBALL})
|
315
|
+
endif()
|
316
|
+
|
317
|
+
set(cxxcbc_apkbuild_checksum "${PROJECT_BINARY_DIR}/packaging/apk_checksum_updated.txt")
|
318
|
+
add_custom_command(
|
319
|
+
OUTPUT ${cxxcbc_apkbuild_checksum}
|
320
|
+
WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/packaging"
|
321
|
+
COMMAND ${ABUILD} checksum
|
322
|
+
COMMAND touch ${cxxcbc_apkbuild_checksum}
|
323
|
+
DEPENDS ${COUCHBASE_CXX_CLIENT_TARBALL_ALPINE} ${cxxcbc_apkbuild_file})
|
324
|
+
|
325
|
+
set(cxxcbc_apkbuild_timestamp "${PROJECT_BINARY_DIR}/packaging/apk_timestamp.txt")
|
326
|
+
add_custom_command(
|
327
|
+
OUTPUT ${cxxcbc_apkbuild_timestamp}
|
328
|
+
WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/packaging"
|
329
|
+
COMMAND ${ABUILD} -r
|
330
|
+
COMMAND touch ${cxxcbc_apkbuild_timestamp}
|
331
|
+
DEPENDS ${COUCHBASE_CXX_CLIENT_TARBALL_ALPINE} ${cxxcbc_apkbuild_checksum})
|
332
|
+
|
333
|
+
add_custom_target(packaging_apk DEPENDS ${cxxcbc_apkbuild_timestamp})
|
334
|
+
endif()
|
@@ -0,0 +1,10 @@
|
|
1
|
+
if(NOT MSVC)
|
2
|
+
if(APPLE)
|
3
|
+
set(CMAKE_MACOSX_RPATH ON)
|
4
|
+
endif()
|
5
|
+
set(CMAKE_INSTALL_RPATH_USE_LINK_PATH ON)
|
6
|
+
list(FIND CMAKE_PLATFORM_IMPLICIT_LINK_DIRECTORIES "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}" isSystemDir)
|
7
|
+
if("${isSystemDir}" STREQUAL "-1")
|
8
|
+
set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR})
|
9
|
+
endif()
|
10
|
+
endif()
|
@@ -15,7 +15,7 @@ if(COUCHBASE_CXX_CLIENT_ENABLE_VALGRIND)
|
|
15
15
|
if(VALGRIND)
|
16
16
|
set(VALGRIND_COMMAND "${VALGRIND}")
|
17
17
|
set(VALGRIND_COMMAND_OPTIONS
|
18
|
-
"-v --tool=memcheck --leak-check=full --track-fds=yes --num-callers=50 --show-reachable=yes --track-origins=yes --malloc-fill=0xff --free-fill=0xfe"
|
18
|
+
"-v --tool=memcheck --leak-check=full --track-fds=yes --num-callers=50 --show-reachable=yes --track-origins=yes --malloc-fill=0xff --free-fill=0xfe --suppressions=${PROJECT_SOURCE_DIR}/.valgrind_suppressions.txt"
|
19
19
|
)
|
20
20
|
set(MEMORYCHECK_COMMAND "${VALGRIND}")
|
21
21
|
set(MEMORYCHECK_COMMAND_OPTIONS "${VALGRIND_COMMAND_OPTIONS}")
|
@@ -24,8 +24,30 @@ if(NOT COUCHBASE_CXX_CLIENT_GIT_DESCRIBE)
|
|
24
24
|
endif()
|
25
25
|
endif()
|
26
26
|
|
27
|
-
|
28
|
-
|
27
|
+
if(NOT COUCHBASE_CXX_CLIENT_BUILD_TIMESTAMP)
|
28
|
+
if(GIT)
|
29
|
+
execute_process(
|
30
|
+
COMMAND git describe --tags --abbrev=0 HEAD
|
31
|
+
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
|
32
|
+
RESULT_VARIABLE tag_result
|
33
|
+
OUTPUT_STRIP_TRAILING_WHITESPACE
|
34
|
+
OUTPUT_VARIABLE last_tag)
|
35
|
+
|
36
|
+
if (tag_result EQUAL 0)
|
37
|
+
execute_process(
|
38
|
+
COMMAND git log --max-count=1 --no-patch --format=%cd --date=format:%Y-%m-%dT%H:%M:%S ${last_tag}
|
39
|
+
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
|
40
|
+
OUTPUT_STRIP_TRAILING_WHITESPACE
|
41
|
+
OUTPUT_VARIABLE COUCHBASE_CXX_CLIENT_BUILD_TIMESTAMP)
|
42
|
+
endif()
|
43
|
+
endif()
|
44
|
+
|
45
|
+
if (NOT COUCHBASE_CXX_CLIENT_BUILD_TIMESTAMP)
|
46
|
+
string(TIMESTAMP COUCHBASE_CXX_CLIENT_BUILD_TIMESTAMP "%Y-%m-%dT%H:%M:%S" UTC)
|
47
|
+
endif()
|
48
|
+
endif()
|
49
|
+
|
50
|
+
string(REGEX REPLACE "T.*" "" COUCHBASE_CXX_CLIENT_BUILD_DATE "${COUCHBASE_CXX_CLIENT_BUILD_TIMESTAMP}")
|
29
51
|
|
30
52
|
# set(couchbase_cxx_client_BUILD_NUMBER 142)
|
31
53
|
# set(COUCHBASE_CXX_CLIENT_GIT_DESCRIBE "1.0.0-beta.4-27-g6807da0") #-> "couchbase_cxx_client-1.0.0-beta.4+142.27.6807da0"
|
@@ -36,6 +58,7 @@ string(TIMESTAMP COUCHBASE_CXX_CLIENT_BUILD_DATE "%Y-%m-%d" UTC)
|
|
36
58
|
set(COUCHBASE_CXX_CLIENT_SEMVER "${couchbase_cxx_client_VERSION}")
|
37
59
|
set(COUCHBASE_CXX_CLIENT_PACKAGE_VERSION "${couchbase_cxx_client_VERSION}")
|
38
60
|
set(COUCHBASE_CXX_CLIENT_PACKAGE_RELEASE "${couchbase_cxx_client_BUILD_NUMBER}")
|
61
|
+
set(COUCHBASE_CXX_CLIENT_NUMBER_OF_COMMITS 0)
|
39
62
|
if(COUCHBASE_CXX_CLIENT_GIT_DESCRIBE MATCHES
|
40
63
|
"^([0-9]+\\.[0-9]+\\.[0-9]+)(-([a-zA-Z0-9\\.]+))?(-([0-9]+)-g([a-zA-Z0-9]+))?$")
|
41
64
|
set(COUCHBASE_CXX_CLIENT_SEMVER "${CMAKE_MATCH_1}")
|
@@ -45,6 +68,7 @@ if(COUCHBASE_CXX_CLIENT_GIT_DESCRIBE MATCHES
|
|
45
68
|
set(COUCHBASE_CXX_CLIENT_PACKAGE_RELEASE "${CMAKE_MATCH_3}.${couchbase_cxx_client_BUILD_NUMBER}")
|
46
69
|
endif()
|
47
70
|
if(CMAKE_MATCH_5 AND CMAKE_MATCH_5 GREATER 0) # number_of_commits.build_number.sha1
|
71
|
+
set(COUCHBASE_CXX_CLIENT_NUMBER_OF_COMMITS ${CMAKE_MATCH_5})
|
48
72
|
set(COUCHBASE_CXX_CLIENT_SEMVER
|
49
73
|
"${COUCHBASE_CXX_CLIENT_SEMVER}+${CMAKE_MATCH_5}.${couchbase_cxx_client_BUILD_NUMBER}.${CMAKE_MATCH_6}")
|
50
74
|
if(CMAKE_MATCH_3) # pre-release
|
@@ -56,6 +80,8 @@ if(COUCHBASE_CXX_CLIENT_GIT_DESCRIBE MATCHES
|
|
56
80
|
endif()
|
57
81
|
endif()
|
58
82
|
|
83
|
+
set(COUCHBASE_CXX_CLIENT_WRAPPER_UNIFIED_ID "" CACHE STRING "Unified ID for wrapper SDK formatted as '<name>/<version>'")
|
84
|
+
|
59
85
|
configure_file(${PROJECT_SOURCE_DIR}/cmake/build_version.hxx.in
|
60
86
|
${PROJECT_BINARY_DIR}/generated/couchbase/build_version.hxx @ONLY)
|
61
87
|
configure_file(${PROJECT_SOURCE_DIR}/cmake/build_config.hxx.in
|
@@ -32,5 +32,6 @@ constexpr auto COUCHBASE_CXX_CLIENT_VERSION_BUILD = @couchbase_cxx_client_BUILD_
|
|
32
32
|
constexpr auto COUCHBASE_CXX_CLIENT_GIT_REVISION = "@COUCHBASE_CXX_CLIENT_GIT_REVISION@";
|
33
33
|
constexpr auto COUCHBASE_CXX_CLIENT_GIT_REVISION_SHORT = "@COUCHBASE_CXX_CLIENT_GIT_REVISION_SHORT@";
|
34
34
|
constexpr auto COUCHBASE_CXX_CLIENT_GIT_DESCRIBE = "@COUCHBASE_CXX_CLIENT_GIT_DESCRIBE@";
|
35
|
+
constexpr auto COUCHBASE_CXX_CLIENT_WRAPPER_UNIFIED_ID = "@COUCHBASE_CXX_CLIENT_WRAPPER_UNIFIED_ID@";
|
35
36
|
#cmakedefine COUCHBASE_CXX_CLIENT_STATIC_STDLIB 1
|
36
37
|
#cmakedefine COUCHBASE_CXX_CLIENT_STATIC_OPENSSL 1
|
@@ -1,3 +1,9 @@
|
|
1
|
+
%if 0%{?suse_version}
|
2
|
+
%global license_dir %{_datadir}/doc
|
3
|
+
%else
|
4
|
+
%global license_dir %{_docdir}
|
5
|
+
%endif
|
6
|
+
|
1
7
|
Name: couchbase-cxx-client
|
2
8
|
Summary: Couchbase C++ SDK
|
3
9
|
Version: @COUCHBASE_CXX_CLIENT_PACKAGE_VERSION@
|
@@ -6,21 +12,31 @@ Vendor: Couchbase, Inc.
|
|
6
12
|
Packager: Couchbase SDK Team <support@couchbase.com>
|
7
13
|
License: ASL 2.0
|
8
14
|
URL: https://docs.couchbase.com/cxx-sdk/current/hello-world/overview.html
|
15
|
+
%if 0%{?suse_version} == 1500
|
16
|
+
BuildRequires: gcc13, gcc13-c++
|
17
|
+
%else
|
9
18
|
BuildRequires: gcc, gcc-c++
|
19
|
+
%endif
|
10
20
|
BuildRequires: cmake >= 3.19
|
11
21
|
Source0: @COUCHBASE_CXX_CLIENT_TARBALL_NAME@.tar.gz
|
12
22
|
|
23
|
+
%if 0%{?amzn}
|
24
|
+
# The additional linker flags break AmazonLinux
|
25
|
+
# https://bugzilla.redhat.com/show_bug.cgi?id=2043092
|
26
|
+
%undefine _package_note_flags
|
27
|
+
%endif
|
28
|
+
|
13
29
|
%description
|
14
30
|
This is the client and protocol library for Couchbase project.
|
15
31
|
|
16
32
|
%package tools
|
17
|
-
Summary: Couchbase C++ SDK
|
33
|
+
Summary: Couchbase C++ SDK, command line tools
|
18
34
|
Requires: %{name}%{?_isa} = %{version}-%{release}
|
19
35
|
%description -n %{name}-tools
|
20
36
|
CLI tools from the Couchbase C++ SDK.
|
21
37
|
|
22
38
|
%package devel
|
23
|
-
Summary: Couchbase C++ SDK
|
39
|
+
Summary: Couchbase C++ SDK, development files
|
24
40
|
Requires: %{name}%{?_isa} = %{version}-%{release}
|
25
41
|
%description devel
|
26
42
|
Development files for the Couchbase C++ SDK.
|
@@ -28,6 +44,13 @@ Development files for the Couchbase C++ SDK.
|
|
28
44
|
%prep
|
29
45
|
%autosetup -p1 -n@COUCHBASE_CXX_CLIENT_TARBALL_NAME@
|
30
46
|
%cmake \
|
47
|
+
%if 0%{?rhel} == 8 || 0%{?rocky} == 8 || 0%{?ol} == 8
|
48
|
+
-S "." -B "redhat-linux-build" \
|
49
|
+
%endif
|
50
|
+
%if 0%{?suse_version} == 1500
|
51
|
+
-DCMAKE_C_COMPILER=gcc-13 \
|
52
|
+
-DCMAKE_CXX_COMPILER=g++-13 \
|
53
|
+
%endif
|
31
54
|
-DBUILD_SHARED_LIBS=OFF \
|
32
55
|
-DCOUCHBASE_CXX_CLIENT_INSTALL=ON \
|
33
56
|
-DCOUCHBASE_CXX_CLIENT_STATIC_BORINGSSL=ON \
|
@@ -38,15 +61,32 @@ Development files for the Couchbase C++ SDK.
|
|
38
61
|
-DCOUCHBASE_CXX_CLIENT_BUILD_SHARED=ON
|
39
62
|
|
40
63
|
%build
|
64
|
+
%if 0%{?rhel} == 8 || 0%{?rocky} == 8 || 0%{?ol} == 8
|
65
|
+
/usr/bin/cmake --build "redhat-linux-build" -j${RPM_BUILD_NCPUS} --verbose
|
66
|
+
%else
|
67
|
+
%if 0%{?suse_version} == 1500
|
68
|
+
cd build
|
69
|
+
%endif
|
41
70
|
%cmake_build
|
71
|
+
%endif
|
42
72
|
|
43
73
|
%install
|
74
|
+
%if 0%{?rhel} == 8 || 0%{?rocky} == 8 || 0%{?ol} == 8
|
75
|
+
DESTDIR="%{buildroot}" /usr/bin/cmake --install "redhat-linux-build"
|
76
|
+
%else
|
44
77
|
%cmake_install
|
78
|
+
%endif
|
79
|
+
%if 0%{?suse_version} == 1500
|
80
|
+
%{__mkdir_p} %{buildroot}%{license_dir}/tao/json %{buildroot}%{_libdir}/cmake
|
81
|
+
%{__mv} %{buildroot}%{license_dir}/taocpp-json/tao/json/LICENSE %{buildroot}%{license_dir}/tao/json/LICENSE
|
82
|
+
%{__mv} %{buildroot}%{_datadir}/taocpp-json/cmake %{buildroot}%{_libdir}/cmake/taocpp-json
|
83
|
+
%{__mv} %{buildroot}%{_datadir}/pegtl/cmake %{buildroot}%{_libdir}/cmake/pegtl
|
84
|
+
%endif
|
45
85
|
|
46
86
|
%files
|
47
|
-
%license %{
|
48
|
-
%license %{
|
49
|
-
%license %{
|
87
|
+
%license %{license_dir}/couchbase_cxx_client/LICENSE.txt
|
88
|
+
%license %{license_dir}/tao/pegtl/LICENSE
|
89
|
+
%license %{license_dir}/tao/json/LICENSE
|
50
90
|
%{_libdir}/libcouchbase_cxx_client.so.*
|
51
91
|
|
52
92
|
%files tools
|
@@ -62,4 +102,3 @@ Development files for the Couchbase C++ SDK.
|
|
62
102
|
%changelog
|
63
103
|
* @COUCHBASE_CXX_CLIENT_RPM_DATE@ Couchbase SDK Team <support@couchbase.com> - @COUCHBASE_CXX_CLIENT_PACKAGE_VERSION@-@COUCHBASE_CXX_CLIENT_PACKAGE_RELEASE@
|
64
104
|
- Automated build.
|
65
|
-
%{_libdir}/libcouchbase_cxx_client_static.a
|
@@ -3,8 +3,8 @@ exec_prefix=@CMAKE_INSTALL_PREFIX@
|
|
3
3
|
includedir=@CMAKE_INSTALL_PREFIX@/include
|
4
4
|
libdir=@CMAKE_INSTALL_LIBDIR@
|
5
5
|
|
6
|
-
Name: couchbase-cxx-client @
|
6
|
+
Name: couchbase-cxx-client @COUCHBASE_CXX_CLIENT_PKGCONFIG_VERSION@
|
7
7
|
Description: Couchbase C++ SDK
|
8
|
-
Version: @
|
8
|
+
Version: @COUCHBASE_CXX_CLIENT_PKGCONFIG_VERSION@
|
9
9
|
Libs: -L${libdir} -lcouchbase_cxx_client
|
10
10
|
Cflags: -I${includedir}
|
@@ -0,0 +1 @@
|
|
1
|
+
10
|
@@ -0,0 +1,40 @@
|
|
1
|
+
Source: couchbase-cxx-client
|
2
|
+
Section: libs
|
3
|
+
Priority: optional
|
4
|
+
Maintainer: Couchbase SDK Team <support@couchbase.com>
|
5
|
+
Build-Depends: debhelper (>= 9), cmake, pkg-config
|
6
|
+
Standards-Version: 4.5.0
|
7
|
+
Vcs-Browser: https://github.com/couchbase/couchbase-cxx-client
|
8
|
+
Vcs-Git: https://github.com/couchbase/couchbase-cxx-client.git
|
9
|
+
|
10
|
+
Package: couchbase-cxx-client
|
11
|
+
Architecture: any
|
12
|
+
Multi-Arch: same
|
13
|
+
Depends: ${shlibs:Depends}, ${misc:Depends}
|
14
|
+
Description: Couchbase C++ SDK.
|
15
|
+
This is the client and protocol library for Couchbase project.
|
16
|
+
|
17
|
+
Package: couchbase-cxx-client-tools
|
18
|
+
Architecture: any
|
19
|
+
Multi-Arch: same
|
20
|
+
Section: utils
|
21
|
+
Depends: couchbase-cxx-client (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}
|
22
|
+
Description: Couchbase C++ SDK, command line tools.
|
23
|
+
This is the command line tools for the client and protocol library for
|
24
|
+
Couchbase project.
|
25
|
+
|
26
|
+
Package: couchbase-cxx-client-dev
|
27
|
+
Architecture: any
|
28
|
+
Multi-Arch: same
|
29
|
+
Depends: couchbase-cxx-client (= ${binary:Version}), ${misc:Depends}
|
30
|
+
Description: Couchbase C++ SDK, development files.
|
31
|
+
This is the development files for the client and protocol library for
|
32
|
+
Couchbase project.
|
33
|
+
|
34
|
+
Package: couchbase-cxx-client-dbg
|
35
|
+
Architecture: any
|
36
|
+
Multi-Arch: same
|
37
|
+
Depends: couchbase-cxx-client (= ${binary:Version}), ${misc:Depends}
|
38
|
+
Description: Couchbase C++ SDK, debug symbols.
|
39
|
+
This is the debug symbols for the client and protocol library for Couchbase
|
40
|
+
project.
|
@@ -0,0 +1,41 @@
|
|
1
|
+
#!/usr/bin/make -f
|
2
|
+
|
3
|
+
%:
|
4
|
+
dh $@ --buildsystem=cmake
|
5
|
+
|
6
|
+
override_dh_strip:
|
7
|
+
dh_strip -pcouchbase-cxx-client-tools -pcouchbase-cxx-client --dbg-package=couchbase-cxx-client-dbg
|
8
|
+
dh_strip --remaining-packages
|
9
|
+
|
10
|
+
override_dh_auto_configure:
|
11
|
+
echo "usr/include/couchbase" \
|
12
|
+
> debian/couchbase-cxx-client-dev.install
|
13
|
+
echo "usr/lib/$(DEB_HOST_MULTIARCH)/libcouchbase_cxx_client.so" \
|
14
|
+
>> debian/couchbase-cxx-client-dev.install
|
15
|
+
echo "usr/lib/$(DEB_HOST_MULTIARCH)/cmake" \
|
16
|
+
>> debian/couchbase-cxx-client-dev.install
|
17
|
+
echo "usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig" \
|
18
|
+
>> debian/couchbase-cxx-client-dev.install
|
19
|
+
echo "usr/bin/*" \
|
20
|
+
> debian/couchbase-cxx-client-tools.install
|
21
|
+
echo "usr/lib/$(DEB_HOST_MULTIARCH)/libcouchbase_cxx_client.so.*" \
|
22
|
+
> debian/couchbase-cxx-client.install
|
23
|
+
echo "usr/share/doc/tao/json/LICENSE" \
|
24
|
+
>> debian/couchbase-cxx-client.install
|
25
|
+
echo "usr/share/doc/tao/pegtl/LICENSE" \
|
26
|
+
>> debian/couchbase-cxx-client.install
|
27
|
+
echo "usr/share/doc/couchbase_cxx_client/LICENSE.txt" \
|
28
|
+
>> debian/couchbase-cxx-client.install
|
29
|
+
dh_auto_configure -- \
|
30
|
+
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
|
31
|
+
-DBUILD_SHARED_LIBS=OFF \
|
32
|
+
-DCOUCHBASE_CXX_CLIENT_INSTALL=ON \
|
33
|
+
-DCOUCHBASE_CXX_CLIENT_STATIC_BORINGSSL=ON \
|
34
|
+
-DCOUCHBASE_CXX_CLIENT_BUILD_EXAMPLES=OFF \
|
35
|
+
-DCOUCHBASE_CXX_CLIENT_BUILD_TESTS=OFF \
|
36
|
+
-DCOUCHBASE_CXX_CLIENT_BUILD_TOOLS=ON \
|
37
|
+
-DCOUCHBASE_CXX_CLIENT_BUILD_STATIC=OFF \
|
38
|
+
-DCOUCHBASE_CXX_CLIENT_BUILD_SHARED=ON
|
39
|
+
|
40
|
+
override_dh_auto_build:
|
41
|
+
dh_auto_build
|
@@ -0,0 +1 @@
|
|
1
|
+
3.0 (quilt)
|
@@ -132,7 +132,11 @@ public:
|
|
132
132
|
|
133
133
|
auto free_form_http_request(const http_request& request,
|
134
134
|
free_form_http_request_callback&& callback)
|
135
|
+
#ifdef COUCHBASE_CXX_CLIENT_COLUMNAR
|
136
|
+
-> tl::expected<std::shared_ptr<pending_operation>, error_union>
|
137
|
+
#else
|
135
138
|
-> tl::expected<std::shared_ptr<pending_operation>, std::error_code>
|
139
|
+
#endif
|
136
140
|
{
|
137
141
|
return cluster_agent_.free_form_http_request(request, std::move(callback));
|
138
142
|
}
|
@@ -221,7 +225,11 @@ agent_group::search_query(const search_query_options& options, search_query_call
|
|
221
225
|
auto
|
222
226
|
agent_group::free_form_http_request(const http_request& request,
|
223
227
|
free_form_http_request_callback&& callback)
|
228
|
+
#ifdef COUCHBASE_CXX_CLIENT_COLUMNAR
|
229
|
+
-> tl::expected<std::shared_ptr<pending_operation>, error_union>
|
230
|
+
#else
|
224
231
|
-> tl::expected<std::shared_ptr<pending_operation>, std::error_code>
|
232
|
+
#endif
|
225
233
|
{
|
226
234
|
return impl_->free_form_http_request(request, std::move(callback));
|
227
235
|
}
|
@@ -70,7 +70,11 @@ public:
|
|
70
70
|
|
71
71
|
auto free_form_http_request(const http_request& request,
|
72
72
|
free_form_http_request_callback&& callback)
|
73
|
+
#ifdef COUCHBASE_CXX_CLIENT_COLUMNAR
|
74
|
+
-> tl::expected<std::shared_ptr<pending_operation>, error_union>;
|
75
|
+
#else
|
73
76
|
-> tl::expected<std::shared_ptr<pending_operation>, std::error_code>;
|
77
|
+
#endif
|
74
78
|
|
75
79
|
auto wait_until_ready(std::chrono::milliseconds timeout,
|
76
80
|
const wait_until_ready_options& options,
|