blob: 6281c3b23ee895778967c4ef6030bda8bf7e080c [file] [log] [blame]
/********************************************************************************
* Copyright (c) 2015-2018 Contributors to the Eclipse Foundation
*
* See the NOTICE file(s) distributed with this work for additional
* information regarding copyright ownership.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* SPDX-License-Identifier: EPL-2.0
*
********************************************************************************/
plugins {
id "de.undercouch.download" version "3.2.0"
id 'maven-publish'
id 'java-library'
}
import de.undercouch.gradle.tasks.download.Download
version '0.7.4'
description = 'Downloads openATFX and publishes it to the local maven repository'
dependencies {
compile 'org.slf4j:jcl-over-slf4j:1.7.25'
compile 'org.slf4j:log4j-over-slf4j:1.7.25'
compile 'org.codehaus.woodstox:woodstox-core-asl:4.4.1'
// actually we just need the org.asam.ods.* classes
compile "org.eclipse.mdm:org.eclipse.mdm.api.odsadapter:${version}"
testCompile 'org.apache.commons:commons-math:2.2'
}
task downloadOpenATFX(type: Download) {
overwrite false
// use mirror subdomain of 'https://sourceforge.net/projects/openatfx/files/openatfx-${version}-jars.zip/download'
// because gradle has problems establishing a ssl connection with sourceforge directly
src "https://liquidtelecom.dl.sourceforge.net/project/openatfx/openatfx-${version}-jars.zip"
dest file("${buildDir}/openatfx-${version}-jars.zip")
outputs.file dest
}
task unzipOpenATFX(dependsOn: downloadOpenATFX, type: Copy) {
from zipTree(downloadOpenATFX.dest)
into buildDir
outputs.dir file("${buildDir}/openatfx-${version}")
}
task copySource(dependsOn: unzipOpenATFX, type: Copy) {
from file("${buildDir}/openatfx-${version}/src")
into 'src'
}
compileJava.dependsOn copySource
/**
* Some tests in openATFX throw NPEs when executed with the ODS Corba classes generated
* by SunORB. The issue occurs, if an attribute is left uninitialized and then serialized.
*/
tasks.withType(Test) {enabled = false}