-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
JfxJar-task producing stackoverflow #71
Comments
Can you post the logs? |
What is the "JafJar"-task? |
sorry, misprint. jfxJar not JafJAr task
|
This gradle script is work. If comment work region and uncomment not work. The jfxJar task not working |
instead of "--debug", can you re-run this with "--stacktrace"? |
|
Thats odd, can you create a small project where I can reproduce this? What version of JDK and Gradle are you using? |
jdk 1.8.0_131 |
Maybe this has something to do with the "dependencySubstitution" ... will have to take a deeper look into this. Even on older gradle 2.10 this does not work. |
So, I tried adding this plugin and getting a similar error. It works for my :launcher subproject but not my :maptool subproject... https://github.com/JamzTheMan/maptool/tree/1.4.3.21
|
Any ideas on this? (As I'm not using dependencySubstitution, not sure if that is the root cause?) Currently looking at creating the tasks manually and it's a pita, I would love to just use your plugin! |
Actually I don't know, I suspect the resolution to be special ... haven't found out whats going on there :/ but I'm happy for any hint |
Hmm, so I stripped out and reduce my project to a single project structure (no sub projects) so now it's just the MapTool as a single project. I also stripped and reduced the gradle build to a more bare bones setup. I then removed what I thought may be the more complicated lib dependencies, org.bouncycastle, libgdx, and nashorn api. I still get the stackoverflow error :( So not sure what the issue is... BTW, I'm able to package just fine use javapackager as a JavaExec task... Here's my current gradle build: /*
* For more details take a look at the Java Quickstart chapter in the Gradle
* user guide available at https://docs.gradle.org/4.1/userguide/tutorial_java_projects.html
*/
//import org.apache.tools.ant.filters.ReplaceTokens
//import java.text.SimpleDateFormat
//import org.ajoberstar.grgit.*
//import org.gradle.api.tasks.JavaExec
buildscript {
dependencies {
classpath group: 'de.dynamicfiles.projects.gradle.plugins', name: 'javafx-gradle-plugin', version: '8.8.2'
}
repositories {
mavenCentral()
}
}
// Apply the java plugin to add support for Java
apply plugin: 'base'
apply plugin: 'application'
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'javafx-gradle-plugin'
// Definitions
defaultTasks 'clean', 'run'
sourceCompatibility = 1.8
targetCompatibility = 1.8
// Used by gradle assemble & run tasks
version = '1.4.4.0'
mainClassName = 'net.rptools.maptool.client.LaunchInstructions'
applicationDefaultJvmArgs = ["-Xss4M"]
// Custom properties
ext {
gdxVersion = '1.9.6'
box2DLightsVersion = '1.4'
//aiVersion = '1.8.0'
//roboVMVersion = '2.3.0'
}
run {
println 'Default arguments being passed...'
args = [ '-v='+version, '-debug', '-fullscreen' ]
}
jfx {
// minimal requirement for jfxJar-task
mainClass = mainClassName
// minimal requirement for jfxNative-task
vendor = 'Nerps'
}
// In this section you declare where to find the dependencies of your project
repositories {
// Use 'jcenter' for resolving your dependencies.
// You can declare any Maven/Ivy/file repository here.
jcenter()
mavenCentral()
maven { url = 'http://maptool.craigs-stuff.net/repo/' }
maven { url = 'http://www.nerps.net/repo/' }
mavenLocal()
}
// In this section you declare the dependencies for your production and test code
dependencies {
compile files("${System.properties['java.home']}/../lib/packager.jar") // This dependency is for UserJvmOptionsService
compile 'net.java.abeille:abeille-formsrt:2.0'
compile 'net.rptools.clientserver:clientserver:1.4.0.+'
compile 'org.hibernate:antlr:2.7.5H3'
compile 'commons-beanutils:commons-beanutils-core:1.8.3'
compile 'org.ow2.util.bundles:commons-collections-3.2.1:1.0.0'
compile 'commons-io:commons-io:2.4'
compile 'commons-jxpath:commons-jxpath:1.3'
compile 'commons-lang:commons-lang:2.6'
compile 'commons-logging:commons-logging:1.1.1'
compile 'commons-net:commons-net:3.2'
compile 'commons-cli:commons-cli:1.3'
compile 'net.rptools.decktool:decktool:1.0.b1'
compile 'net.rptools.dicelib:dicelib:1.4.0.+'
compile 'net.sf.ezmorph:ezmorph:1.0.5'
compile 'com.caucho.hessian:hessian:3.1.6'
compile 'jide-common:jide-common:3.2.3'
compile 'jide-components:jide-components:3.2.3'
compile 'jide-dialogs:jide-dialogs:3.2.3'
compile 'jide-dock:jide-dock:3.2.3'
compile 'jide-editor:jide-editor:3.2.3'
compile 'jide-grids:jide-grids:3.2.3'
compile 'jide-properties:jide-properties:3.2.3'
compile 'jide-shortcut:jide-shortcut:3.2.3'
compile 'de.huxhorn.sulky:de.huxhorn.sulky.3rdparty.jlayer:1.0'
// compile 'rhino:js:1.7R1'
compile 'net.sf.json-lib:json-lib:2.4:jdk15'
compile 'log4j:log4j:1.2.16'
compile 'net.rptools.maptool.resource:maptool.resource:1.0.b18'
compile 'net.rptools.parser:parser:1.4.0.+'
compile 'ca.odell.renderpack:renderpack:1.2004'
compile 'net.tsc.servicediscovery:servicediscovery:1.0.b5'
compile 'org.swinglabs:swing-worker:1.1'
compile 'net.sbbi.upnp:upnplib:1.0.9-nodebug'
compile 'com.withay:withay-util:1.0'
compile 'xmlpull:xmlpull:1.1.3.1'
compile 'xpp3:xpp3_min:1.1.4c'
compile 'com.thoughtworks.xstream:xstream:1.4.9'
compile 'yasb:yasb:0.2-21012007'
compile 'de.muntjak.tinylookandfeel:tinylaf-nocp:1.4.0'
compile 'org.eclipse.jetty:jetty-server:9.3.0.M0'
compile 'org.eclipse.jetty:jetty-servlet:9.3.0.M0'
compile 'org.eclipse.jetty:jetty-webapp:9.3.0.M0'
compile 'org.eclipse.jetty:jetty-continuation:9.3.0.M1'
compile 'org.eclipse.jetty.websocket:websocket-server:9.3.0.M1'
compile 'org.eclipse.jetty.websocket:websocket-client:9.3.0.M1'
compile 'org.eclipse.jetty.websocket:websocket-servlet:9.3.0.M1'
compile 'org.eclipse.jetty.websocket:websocket-api:9.3.0.M1'
compile 'org.reflections:reflections:0.9.10'
compile 'org.apache.pdfbox:pdfbox:2.0.0' // Jamz: For pdf image extraction
compile 'org.apache.pdfbox:pdfbox-tools:2.0.0' // Jamz: Dependancy for pdfbox
// compile 'org.bouncycastle:bcmail-jdk15on:1.54' // Jamz: To decrypt passworded/secured pdf's
compile 'com.github.jai-imageio:jai-imageio-core:1.3.1' // Jamz: For pdf image extraction, specifically for jpeg2000 (jpx) support.
compile 'com.github.jai-imageio:jai-imageio-jpeg2000:1.3.0' // Jamz: For pdf image extraction, specifically for jpeg2000 (jpx) support.
compile group: 'com.fifesoft', name: 'rsyntaxtextarea', version: '2.6.0' // https://mvnrepository.com/artifact/com.fifesoft/rsyntaxtextarea
compile group: 'com.fifesoft', name: 'autocomplete', version: '2.6.0' // https://mvnrepository.com/artifact/com.fifesoft/autocomplete
compile group: 'com.fifesoft', name: 'rstaui', version: '2.6.0' // https://mvnrepository.com/artifact/com.fifesoft/rstaui
compile group: 'com.jcabi', name: 'jcabi-xml', version: '0.18.1' // https://mvnrepository.com/artifact/com.jcabi/jcabi-xml
// box2dlights test
//compile group: 'com.badlogicgames.gdx', name: 'gdx-platform', version: '1.9.5' // https://mvnrepository.com/artifact/com.badlogicgames.gdx/gdx-platform
//compile group: 'com.badlogicgames.gdx', name: 'gdx-backend-lwjgl', version: '1.9.5' // https://mvnrepository.com/artifact/com.badlogicgames.gdx/gdx-backend-lwjgl
//compile group: 'com.badlogicgames.gdx', name: 'gdx-box2d', version: '1.9.5' // https://mvnrepository.com/artifact/com.badlogicgames.gdx/gdx-box2d
//compile group: 'com.badlogicgames.box2dlights', name: 'box2dlights', version: '1.4'
// compile "com.badlogicgames.gdx:gdx-backend-lwjgl:$gdxVersion"
// compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-desktop"
// compile "com.badlogicgames.gdx:gdx-box2d-platform:$gdxVersion:natives-desktop"
// compile "com.badlogicgames.gdx:gdx:$gdxVersion"
// compile "com.badlogicgames.gdx:gdx-box2d:$gdxVersion"
// compile "com.badlogicgames.box2dlights:box2dlights:$box2DLightsVersion"
// Not in use at this time, left for easy reference later...
//compile "com.badlogicgames.gdx:gdx-controllers:$gdxVersion"
//compile "com.badlogicgames.gdx:gdx-freetype:$gdxVersion"
//compile "com.badlogicgames.ashley:ashley:$ashleyVersion"
//compile "com.badlogicgames.gdx:gdx-ai:$aiVersion"
//compile "com.badlogicgames.gdx:gdx-bullet:$gdxVersion"
// Declare the dependency for your favourite test framework you want to use in your tests.
// TestNG is also supported by the Gradle Test task. Just change the
// testCompile dependency to testCompile 'org.testng:testng:6.8.1' and add
// 'test.useTestNG()' to your build script.
testCompile 'junit:junit:4.12'
}
// Adjust access rule in Eclipse for Nashorn
eclipse.classpath.file {
whenMerged {
withXml { classpathXml ->
def classpathXmlNode = classpathXml.asNode()
Node classpathJreNode = node.find {
it.@kind == 'con' &&
it.@path.contains('JRE_CONTAINER') &&
it.@path.contains('JavaSE-1.8')
}
// Only append if node is not null, eg
// if it found the proper node entry.
if (classpathJreNode) {
classpathJreNode
.appendNode('accessrules')
.appendNode('accessrule', [
kind: 'accessible',
pattern: 'jdk/nashorn/api/**'
])
}
}
}
} |
I dunno if it matters or not, but ... in the repositories block I always make |
MavenCentral will not become dead in the next days, because maven isn't dead. As MavenCentral just started as a maven-targeted repository, but became some artifact-repository, this shouldn't be the problem. I hope to get some time this weekend for further reworking-progress. This probably has something to do with the way I'm actually looping through the dependencies. |
In my project i need swt. So i add it in gradle. The problem with swt dependency. swt depend on native libs. native libs depends on swt. Build task is work correct, but JafJar is failed with stakOverflow.
This gradle script is work. If comment work region and uncomment not work in dependencies, you will be get error.
The text was updated successfully, but these errors were encountered: