This is an automated email from the ASF dual-hosted git repository.
sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-crypto.git
The following commit(s) were added to refs/heads/master by this push:
new 5a7426b7 Documentation on distribution builds [skip ci]
5a7426b7 is described below
commit 5a7426b72c8f0f4fe5e6be9b101572f4e0abba14
Author: Sebb <[email protected]>
AuthorDate: Fri Nov 24 22:55:41 2023 +0000
Documentation on distribution builds [skip ci]
---
BUILDING.txt | 7 ++++++-
build_dist.sh | 30 ++++++++++++++++++++++++++++++
2 files changed, 36 insertions(+), 1 deletion(-)
diff --git a/BUILDING.txt b/BUILDING.txt
index abd1b1ab..d7187a31 100644
--- a/BUILDING.txt
+++ b/BUILDING.txt
@@ -107,5 +107,10 @@ File menu: Choose Import..., select "Existing Maven
Project".
----------------------------------------------------------------------------------
Building distributions:
-Please read http://commons.apache.org/releases/index.html
+Commons Crypto includes a native code component that must be built for
multiple hardware architectures and operating systems.
+These library files are then bundled into the binary jar.
+Building currently requires macOS and Docker, and uses the script:
build_dist.sh
+
+
+For the general release process, please read
http://commons.apache.org/releases/index.html
diff --git a/build_dist.sh b/build_dist.sh
new file mode 100755
index 00000000..b2cfc4e2
--- /dev/null
+++ b/build_dist.sh
@@ -0,0 +1,30 @@
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License. See accompanying LICENSE file.
+
+# script to build native libraries
+# requires Docker and macOS
+
+mvn clean
+
+# build linux 64 bit libraries
+docker compose -f src/docker/docker-compose.yaml run crypto src/docker/build.sh
+
+# build linux 32 bit libraries
+docker compose -f src/docker/docker-compose.yaml run crypto
src/docker/build_linux32.sh
+
+# build 64 bit macOS libraries
+mvn -DskipTests -Drat.skip process-classes -Dtarget.name=mac64
+mvn -DskipTests -Drat.skip process-classes -Dtarget.name=macArm64
+mvn -DskipTests -Drat.skip process-classes -Dtarget.name=mac-aarch64
+
+# package it all up
+mvn package -DskipTests