From: Ben Soares Date: Fri, 22 Nov 2024 16:33:59 +0000 (+0000) Subject: JAL-4492 Exclude applet classes for desktop build. Not tested jalviewjs build yet... X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=01a733c58dda046018e7cee338fe0b86a005893a;p=jalview.git JAL-4492 Exclude applet classes for desktop build. Not tested jalviewjs build yet as it appears to be broken on my machine at the moment. --- diff --git a/build.gradle b/build.gradle index d466891..a350de3 100644 --- a/build.gradle +++ b/build.gradle @@ -596,14 +596,32 @@ ext { jalviewjsChromiumUserDir = "${jalviewjsBuildDir}/${jalviewjs_chromium_user_dir}" jalviewjsChromiumProfileDir = "${ext.jalviewjsChromiumUserDir}/${jalviewjs_chromium_profile_name}" + if (!project.hasProperty("jalviewLite")) { + jalviewLite = false + } // ENDEXT } +gradle.taskGraph.whenReady { graph -> + jalviewLite = graph.hasTask("jalviewjsTranspile") +} + + sourceSets { main { java { srcDirs sourceDir + + if (! jalviewLite) { + exclude "${sourceDir}/jalview/bin/JalviewLite.java" + exclude "${sourceDir}/jalview/urls/applet/**" + exclude "${sourceDir}/jalview/javascript/*.java" + exclude "${sourceDir}/jalview/appletgui/**" + exclude "${sourceDir}/com/stevesoft/**" + exclude "${sourceDir}/mc_view/Applet*.java" + } + outputDir = file(classesDir) } @@ -640,6 +658,11 @@ sourceSets { test { java { srcDirs testSourceDir + + if (! jalviewLite) { + exclude "${testSourceDir}/jalview/bin/JalviewLiteTest.java" + } + outputDir = file(testClassesDir) }