diff options
author | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2013-10-29 12:08:29 +0100 |
---|---|---|
committer | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2013-10-29 12:08:29 +0100 |
commit | dd43264f702c5e0351cc63835862c55f3e847634 (patch) | |
tree | c16b35e7b7008f15142fe3f98672aff5e37ce41e /pdf-as-lib/build.gradle | |
parent | 07cfc175c86eec0def3cd7376e0697317d3d7b26 (diff) | |
download | pdf-as-4-dd43264f702c5e0351cc63835862c55f3e847634.tar.gz pdf-as-4-dd43264f702c5e0351cc63835862c55f3e847634.tar.bz2 pdf-as-4-dd43264f702c5e0351cc63835862c55f3e847634.zip |
Some changes
Diffstat (limited to 'pdf-as-lib/build.gradle')
-rw-r--r-- | pdf-as-lib/build.gradle | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/pdf-as-lib/build.gradle b/pdf-as-lib/build.gradle index fd7c00fc..a6693841 100644 --- a/pdf-as-lib/build.gradle +++ b/pdf-as-lib/build.gradle @@ -7,6 +7,41 @@ jar { } } +buildscript { + repositories { + mavenLocal() + mavenCentral() + } + dependencies { + classpath("commons-io:commons-io:2.4") + } +} + +configurations { + generateJavaFromWsdlDeps +} + +task generateJavaFromWsdl(type: JavaExec) { + classpath configurations.generateJavaFromWsdlDeps + //main "org.apache.cxf.tools.wsdlto.WSDLToJava" + main "org.apache.axis.wsdl.WSDL2Java" + args "-o " + projectDir + "/src/main/java", "-v", "" + projectDir + "/src/main/resources/wsdl/MOA-SPSS-1.3.wsdl" + + compileJava.dependsOn += name + + def branch = new org.apache.commons.io.output.ByteArrayOutputStream() + errorOutput = new org.apache.commons.io.output.TeeOutputStream(System.err, branch) + doLast { + def str = branch.toString() + if (str.contains('Usage : wsdl2java') || str.contains('WSDLToJava Error')) { + throw new TaskExecutionException( + tasks[name], + new IOException("WSDLToJava has failed, please see output") + ) + } + } +} + repositories { mavenLocal() mavenCentral() @@ -26,6 +61,15 @@ dependencies { compile group: 'eu.europa.ec.joinup.egovlabs.pdf-as.iaik', name: 'iaik_jce_eval_signed', version: '4.0' compile group: 'eu.europa.ec.joinup.egovlabs.pdf-as.iaik', name: 'iaik_ecc_eval_signed', version: '2.19' testCompile group: 'junit', name: 'junit', version: '4.+' + generateJavaFromWsdlDeps('org.apache.axis:axis:1.4') + generateJavaFromWsdlDeps('org.apache.axis:axis-jaxrpc:1.4') + generateJavaFromWsdlDeps('axis:axis-wsdl4j:1.5.1') + generateJavaFromWsdlDeps('commons-codec:commons-codec:1.3') + generateJavaFromWsdlDeps('commons-logging:commons-logging:1.1.1') + generateJavaFromWsdlDeps('commons-discovery:commons-discovery:0.2') + /*generateJavaFromWsdlDeps('org.apache.cxf:cxf-tools-wsdlto-core:2.7.0') + generateJavaFromWsdlDeps('org.apache.cxf:cxf-tools-wsdlto-frontend-jaxws:2.7.0') + generateJavaFromWsdlDeps('org.apache.cxf:cxf-tools-wsdlto-databinding-jaxb:2.7.0')*/ } test { |