[ooo-build-commit] extensions/ooo2gd

Kohei Yoshida kohei at kemper.freedesktop.org
Fri Jan 8 20:19:13 PST 2010


 extensions/ooo2gd/README    |   17 +++++++++
 extensions/ooo2gd/build.xml |   83 ++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 100 insertions(+)

New commits:
commit de5e248b11fcac70351987f81c2b771bd88d29f5
Author: Kohei Yoshida <kyoshida at novell.com>
Date:   Fri Jan 8 23:13:34 2010 -0500

    Our own ant build file for building ooo2gd.
    
    I had to create my own build.xml to work around the fact that:
    
    1) ooo2gd's author uses NetBeans to develop this extension, which
       auto-generates a set of horrible-looking, hard-to-understand
       ant build files (not to mention useless ones for non-NetBeans
       users), and
    
    2) the author has refused to check in all necessary build files
       generated by NetBeans, believing that you should use NetBeans
       to build this extension, which is silly.
    
    * extensions/ooo2gd/README:
    * extensions/ooo2gd/build.xml:

diff --git a/extensions/ooo2gd/README b/extensions/ooo2gd/README
new file mode 100644
index 0000000..12845af
--- /dev/null
+++ b/extensions/ooo2gd/README
@@ -0,0 +1,17 @@
+This directory only contains the ant build file (build.xml) that you can use 
+to build ooo2gd extension from http://code.google.com/p/ooo2gd .  To use, 
+check out the sources from their repository and replace their build.xml with 
+ours.
+
+  svn checkout http://ooo2gd.googlecode.com/svn/trunk/\ ooo2gd repo
+  cd repo
+  cp ../build.xml ./
+  [...edit build.xml to taylor to your system...]
+  ant pack
+
+Note the whitespace in front of the directory name 'ooo2gd', which the author
+mistakenly put it thinking it was to satisfy Google's intention.  Anyway, he
+has no intention of fixing it, so we'll have to deal with that. :-/
+
+I last tried it with version 2.1.0.  So, if you are trying to build later 
+versions you may need to update our build.xml.
diff --git a/extensions/ooo2gd/build.xml b/extensions/ooo2gd/build.xml
new file mode 100644
index 0000000..03eee87
--- /dev/null
+++ b/extensions/ooo2gd/build.xml
@@ -0,0 +1,83 @@
+<project name="ooo2gd" default="build" basedir=".">
+
+    <property name="src" location="src"/>
+    <property name="build" location="build"/>
+
+    <!-- For jar files bundled with NetBeans.  Modify 'nbpath' to your netbeans installation. -->
+    <property name="nbpath" value="/home/kyoshida/Download/netbeans-6.8"/>
+    <property name="nbp11path" value="${nbpath}/platform11/modules/ext"/>
+    <property name="nbjava3path" value="${nbpath}/java3/modules/ext"/>
+
+    <property name="version" value="2.1.0"/>
+
+    <property name="ooodir" value="/usr/lib/ooo3"/>
+    <property name="basisdir" value="${ooodir}/basis3.1"/>
+    <property name="clsdir" value="${ooodir}/ure/share/java"/>
+    <property name="external_jars" value="libs/activation.jar:libs/gdata-client-1.0.jar:libs/gdata-client-meta-1.0.jar:libs/gdata-core-1.0.jar:libs/gdata-docs-2.0.jar:libs/gdata-media-1.0.jar:libs/gdata-spreadsheet-3.0.jar:libs/gdata-spreadsheet-meta-3.0.jar:libs/google-collect-1.0-rc1.jar:libs/mail-1.4.jar"/>
+    <property name="ooo_jars" value="${clsdir}/jurt.jar:${clsdir}/juh.jar:${clsdir}/sandbox.jar:${clsdir}/unoil.jar:${clsdir}/ridl.jar"/>
+    <property name="clspath" value="${external_jars}:${ooo_jars}:${nbp11path}/swing-layout-1.0.4.jar:."/>
+
+    <property name="extjarname" value="GDocs.jar"/>
+    <property name="packname" value="gdocs_${version}.oxt"/>
+
+    <property name="idlc" value="${ooodir}/solver/bin/idlc"/>
+    <property name="javamaker" value="${ooodir}/solver/bin/javamaker"/>
+    <property name="types.rdb" value="${ooodir}/solver/bin/types.rdb"/>
+    <property name="regmerge" value="${ooodir}/ure/bin/regmerge"/>
+    <property name="libpath" value="/usr/lib/ooo3/ure/lib:"/>
+
+    <target name="com">
+        <exec executable="${javamaker}">
+            <env key="LD_LIBRARY_PATH" value="${libpath}"/>
+            <arg value="-BUCR"/>
+            <arg file="${types.rdb}"/>
+        </exec>
+    </target>
+    <target name="build" depends="com">
+        <mkdir dir="${build}"/>
+        <javac srcdir="${src}" destdir="${build}" classpath="${clspath}">
+            <compilerarg value="-Xlint:unchecked"/>
+            <compilerarg value="-Xlint:deprecation"/>
+        </javac>
+        <jar destfile="${extjarname}" basedir="${build}">
+            <manifest>
+                <attribute name="UNO-Type-Path" value=""/>
+                <attribute name="RegistrationClassName" value="org.openoffice.gdocs.CentralRegistrationClass"/>
+                <!-- We need to have the class-path autogenerated. -->
+                <attribute name="Class-Path" value="external_jars/gdata-client-1.0.jar external_jars/gdata-client-meta-1.0.jar external_jars/gdata-core-1.0.jar external_jars/gdata-media-1.0.jar external_jars/mail-1.4.jar external_jars/gdata-docs-2.0.jar external_jars/swing-layout-1.0.4.jar external_jars/activation.jar external_jars/gdata-spreadsheet-3.0.jar external_jars/gdata-spreadsheet-meta-3.0.jar external_jars/google-collect-1.0-rc1.jar external_jars/AbsoluteLayout.jar"/>
+                <section name="org/openoffice/gdocs/CentralRegistrationClass.class">
+                    <attribute name="RegistrationClasses" value="org.openoffice.gdocs.GDocs"/>
+                </section>
+            </manifest>
+            <fileset dir="src" includes="org/openoffice/gdocs/resources/*"/>
+        </jar>
+    </target>
+    <target name="pack" depends="build">
+        <zip destfile="${packname}">
+            <zipfileset dir="${nbp11path}" includes="swing-layout-1.0.4.jar" prefix="external_jars"/>
+            <zipfileset dir="${nbjava3path}" includes="AbsoluteLayout.jar" prefix="external_jars"/>
+            <zipfileset dir="libs" includes="*.jar" prefix="external_jars"/>
+            <fileset dir="." includes="${extjarname}"/>
+            <fileset dir="." includes="images/*"/>
+            <fileset dir="." includes="description/description.txt"/>
+            <fileset dir="src" includes="*.xcu"/>
+            <fileset dir="src" includes="description.xml"/>
+            <fileset dir="src" includes="org/openoffice/gdocs/resources/*.properties"/>
+            <zipfileset dir="src" includes="uno-extension-manifest.xml" fullpath="META-INF/manifest.xml"/>
+        </zip>
+    </target>
+
+    <target name="clean">
+        <delete includeemptydirs="true" failonerror="false">
+            <fileset dir="." includes="${extjarname}"/>
+            <fileset dir="." includes="${packname}"/>
+            <fileset dir="${build}"/>
+        </delete>
+    </target>
+    <target name="distclean" depends="clean">
+        <delete includeemptydirs="true" failonerror="false">
+            <fileset dir="com"/>
+            <fileset dir="drafts"/>
+        </delete>
+    </target>
+</project>


More information about the ooo-build-commit mailing list