This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/main by this push:
     new 7dbed41d83 Include NSIS src in the distribution download
7dbed41d83 is described below

commit 7dbed41d831dccb66218159f696880ee5fcd1748
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Mon Mar 3 16:38:17 2025 +0000

    Include NSIS src in the distribution download
---
 BUILDING.txt             |  9 +++++----
 build.properties.default | 24 ++++++++++++++----------
 build.xml                | 40 +++++++++++++++++++++++++++++++++-------
 3 files changed, 52 insertions(+), 21 deletions(-)

diff --git a/BUILDING.txt b/BUILDING.txt
index 03ea8dbaff..12fcd7b9f1 100644
--- a/BUILDING.txt
+++ b/BUILDING.txt
@@ -341,12 +341,13 @@ in build.xml and the default property values in 
build.properties.default.
     in build.properties.default.
 
     Download and extract NSIS for Windows by running "ant download-dist". Note
-    the NSIS installation path from the output or by checking "nsis.home" in
+    the NSIS installation path from the output or by checking "nsis.bin.home" 
in
     build.properties.default. For example by default:
-    nsis.home=${base.path}/nsis-${nsis.version}
+    nsis.bin.home=${base.path}/nsis-${nsis.version}
 
-    Download the corresponding sources from the same site at:
-    ${base-sf.loc}/nsis/nsis-${nsis.version}-src.tar.bz2
+    The corresponding sources will be downloaded to "nsis.src.home" in 
+    build.properties.default. For example by default:
+    nsis.src.home=${base.path}/nsis-${nsis.version}-src
 
     Install the scons Python software construction tool.
 
