You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@netbeans.apache.org by ma...@apache.org on 2020/01/10 18:18:08 UTC
[netbeans] branch master updated: [NETBEANS-3260] : Corrected
output for modular project while building using ant script
This is an automated email from the ASF dual-hosted git repository.
matthiasblaesing pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/netbeans.git
The following commit(s) were added to refs/heads/master by this push:
new fffdefc [NETBEANS-3260] : Corrected output for modular project while building using ant script
new a7a0b51 Merge pull request #1767 from singh-akhilesh/netbeans-3260
fffdefc is described below
commit fffdefc13c94356f67eee9fb8f5f419a75d19526
Author: Akhilesh Singh <ak...@oracle.com>
AuthorDate: Wed Jan 8 16:50:58 2020 +0530
[NETBEANS-3260] : Corrected output for modular project while building using ant script
---
.../java/j2semodule/resources/build-impl.xsl | 28 +++++++++++++++++++---
1 file changed, 25 insertions(+), 3 deletions(-)
diff --git a/java/java.j2semodule/src/org/netbeans/modules/java/j2semodule/resources/build-impl.xsl b/java/java.j2semodule/src/org/netbeans/modules/java/j2semodule/resources/build-impl.xsl
index 48d4a01..97cb56e 100644
--- a/java/java.j2semodule/src/org/netbeans/modules/java/j2semodule/resources/build-impl.xsl
+++ b/java/java.j2semodule/src/org/netbeans/modules/java/j2semodule/resources/build-impl.xsl
@@ -1697,7 +1697,7 @@ is divided into following sections:
</target>
<target name="-do-jar-jar">
- <xsl:attribute name="depends">init,compile,-pre-pre-jar,-pre-jar</xsl:attribute>
+ <xsl:attribute name="depends">init,compile,-pre-pre-jar,-pre-jar,-main-module-check-condition</xsl:attribute>
<xsl:attribute name="if">do.archive</xsl:attribute>
<xsl:attribute name="unless">do.mkdist</xsl:attribute>
<property name="build.modules.dir.resolved" location="${{build.modules.dir}}"/>
@@ -1716,7 +1716,17 @@ is divided into following sections:
<param name="module.dir" location="${{entry}}"/>
</antcall>
</j2semodularproject1:for-paths>
-
+ <condition property="named.module.internal">
+ <and>
+ <isset property="module.name"/>
+ <length length="0" string="${{module.name}}" when="greater"/>
+ </and>
+ </condition>
+ <condition property="unnamed.module.internal">
+ <not>
+ <isset property="named.module.internal"/>
+ </not>
+ </condition>
<property location="${{build.classes.dir}}" name="build.classes.dir.resolved"/>
<property location="${{dist.jar}}" name="dist.jar.resolved"/>
<pathconvert property="run.classpath.with.dist.jar">
@@ -1727,7 +1737,7 @@ is divided into following sections:
<path path="${{run.modulepath}}"/>
<map from="${{build.classes.dir.resolved}}" to="${{dist.jar.resolved}}"/>
</pathconvert>
- <condition property="jar.usage.message.module.path" value=" -modulepath ${{run.modulepath.with.dist.jar}}" else="">
+ <condition property="jar.usage.message.module.path" value=" --module-path ${{run.modulepath.with.dist.jar}}" else="">
<and>
<isset property="modules.supported.internal"/>
<length length="0" string="${{run.modulepath.with.dist.jar}}" when="greater"/>
@@ -1905,6 +1915,18 @@ is divided into following sections:
</condition>
</fail>
</target>
+ <target name="-main-module-check-condition" depends="-main-module-set" if="main.class.available">
+ <fail message="Could not determine module of the main class and module.name is not set">
+ <condition>
+ <or>
+ <not>
+ <isset property="module.name"/>
+ </not>
+ <length string="${{module.name}}" when="equal" length="0"/>
+ </or>
+ </condition>
+ </fail>
+ </target>
<target name="-do-not-recompile">
<property name="javac.includes.binary" value=""/> <!-- #116230 hack -->
</target>
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@netbeans.apache.org
For additional commands, e-mail: commits-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists