diff options
author | Cédric Bosdonnat <cedricbosdo@openoffice.org> | 2010-11-24 22:35:30 +0100 |
---|---|---|
committer | Cédric Bosdonnat <cedricbosdo@openoffice.org> | 2010-11-24 22:35:30 +0100 |
commit | 043b49ff333c0d07ab22dab4ec975fe51d6cee85 (patch) | |
tree | cde9ec852dd1787fc70169e4295e92444a3e9f25 /packager | |
parent | c8114e54d7f433c48fd0f3d54e3e7f16758865a5 (diff) |
Added the build scripts for the packager plugin.
Fetches the sources of the ooo-plugin-packager from git's HEAD.
Diffstat (limited to 'packager')
-rw-r--r-- | packager/.classpath | 2 | ||||
-rw-r--r-- | packager/.externalToolBuilders/Sources update.launch | 20 | ||||
-rw-r--r-- | packager/.gitignore | 1 | ||||
-rw-r--r-- | packager/.project | 10 | ||||
-rw-r--r-- | packager/META-INF/MANIFEST.MF | 3 | ||||
-rw-r--r-- | packager/README.txt | 4 | ||||
-rw-r--r-- | packager/build.properties | 5 | ||||
-rw-r--r-- | packager/build/MANIFEST.MF.in | 3 | ||||
-rw-r--r-- | packager/build/build.properties | 4 | ||||
-rw-r--r-- | packager/build/build.xml | 86 |
10 files changed, 83 insertions, 55 deletions
diff --git a/packager/.classpath b/packager/.classpath index c5d47ad..3402384 100644 --- a/packager/.classpath +++ b/packager/.classpath @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <classpath> - <classpathentry exported="true" kind="lib" path="ooo-plugin-packager-core-0.1.0-SNAPSHOT.jar" sourcepath="/ooo-plugin-packager-core/src/main/java"/> + <classpathentry kind="src" path="source/ooo-plugin-packager-core/src/main/java"/> <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/> <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> <classpathentry kind="output" path="bin"/> diff --git a/packager/.externalToolBuilders/Sources update.launch b/packager/.externalToolBuilders/Sources update.launch new file mode 100644 index 0000000..465b0d9 --- /dev/null +++ b/packager/.externalToolBuilders/Sources update.launch @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<launchConfiguration type="org.eclipse.ant.AntBuilderLaunchConfigurationType"> +<booleanAttribute key="org.eclipse.ant.ui.ATTR_TARGETS_UPDATED" value="true"/> +<booleanAttribute key="org.eclipse.ant.ui.DEFAULT_VM_INSTALL" value="false"/> +<stringAttribute key="org.eclipse.debug.core.ATTR_REFRESH_SCOPE" value="${workspace}"/> +<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS"> +<listEntry value="/org.openoffice.ide.packager.core/build/build.xml"/> +</listAttribute> +<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES"> +<listEntry value="1"/> +</listAttribute> +<booleanAttribute key="org.eclipse.debug.ui.ATTR_LAUNCH_IN_BACKGROUND" value="false"/> +<stringAttribute key="org.eclipse.jdt.launching.CLASSPATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/> +<booleanAttribute key="org.eclipse.jdt.launching.DEFAULT_CLASSPATH" value="true"/> +<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="org.openoffice.ide.packager.core"/> +<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="${workspace_loc:/org.openoffice.ide.packager.core/build/build.xml}"/> +<stringAttribute key="org.eclipse.ui.externaltools.ATTR_RUN_BUILD_KINDS" value=""/> +<booleanAttribute key="org.eclipse.ui.externaltools.ATTR_TRIGGERS_CONFIGURED" value="true"/> +<stringAttribute key="org.eclipse.ui.externaltools.ATTR_WORKING_DIRECTORY" value="${workspace_loc:/org.openoffice.ide.packager.core}"/> +</launchConfiguration> diff --git a/packager/.gitignore b/packager/.gitignore index d392f0e..9546c6c 100644 --- a/packager/.gitignore +++ b/packager/.gitignore @@ -1 +1,2 @@ *.jar +source diff --git a/packager/.project b/packager/.project index b36f88f..c052e77 100644 --- a/packager/.project +++ b/packager/.project @@ -6,6 +6,16 @@ </projects> <buildSpec> <buildCommand> + <name>org.eclipse.ui.externaltools.ExternalToolBuilder</name> + <triggers>full,incremental,</triggers> + <arguments> + <dictionary> + <key>LaunchConfigHandle</key> + <value><project>/.externalToolBuilders/Sources update.launch</value> + </dictionary> + </arguments> + </buildCommand> + <buildCommand> <name>org.eclipse.jdt.core.javabuilder</name> <arguments> </arguments> diff --git a/packager/META-INF/MANIFEST.MF b/packager/META-INF/MANIFEST.MF index a2ebd5b..a271484 100644 --- a/packager/META-INF/MANIFEST.MF +++ b/packager/META-INF/MANIFEST.MF @@ -6,8 +6,5 @@ Bundle-Version: 0.1.0 Bundle-Vendor: Cédric Bosdonnat Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Bundle-ActivationPolicy: lazy -Bundle-ClassPath: ooo-plugin-packager-core-0.1.0-SNAPSHOT.jar, - . Export-Package: org.openoffice.plugin.core.model, org.openoffice.plugin.core.utils -Require-Bundle: org.apache.commons.lang;bundle-version="2.3.0" diff --git a/packager/README.txt b/packager/README.txt new file mode 100644 index 0000000..d623302 --- /dev/null +++ b/packager/README.txt @@ -0,0 +1,4 @@ +This project isn't intended to contain any changed source: everything should be fetched from the +ooo-plugin-packager Git repository. The META-INF/MANIFEST.MF file is present only for building +inside Eclipse and thus testing the plugins easily. Please edit the build/MANIFEST.MF.in for changes +to be distributed in the plugin.
\ No newline at end of file diff --git a/packager/build.properties b/packager/build.properties index 9abde93..b2b1ead 100644 --- a/packager/build.properties +++ b/packager/build.properties @@ -1,5 +1,2 @@ -source.. = src/ output.. = bin/ -bin.includes = META-INF/,\ - .,\ - ooo-plugin-packager-core-0.1.0-SNAPSHOT.jar +bin.includes = META-INF/ diff --git a/packager/build/MANIFEST.MF.in b/packager/build/MANIFEST.MF.in index ac1cb47..69578ed 100644 --- a/packager/build/MANIFEST.MF.in +++ b/packager/build/MANIFEST.MF.in @@ -6,8 +6,5 @@ Bundle-Version: @VERSION@ Bundle-Vendor: Cédric Bosdonnat Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Bundle-ActivationPolicy: lazy -Bundle-ClassPath: ooo-plugin-packager-core-0.1.0-SNAPSHOT.jar, - . Export-Package: org.openoffice.plugin.core.model, org.openoffice.plugin.core.utils -Require-Bundle: org.apache.commons.lang;bundle-version="2.3.0" diff --git a/packager/build/build.properties b/packager/build/build.properties index d99e73e..5685767 100644 --- a/packager/build/build.properties +++ b/packager/build/build.properties @@ -1,4 +1,4 @@ #Wed Apr 26 20:26:48 CEST 2006 -packager.plugin.version=1.0.0 +packager.plugin.version=0.1.0 debug=true -packager.git.repo=git://github.com/fredericmorin/ooo-plugin-packager.git +packager.git.repo=git://github.com/fredericmorin/ooo-plugin-packager.git
\ No newline at end of file diff --git a/packager/build/build.xml b/packager/build/build.xml index 2fc4fb7..ed7b28f 100644 --- a/packager/build/build.xml +++ b/packager/build/build.xml @@ -1,16 +1,35 @@ <?xml version="1.0"?> - -<project name="packager" default="packager.error"> - - - <target name="packager.error"> - <fail>Wrong target! - - This script should not be executed directly. - Please, use the one in the build project - </fail> - </target> - +<!-- ====================================================================== + * + * The Contents of this file are made available subject to the terms of + * the GNU Lesser General Public License Version 2.1 + * + * GNU Lesser General Public License Version 2.1 + * ============================================= + * Copyright 2009 by Cédric Bosdonnat. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License version 2.1, as published by the Free Software Foundation. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, + * MA 02111-1307 USA + * + * The Initial Developer of the Original Code is: Cédric Bosdonnat. + * + * Copyright: 2009 by Cédric Bosdonnat. + * + * All Rights Reserved. + * + ====================================================================== --> +<project name="packager" default="update-sources"> <target name="init-env"> <dirname property="packager.basedir" file="${ant.file.packager}/.."/> @@ -19,22 +38,14 @@ <property name="packager.out.path" value="${packager.basedir}/bin/ant" /> <property name="packager.out.classes" value="${packager.out.path}/classes"/> - <property name="packager.sources" value="${packager.out.path}/source"/> - - <path id="packager.dependencies.path"> - <fileset dir="${eclipse.home}/plugins/"> - <include name="org.apache.commons.lang*.jar"/> - </fileset> - </path> + <property name="packager.sources" value="${packager.basedir}/source"/> <mkdir dir="${packager.out.path}/features" /> <mkdir dir="${packager.out.path}/plugins" /> <mkdir dir="${packager.out.classes}" /> <condition property="packager.sources.cloned"> - <resourceexists> - <file file="${packager.sources}"/> - </resourceexists> + <available file="${packager.sources}"/> </condition> </target> @@ -44,18 +55,8 @@ <delete dir="${packager.out.path}" /> </target> - <!-- - <target name="packager.compile" depends="init-env"> - <javac srcdir="${packager.sources}" destdir="${packager.out.classes}" - target="1.5" source="1.5" - debug="${debug}" - classpathref="packager.dependencies.path" - excludes="**/unittests/**"/> - </target> - --> - <target name="clone-sources" depends="init-env" unless="packager.sources.cloned"> - <exec executable="git" dir="${packager.out.path}"> + <exec executable="git" dir="${packager.basedir}"> <arg line="clone ${packager.git.repo}"/> <arg line="source"/> </exec> @@ -66,27 +67,28 @@ <arg line="pull -r"/> </exec> </target> - - <target name="compile-jar" depends="init-env, clone-sources, pull-sources"> - + + <target name="update-sources" depends="clone-sources, pull-sources" description="Update the packager sources from git"/> + + <target name="packager-compile" depends="init-env, update-sources"> + <javac srcdir="${packager.sources}/ooo-plugin-packager-core/src/main" destdir="${packager.out.classes}" + target="1.5" source="1.5" + debug="${debug}"/> </target> - <target name="packager.plugin" depends="compile-jar"> + <target name="packager.plugin" depends="packager-compile"> <copy file="${packager.basedir}/build/MANIFEST.MF.in" tofile="${packager.out.path}/MANIFEST.MF" /> <replace file="${packager.out.path}/MANIFEST.MF" token="@VERSION@" value="${packager.plugin.version}" /> - <jar destfile="${packager.out.path}/plugins/${package.prefix}.java_${packager.plugin.version}.jar" + <jar destfile="${packager.out.path}/plugins/${package.prefix}.packager.core_${packager.plugin.version}.jar" manifest="${packager.out.path}/MANIFEST.MF"> - <zipfileset prefix="" dir="${packager.sources}"> + <zipfileset prefix="" dir="${packager.sources}/ooo-plugin-packager-core/src/main"> <exclude name="**/*.java"/> </zipfileset> <zipfileset prefix="" dir="${packager.out.classes}"/> - - <zipfileset prefix="icons" dir="${packager.basedir}/icons"/> - <zipfileset prefix="" file="${packager.basedir}/plugin.xml" /> </jar> </target> |