diff --git a/build.properties.default b/build.properties.default
index 1a47ed9bbf..cf4d5c258e 100644
--- a/build.properties.default
+++ b/build.properties.default
@@ -173,17 +173,21 @@ 
tomcat-native.win.2=${base-tomcat.loc.2}/tomcat-connectors/native/${tomcat-nativ
 # ----- NSIS, version 3.0 or later -----
 nsis.version=3.10
 nsis.checksum.enabled=true
-nsis.checksum.algorithm=MD5|SHA-1
-nsis.checksum.value=e3e2803a13ead75e4471a51069d04c20|22cf776b463c6c845444328341219167abf399dc
-nsis.home=${base.path}/nsis-${nsis.version}
-nsis.exe=${nsis.home}/makensis.exe
+nsis.bin.checksum.algorithm=MD5|SHA-1
+nsis.bin.checksum.value=e3e2803a13ead75e4471a51069d04c20|22cf776b463c6c845444328341219167abf399dc
+nsis.bin.home=${base.path}/nsis-${nsis.version}
+nsis.exe=${nsis.bin.home}/makensis.exe
 nsis.arch.dir=x86-unicode/
-nsis.installoptions.dll=${nsis.home}/Plugins/${nsis.arch.dir}InstallOptions.dll
-nsis.nsexec.dll=${nsis.home}/Plugins/${nsis.arch.dir}nsExec.dll
-nsis.nsisdl.dll=${nsis.home}/Plugins/${nsis.arch.dir}NSISdl.dll
-nsis.system.dll=${nsis.home}/Plugins/${nsis.arch.dir}System.dll
-nsis.nsdialogs.dll=${nsis.home}/Plugins/${nsis.arch.dir}nsDialogs.dll
-nsis.loc=${base-sf.loc}/nsis/nsis-${nsis.version}.zip
+nsis.installoptions.dll=${nsis.bin.home}/Plugins/${nsis.arch.dir}InstallOptions.dll
+nsis.nsexec.dll=${nsis.bin.home}/Plugins/${nsis.arch.dir}nsExec.dll
+nsis.nsisdl.dll=${nsis.bin.home}/Plugins/${nsis.arch.dir}NSISdl.dll
+nsis.system.dll=${nsis.bin.home}/Plugins/${nsis.arch.dir}System.dll
+nsis.nsdialogs.dll=${nsis.bin.home}/Plugins/${nsis.arch.dir}nsDialogs.dll
+nsis.bin.loc=${base-sf.loc}/nsis/nsis-${nsis.version}.zip
+nsis.src.checksum.algorithm=MD5|SHA-1
+nsis.src.checksum.value=dec8094892b881f8bed0a170feee3200|d99f80a197653ad7a623a12f209853d68da1ab84
+nsis.src.home=${base.path}/nsis-${nsis.version}-src
+nsis.src.loc=${base-sf.loc}/nsis/nsis-${nsis.version}-src.tar.bz2
 
 # ----- Commons Daemon, version 1.2.0 or later -----
 commons-daemon.version=1.4.1
diff --git a/build.xml b/build.xml
index 9070db7e00..26120921b2 100644
--- a/build.xml
+++ b/build.xml
@@ -2680,7 +2680,7 @@ To skip building the Windows installer, set the 
skip.installer property in build
   <target name="-installer-wine" if="${wine.ok}">
      <exec dir="${tomcat.dist}" executable="wine" osfamily="unix">
       <arg value="${nsis.exe}" />
-      <arg value="/DNSISDIR=${nsis.home}" />
+      <arg value="/DNSISDIR=${nsis.bin.home}" />
       <arg value="/V2" />
       <arg value="tomcat.nsi" />
     </exec>
@@ -2688,7 +2688,7 @@ To skip building the Windows installer, set the 
skip.installer property in build
 
   <target name="-installer-makensis" if="${makensis.ok}">
     <exec dir="${tomcat.dist}" executable="makensis" osfamily="unix">
-      <arg value="-DNSISDIR=${nsis.home}" />
+      <arg value="-DNSISDIR=${nsis.bin.home}" />
       <arg value="-V2" />
       <arg value="tomcat.nsi" />
     </exec>
@@ -2697,7 +2697,7 @@ To skip building the Windows installer, set the 
skip.installer property in build
   <target name="-installer" unless="skip.installer"
       depends="-installer-prep,-installer-wine,-installer-makensis">
     <exec dir="${tomcat.dist}" executable="${nsis.exe}" osfamily="windows">
-      <arg value="/DNSISDIR=${nsis.home}" />
+      <arg value="/DNSISDIR=${nsis.bin.home}" />
       <arg value="/V2" />
       <arg value="tomcat.nsi" />
     </exec>
@@ -3612,12 +3612,21 @@ Configured for ${release.asfusername} to release Tomcat 
${version.major}.${versi
     </antcall>
 
     <antcall target="downloadzip">
-      <param name="sourcefile" value="${nsis.loc}"/>
+      <param name="sourcefile" value="${nsis.bin.loc}"/>
       <param name="destfile" value="${nsis.exe}"/>
-      <param name="destdir" value="${nsis.home}/.."/>
+      <param name="destdir" value="${nsis.bin.home}/.."/>
       <param name="checksum.enabled" value="${nsis.checksum.enabled}"/>
-      <param name="checksum.algorithm" value="${nsis.checksum.algorithm}"/>
-      <param name="checksum.value" value="${nsis.checksum.value}"/>
+      <param name="checksum.algorithm" value="${nsis.bin.checksum.algorithm}"/>
+      <param name="checksum.value" value="${nsis.bin.checksum.value}"/>
+    </antcall>
+
+    <antcall target="downloadbz2">
+      <param name="sourcefile" value="${nsis.src.loc}"/>
+      <param name="destfile" value="${nsis.exe}"/>
+      <param name="destdir" value="${nsis.bin.home}/.."/>
+      <param name="checksum.enabled" value="${nsis.checksum.enabled}"/>
+      <param name="checksum.algorithm" value="${nsis.src.checksum.algorithm}"/>
+      <param name="checksum.value" value="${nsis.src.checksum.value}"/>
     </antcall>
 
   </target>
@@ -3794,6 +3803,23 @@ Configured for ${release.asfusername} to release Tomcat 
${version.major}.${versi
     <delete file="${temp.file}.tar.gz"/>
   </target>
 
+  <target name="downloadbz2" unless="exist" if="${execute.download}" 
depends="testexist,setproxy">
+    <!-- Download and extract the package -->
+    <local name="temp.file"/>
+    <mkdir dir="${base.path}"/>
+    <tempfile property="temp.file" destdir="${base.path}" prefix="download-"/>
+    <get src="${sourcefile}" httpusecaches="${trydownload.httpusecaches}" 
dest="${temp.file}.tar.bz2" />
+    <verifyChecksum
+      enabled="${checksum.enabled}"
+      algorithm="${checksum.algorithm}" value="${checksum.value}"
+      file="${temp.file}.tar.bz2" name="${sourcefile}" />
+
+    <bunzip2 src="${temp.file}.tar.bz2" dest="${temp.file}.tar"/>
+    <untar src="${temp.file}.tar" dest="${base.path}"/>
+    <delete file="${temp.file}.tar"/>
+    <delete file="${temp.file}.tar.bz2"/>
+  </target>
+
   <target name="downloadzip" unless="exist" if="${execute.download}" 
depends="testexist,setproxy">
     <!-- Download and extract the package -->
     <local name="temp.file"/>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to