diff options
-rw-r--r-- | releng/cmdtools/build.gradle | 20 | ||||
-rw-r--r-- | releng/cmdtools/gradle.properties | 14 | ||||
-rw-r--r-- | releng/cmdtools/settings.gradle | 127 | ||||
-rw-r--r-- | releng/tooling/org.eclipse.fx.ide.ldef.feature/feature.xml | 137 |
4 files changed, 292 insertions, 6 deletions
diff --git a/releng/cmdtools/build.gradle b/releng/cmdtools/build.gradle new file mode 100644 index 000000000..8766dc5ab --- /dev/null +++ b/releng/cmdtools/build.gradle @@ -0,0 +1,20 @@ +/* + * Master Gradle build script + * + * Depends on bndWorkspace and bndURI properties set by settings.gradle. + */ + +/* Add bnd as a script dependency */ +buildscript { + dependencies { + classpath files(bndURI) + } +} + +/* Configure the subprojects */ +subprojects { + def bndProject = bndWorkspace.getProject(name) + if (bndProject != null) { + plugins.apply 'biz.aQute.bnd' + } +} diff --git a/releng/cmdtools/gradle.properties b/releng/cmdtools/gradle.properties new file mode 100644 index 000000000..e4644f8ac --- /dev/null +++ b/releng/cmdtools/gradle.properties @@ -0,0 +1,14 @@ +# cnf project name +bnd_cnf=cnf + +# bnd_jar can also be a URL. +bnd_jar=cnf/gradle/biz.aQute.bnd.gradle.jar + +# bnd_build can be set to the name of a "master" project whose dependencies will seed the set of projects to build. +bnd_build= + +# Default gradle task to build +bnd_defaultTask=build + +# This should be false. It only needs to be true in rare cases. +bnd_preCompileRefresh=false diff --git a/releng/cmdtools/settings.gradle b/releng/cmdtools/settings.gradle new file mode 100644 index 000000000..5d64c9936 --- /dev/null +++ b/releng/cmdtools/settings.gradle @@ -0,0 +1,127 @@ +/* + * Master Gradle initialization script + * + * Depends on bnd_* values from gradle.properties. + */ + +import aQute.bnd.build.Workspace + +/* Add bnd as a script dependency */ +buildscript { + dependencies { + def bndURI = rootDir.toURI().resolve(bnd_jar) + if (bndURI.scheme != 'file') { + /* If not a local file, copy to a local file in cnf/cache */ + def cnfCache = mkdir("${rootDir}/${bnd_cnf}/cache") + def bndJarFile = new File(cnfCache, 'biz.aQute.bnd.gradle.jar') + if (!bndJarFile.exists()) { + println "Downloading ${bndURI} to ${bndJarFile} ..." + bndURI.toURL().withInputStream { is -> + bndJarFile.withOutputStream { os -> + def bos = new BufferedOutputStream( os ) + bos << is + } + } + } + bndURI = bndJarFile.toURI() + } + classpath files(bndURI) + + /* After the rootProject is created, pass URI to projects */ + gradle.rootProject { rootProject -> + rootProject.ext.bndURI = bndURI + } + } +} + +/* Initialize the bnd workspace */ +def workspace = Workspace.getWorkspace(rootDir, bnd_cnf) +if (workspace == null) { + throw new GradleException("Unable to load workspace ${rootDir}/${bnd_cnf}") +} + +/* Add cnf project to the graph */ +include bnd_cnf + +/* Start with the declared build project name */ +def defaultProjectName = bnd_build + +/* If in a subproject, use the subproject name */ +for (def currentDir = startParameter.currentDir; currentDir != rootDir; currentDir = currentDir.parentFile) { + defaultProjectName = currentDir.name +} + +/* Build a set of project names we need to include from the specified tasks */ +def projectNames = startParameter.taskNames.collect { taskName -> + def elements = taskName.split(':') + switch (elements.length) { + case 1: + return defaultProjectName + case 2: + return elements[0].empty ? bnd_build : elements[0] + default: + return elements[0].empty ? elements[1] : elements[0] + } +}.toSet() + +/* Include the default project name if in a subproject or no tasks specified */ +if ((startParameter.currentDir != rootDir) || projectNames.empty) { + projectNames += defaultProjectName +} + +/* If bnd_build used but declared empty, add all non-private folders of rootDir */ +if (projectNames.remove('')) { + rootDir.eachDir { + def projectName = it.name + if (!projectName.startsWith('.')) { + projectNames += projectName + } + } +} + +/* Add each project and its dependencies to the graph */ +projectNames.each { projectName -> + include projectName + def project = getBndProject(workspace, projectName) + project?.dependson.each { + include it.name + } +} + +/* Get the bnd project for the specified project name */ +def getBndProject(Workspace workspace, String projectName) { + def project = workspace.getProject(projectName) + if (project == null) { + return null + } + project.prepare() + if (project.isValid()) { + return project + } + + project.getInfo(workspace, "${rootDir} :") + def errorCount = 0 + project.warnings.each { + println "Warning: ${it}" + } + project.errors.each { + println "Error : ${it}" + errorCount++ + } + if (!project.isOk()) { + def str = 'even though no errors were reported' + if (errorCount == 1) { + str = 'one error was reported' + } else if (errorCount > 1) { + str = "${errorCount} errors were reported" + } + throw new GradleException("Project ${rootDir}/${projectName} is invalid, ${str}") + } + throw new GradleException("Project ${rootDir}/${projectName} is not a valid bnd project") +} + +/* After the rootProject is created, set up some properties. */ +gradle.rootProject { rootProject -> + rootProject.ext.bndWorkspace = workspace + rootProject.ext.cnf = rootProject.project(bnd_cnf) +} diff --git a/releng/tooling/org.eclipse.fx.ide.ldef.feature/feature.xml b/releng/tooling/org.eclipse.fx.ide.ldef.feature/feature.xml index f14b6f71e..765863b89 100644 --- a/releng/tooling/org.eclipse.fx.ide.ldef.feature/feature.xml +++ b/releng/tooling/org.eclipse.fx.ide.ldef.feature/feature.xml @@ -4,16 +4,141 @@ label="Feature" version="2.1.0.qualifier"> - <description url="http://www.example.com/description"> - [Enter Feature Description here.] + <description> + DSL to create code editors </description> - <copyright url="http://www.example.com/copyright"> - [Enter Copyright Description here.] + <copyright> + Copyright (c) 2015 Eclipse.org and others. +All rights reserved. This program and the accompanying materials +are made available under the terms of the Eclipse Public License v1.0 +which accompanies this distribution, and is available at +http://www.eclipse.org/legal/epl-v10.html </copyright> - <license url="http://www.example.com/license"> - [Enter License Description here.] + <license url="http://www.eclipse.org/legal/epl-v10.html"> + Eclipse Foundation Software User Agreement +April 9, 2014 + +Usage Of Content + +THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR +OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT"). +USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS +AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR +NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU +AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT +AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS +OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE +TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS +OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED +BELOW, THEN YOU MAY NOT USE THE CONTENT. + +Applicable Licenses + +Unless otherwise indicated, all Content made available by the +Eclipse Foundation is provided to you under the terms and conditions of +the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is +provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html. +For purposes of the EPL, "Program" will mean the Content. + +Content includes, but is not limited to, source code, object code, +documentation and other files maintained in the Eclipse Foundation source code +repository ("Repository") in software modules ("Modules") and made available +as downloadable archives ("Downloads"). + + - Content may be structured and packaged into modules to facilitate delivering, + extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), + plug-in fragments ("Fragments"), and features ("Features"). + - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive) + in a directory named "plugins". + - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. + Each Feature may be packaged as a sub-directory in a directory named "features". + Within a Feature, files named "feature.xml" may contain a list of the names and version + numbers of the Plug-ins and/or Fragments associated with that Feature. + - Features may also include other Features ("Included Features"). Within a Feature, files + named "feature.xml" may contain a list of the names and version numbers of Included Features. + +The terms and conditions governing Plug-ins and Fragments should be +contained in files named "about.html" ("Abouts"). The terms and +conditions governing Features and Included Features should be contained +in files named "license.html" ("Feature Licenses"). Abouts and Feature +Licenses may be located in any directory of a Download or Module +including, but not limited to the following locations: + + - The top-level (root) directory + - Plug-in and Fragment directories + - Inside Plug-ins and Fragments packaged as JARs + - Sub-directories of the directory named "src" of certain Plug-ins + - Feature directories + +Note: if a Feature made available by the Eclipse Foundation is installed using the +Provisioning Technology (as defined below), you must agree to a license ("Feature +Update License") during the installation process. If the Feature contains +Included Features, the Feature Update License should either provide you +with the terms and conditions governing the Included Features or inform +you where you can locate them. Feature Update Licenses may be found in +the "license" property of files named "feature.properties" found within a Feature. +Such Abouts, Feature Licenses, and Feature Update Licenses contain the +terms and conditions (or references to such terms and conditions) that +govern your use of the associated Content in that directory. + +THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER +TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. +SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO): + + - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html) + - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html) + - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE) + - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0) + - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html) + +IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR +TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License +is provided, please contact the Eclipse Foundation to determine what terms and conditions +govern that particular Content. + +Use of Provisioning Technology + +The Eclipse Foundation makes available provisioning software, examples of which include, +but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for +the purpose of allowing users to install software, documentation, information and/or +other materials (collectively "Installable Software"). This capability is provided with +the intent of allowing such users to install, extend and update Eclipse-based products. +Information about packaging Installable Software is available at +http://eclipse.org/equinox/p2/repository_packaging.html ("Specification"). + +You may use Provisioning Technology to allow other parties to install Installable Software. +You shall be responsible for enabling the applicable license agreements relating to the +Installable Software to be presented to, and accepted by, the users of the Provisioning Technology +in accordance with the Specification. By using Provisioning Technology in such a manner and +making it available in accordance with the Specification, you further acknowledge your +agreement to, and the acquisition of all necessary rights to permit the following: + + 1. A series of actions may occur ("Provisioning Process") in which a user may execute + the Provisioning Technology on a machine ("Target Machine") with the intent of installing, + extending or updating the functionality of an Eclipse-based product. + 2. During the Provisioning Process, the Provisioning Technology may cause third party + Installable Software or a portion thereof to be accessed and copied to the Target Machine. + 3. Pursuant to the Specification, you will provide to the user the terms and conditions that + govern the use of the Installable Software ("Installable Software Agreement") and such + Installable Software Agreement shall be accessed from the Target Machine in accordance + with the Specification. Such Installable Software Agreement must inform the user of the + terms and conditions that govern the Installable Software and must solicit acceptance by + the end user in the manner prescribed in such Installable Software Agreement. Upon such + indication of agreement by the user, the provisioning Technology will complete installation + of the Installable Software. + +Cryptography + +Content may contain encryption software. The country in which you are +currently may have restrictions on the import, possession, and use, +and/or re-export to another country, of encryption software. BEFORE +using any encryption software, please check the country's laws, +regulations and policies concerning the import, possession, or use, and +re-export of encryption software, to see if this is permitted. + +Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both. </license> <plugin |