You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2018/09/04 11:53:25 UTC

[GitHub] matthiasblaesing closed pull request #832: [NETBEANS-1171] Ensure tlddoc can be build if invoked outside project…

matthiasblaesing closed pull request #832: [NETBEANS-1171] Ensure tlddoc can be build if invoked outside project…
URL: https://github.com/apache/incubator-netbeans/pull/832
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/nbbuild/antsrc/org/netbeans/nbbuild/extlibs/VerifyLibsAndLicenses.java b/nbbuild/antsrc/org/netbeans/nbbuild/extlibs/VerifyLibsAndLicenses.java
index ff17324d9b..54b17d9925 100644
--- a/nbbuild/antsrc/org/netbeans/nbbuild/extlibs/VerifyLibsAndLicenses.java
+++ b/nbbuild/antsrc/org/netbeans/nbbuild/extlibs/VerifyLibsAndLicenses.java
@@ -364,19 +364,20 @@ private void testLicenses() throws IOException {
                         }
                     }
                 }
-                if(! headers.getOrDefault("Type", "").equals("generated")) {
-                    // Generated files are created by the build system, for
-                    // example by post-procession other downloaded files
-                    String files = headers.get("Files");
-                    if (files != null) {
-                        for (String file : files.split("[, ]+")) {
-                            referencedBinaries.add(file);
-                            String nested = null;
-                            if (file.contains("!/")) {
-                                final int nestedStart = file.indexOf("!/");
-                                nested = file.substring(nestedStart + 2);
-                                file = file.substring(0, nestedStart);
-                            }
+
+                String files = headers.get("Files");
+                if (files != null) {
+                    for (String file : files.split("[, ]+")) {
+                        referencedBinaries.add(file);
+                        String nested = null;
+                        if (file.contains("!/")) {
+                            final int nestedStart = file.indexOf("!/");
+                            nested = file.substring(nestedStart + 2);
+                            file = file.substring(0, nestedStart);
+                        }
+                        if (!headers.getOrDefault("Type", "").equals("generated")) {
+                            // Generated files are created by the build system, for
+                            // example by post-procession other downloaded files
                             if (!hgFiles.contains(file)) {
                                 msg.append("\n" + path + " mentions a nonexistent binary in Files: " + file);
                             } else if (nested != null) {
@@ -388,16 +389,21 @@ private void testLicenses() throws IOException {
                                 }
                             }
                         }
-                    } else {
-                        String matchingJar = n.replaceFirst("-license\\.txt$", ".jar");
-                        String matchingZip = n.replaceFirst("-license\\.txt$", ".zip");
-                        referencedBinaries.add(matchingJar);
-                        referencedBinaries.add(matchingZip);
+                    }
+                } else {
+                    String matchingJar = n.replaceFirst("-license\\.txt$", ".jar");
+                    String matchingZip = n.replaceFirst("-license\\.txt$", ".zip");
+                    referencedBinaries.add(matchingJar);
+                    referencedBinaries.add(matchingZip);
+                    if (!headers.getOrDefault("Type", "").equals("generated")) {
+                        // Generated files are created by the build system, for
+                        // example by post-procession other downloaded files
                         if (!hgFiles.contains(matchingJar) && !hgFiles.contains(matchingZip)) {
                             msg.append("\n" + path + " has no Files header and no corresponding " + matchingJar + " or " + matchingZip + " could be found");
                         }
                     }
                 }
+
             }
             for (String n : hgFiles) {
                 if (!n.endsWith(".jar") && !n.endsWith(".zip")) {
diff --git a/web.core.syntax/build.xml b/web.core.syntax/build.xml
index 2ea6661eeb..3b4854696e 100644
--- a/web.core.syntax/build.xml
+++ b/web.core.syntax/build.xml
@@ -21,12 +21,12 @@
 -->
 <project name="web.core.syntax" default="netbeans" basedir=".">
 
-    <import file="../j2ee.kit/register_server.xml"/> 
+    <import file="../j2ee.kit/register_server.xml"/>
     <import file="../nbbuild/templates/projectized.xml"/>
 
-    <!-- Hook into harness "basic-init" task -->
+    <!-- Hook into harness "-process.release.files" task -->
     <target name="-process.release.files" depends="prepare-doc"/>
-    
+
     <!-- Check if taglib doc was already generated -->
     <target name="-check-prepared-doc">
         <condition property="web.core.syntax.doccreated" value="present">
@@ -37,13 +37,13 @@
             </and>
         </condition>
     </target>
-    
-    <target name="prepare-doc" depends="-check-prepared-doc,-define-FileCRC32Calculator" unless="web.core.syntax.doccreated">
+
+    <target name="prepare-doc" depends="-check-prepared-doc" unless="web.core.syntax.doccreated">
         <!--
-        
+
         This task prepares the tld doc, that are downloaded as pre-build
         binaries. The procedure:
-        
+
         - the Tag Library Documentation Generator is loaded via the external binaries task
         - the jars the docs are build for are also downloaded by the same mechanism
         - the generator expects in each generation invocation, that the short
@@ -51,7 +51,7 @@
           names are modified below
         - the generated files are the zipped and need to be manually uploaded
           to the netbeans binaries server
-        
+
         -->
         <delete dir="build/tlddoc-build" />
         <mkdir dir="build/tlddoc-build/jstl11" />
@@ -82,43 +82,43 @@
                 <pathelement location="external/tlddoc-1.3.jar" />
             </classpath>
             <arg value="-d" />
-            <arg value="build/tlddoc-build/jstl11-out" />
+            <arg value="${basedir}/build/tlddoc-build/jstl11-out" />
             <arg value="-xslt" />
-            <arg value="tlddoc/xslt/" />
+            <arg value="${basedir}/tlddoc/xslt/" />
             <arg value="-doctitle" />
             <arg value="JavaServer Pages Standard Tag Library 1.1 Tag Reference" />
             <arg value="-windowtitle" />
             <arg value="JSPL 1.1 - Generated Documentation" />
-            <arg value="build/tlddoc-build/jstl11-input.jar" />
+            <arg value="${basedir}/build/tlddoc-build/jstl11-input.jar" />
         </java>
         <java classname="com.sun.tlddoc.TLDDoc">
             <classpath>
                 <pathelement location="external/tlddoc-1.3.jar" />
             </classpath>
             <arg value="-d" />
-            <arg value="build/tlddoc-build/jsf12-out" />
+            <arg value="${basedir}/build/tlddoc-build/jsf12-out" />
             <arg value="-xslt" />
-            <arg value="tlddoc/xslt/" />
+            <arg value="${basedir}/tlddoc/xslt/" />
             <arg value="-doctitle" />
             <arg value="JavaServer Faces 1.2" />
             <arg value="-windowtitle" />
             <arg value="JSF 1.2 - Generated Documentation" />
-            <arg value="external/jsf-impl-1.2-20.jar" />
+            <arg value="${basedir}/external/jsf-impl-1.2-20.jar" />
         </java>
         <java classname="com.sun.tlddoc.TLDDoc">
             <classpath>
                 <pathelement location="external/tlddoc-1.3.jar" />
             </classpath>
             <arg value="-d" />
-            <arg value="build/tlddoc-build/struts.out" />
+            <arg value="${basedir}/build/tlddoc-build/struts.out" />
             <arg value="-xslt" />
-            <arg value="tlddoc/xslt/" />
+            <arg value="${basedir}/tlddoc/xslt/" />
             <arg value="-doctitle" />
             <arg value="The Struts Framework Project" />
             <arg value="-windowtitle" />
             <arg value="Struts - Generated Documentation" />
-            <arg value="external/struts-taglib-1.3.10.jar" />
-            <arg value="external/struts-tiles-1.3.10.jar" />
+            <arg value="${basedir}/external/struts-taglib-1.3.10.jar" />
+            <arg value="${basedir}/external/struts-tiles-1.3.10.jar" />
         </java>
 
         <jar destfile="external/generated-jstl11-doc-1.1.2.zip">


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists