[Git][java-team/eclipse-debian-helper][master] 2 commits: Fixed the classpath when depending on other bundles

Emmanuel Bourg gitlab at salsa.debian.org
Wed Jul 11 20:12:15 BST 2018


Emmanuel Bourg pushed to branch master at Debian Java Maintainers / eclipse-debian-helper


Commits:
e8ad9818 by Emmanuel Bourg at 2018-07-11T21:10:33+02:00
Fixed the classpath when depending on other bundles

- - - - -
c601ee4b by Emmanuel Bourg at 2018-07-11T21:11:46+02:00
Include the resources from all source directories and not only src/

- - - - -


2 changed files:

- debian/changelog
- src/ant/build-eclipse-bundle.xml


Changes:

=====================================
debian/changelog
=====================================
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+eclipse-debian-helper (1.0.1) UNRELEASED; urgency=medium
+
+  * Fixed the classpath when depending on other bundles
+  * Include the resources from all source directories and not only src/
+
+ -- Emmanuel Bourg <ebourg at apache.org>  Wed, 11 Jul 2018 19:55:47 +0200
+
 eclipse-debian-helper (1.0) unstable; urgency=medium
 
   * Initial release (Closes: #903559)


=====================================
src/ant/build-eclipse-bundle.xml
=====================================
--- a/src/ant/build-eclipse-bundle.xml
+++ b/src/ant/build-eclipse-bundle.xml
@@ -28,23 +28,27 @@
           <mkdir dir="${bundle.dir.@{name}}/target/classes"/>
 
           <touch file="${bundle.dir.@{name}}/target/dependencies"/>
+          <concat destfile="${bundle.dir.@{name}}/target/dependencies" append="true">non/existent/path/${line.separator}</concat>
           <for list="@{depends}" param="dependency">
             <sequential>
               <concat destfile="${bundle.dir.@{name}}/target/dependencies" append="true">@{basedir}/@{dependency}/target/@{dependency}.jar${line.separator}</concat>
             </sequential>
           </for>
 
-          <touch file="${bundle.dir.@{name}}/target/sources"/>
+          <var name="sourcedirs.@{name}" value=""/>
           <for list="${@{name}.source..}" param="srcdir">
             <sequential>
-              <concat destfile="${bundle.dir.@{name}}/target/sources" append="true">@{srcdir}${line.separator}</concat>
+              <var name="sourcedirs.@{name}" value="${sourcedirs.@{name}},${bundle.dir.@{name}}/@{srcdir}"/>
             </sequential>
           </for>
+          <propertyregex property="sourcedirs.@{name}" input="${sourcedirs.@{name}}" regexp="^,(.*)" replace="\1" override="true"/>
 
-          <javac destdir="${bundle.dir.@{name}}/target/classes" debug="yes" release="8" includeantruntime="false">
-            <src>
-              <dirset dir="${bundle.dir.@{name}}" includesfile="${bundle.dir.@{name}}/target/sources"/>
-            </src>
+          <mkdir dir="${bundle.dir.@{name}}/target/sources"/>
+          <copy todir="${bundle.dir.@{name}}/target/sources">
+            <multirootfileset basedirs="${sourcedirs.@{name}}" includes="**/*.java"/>
+          </copy>
+
+          <javac srcdir="${bundle.dir.@{name}}/target/sources" destdir="${bundle.dir.@{name}}/target/classes" debug="yes" release="8" includeantruntime="false">
             <classpath>
               <pathelement path="/usr/share/java/org.eclipse.osgi.jar"/>
               <pathelement path="/usr/share/java/osgi.compendium.jar"/>
@@ -55,8 +59,8 @@
 
           <!-- Copy the resources -->
           <copy todir="${bundle.dir.@{name}}/target/classes" quiet="true">
-            <fileset dir="${bundle.dir.@{name}}/src" includes="**/*.properties"/>
-            <fileset dir="${bundle.dir.@{name}}"     includes="${@{name}.bin.includes}"/>
+            <multirootfileset basedirs="${sourcedirs.@{name}}" excludes="**/*.java,**/package.html"/>
+            <fileset dir="${bundle.dir.@{name}}" includes="${@{name}.bin.includes}"/>
           </copy>
 
           <!-- Create the jar -->



View it on GitLab: https://salsa.debian.org/java-team/eclipse-debian-helper/compare/ce0de3b76422f38616cebc012b2eb97aa874256f...c601ee4b1b18e1530cf155e9805bb3ac4f81c044

-- 
View it on GitLab: https://salsa.debian.org/java-team/eclipse-debian-helper/compare/ce0de3b76422f38616cebc012b2eb97aa874256f...c601ee4b1b18e1530cf155e9805bb3ac4f81c044
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-java-commits/attachments/20180711/484d2c29/attachment.html>


More information about the pkg-java-commits mailing list