summaryrefslogtreecommitdiff
path: root/README_packaging.md
diff options
context:
space:
mode:
authorMate Szalay-Beko <szalay.beko.mate@gmail.com>2019-12-14 09:29:51 +0100
committerEnrico Olivelli <eolivelli@apache.org>2019-12-14 09:29:51 +0100
commitac9cecf2a41214d6ee2401df849a155dc877dc45 (patch)
treeb57b7805381b17273f98b5b15c249765c8177420 /README_packaging.md
parenta5d67c8ffcc18289aa89c892d948ad7c75a317b4 (diff)
downloadzookeeper-ac9cecf2a41214d6ee2401df849a155dc877dc45.tar.gz
ZOOKEEPER-3630: Autodetection of openssl during ZooKeeper C client build
**Thanks for ztzg for raising the issue and suggesting the solution!** In this patch we enhance the way how the openssl library is found during C client build. I introduced and documented a new build parameter for `configure` (`--with-openssl=...`), `cmake` (`-D WITH_OPENSSL=...`) and `mvn` (`-Dc-client-openssl=...`), so independent of the build tool, the build will work the same way: - By default, the OpenSSL library will be autodetected. If the library is found, then the C-client will be compiled with SSL support, otherwise we get a warning message, but the build will continue without SSL support. The SSL related unit tests will be skipped as well. - you can explicitly disable the SSL support (e.g. `-Dc-client-openssl=no`) - or you can specify an alternative path to look for the openssl library (e.g. `-Dc-client-openssl=/path/to/openssl`) I tested the patch - using mvn on linux - using make on linux - using cmake on linux and on windows In addition, I also added the openssl dependencies to the dev docker image and copied the OpenSSL license to the C client LICENSE file. Author: Mate Szalay-Beko <szalay.beko.mate@gmail.com> Reviewers: Enrico Olivelli <eolivelli@apache.org>, Norbert Kalmar <nkalmar@cloudera.com>, Damien Diederen Closes #1159 from symat/ZOOKEEPER-3630
Diffstat (limited to 'README_packaging.md')
-rw-r--r--README_packaging.md11
1 files changed, 9 insertions, 2 deletions
diff --git a/README_packaging.md b/README_packaging.md
index e2a2d4767..b290dd9f9 100644
--- a/README_packaging.md
+++ b/README_packaging.md
@@ -57,7 +57,13 @@ Optional parameters you might consider when using maven:
- `-Pfull-build` - activates the full-build profile, causing the C client to be built
- `-DskipTests` - this parameter will skip both java and C++ unit test execution during the build
- `-Pc-test-coverage` - activates the test coverage calculation during the execution of C client tests
-
+- `-Dc-client-openssl` - specify ssl support and openssl library location. Default value: `yes`, resulting in
+ the autodetection of the openssl library. If the openssl library will not be detected,
+ then a warning will be shown and the C client will be compiled without SSL support.
+ Use `-Dc-client-openssl=no` to explicitly disable SSL feature in C client. Or use
+ `-Dc-client-openssl=/path/to/openssl/` if you want to use a non-default / specific
+ openssl library location.
+
Please note: if you don't provide the `-Pfull-build` parameter, then the C client will not be built, the C client tests
will not be executed and the previous C client builds will no be cleaned up (e.g. with simply using `mvn clean`).
@@ -66,4 +72,5 @@ The compiled C client can be found here:
- `zookeeper-client/zookeeper-client-c/target/c/lib` - Native libraries
- `zookeeper-client/zookeeper-client-c/target/c/include/zookeeper` - Native library headers
-The same folders gets archived to the `zookeeper-assembly/target/apache-zookeeper-<version>-lib.tar.gz` file, assuming you activated the `full-build` maven profile.
+The same folders gets archived to the `zookeeper-assembly/target/apache-zookeeper-<version>-lib.tar.gz` file, assuming
+you activated the `full-build` maven profile.