xref: /aoo42x/main/odk/docs/install.html (revision 122c3632)
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
2<!--
3#**************************************************************
4#
5#  Licensed to the Apache Software Foundation (ASF) under one
6#  or more contributor license agreements.  See the NOTICE file
7#  distributed with this work for additional information
8#  regarding copyright ownership.  The ASF licenses this file
9#  to you under the Apache License, Version 2.0 (the
10#  "License"); you may not use this file except in compliance
11#  with the License.  You may obtain a copy of the License at
12#
13#    http://www.apache.org/licenses/LICENSE-2.0
14#
15#  Unless required by applicable law or agreed to in writing,
16#  software distributed under the License is distributed on an
17#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
18#  KIND, either express or implied.  See the License for the
19#  specific language governing permissions and limitations
20#  under the License.
21#
22#**************************************************************
23 -->
24<html>
25<head>
26  <title>Apache OpenOffice %PRODUCT_RELEASE% SDK - Installation Guide</title>
27  <link rel="stylesheet" type="text/css" href="sdk_styles.css">
28  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
29  <meta name="author" content="J&uuml;rgen Schmidt">
30  <meta name="created" content="2004-12-14">
31</head>
32<body class="sdkbody"><a name="install"/>
33<table class="table1" cellpadding=0>
34  <tr style="background-image:url(images/sdk_head-2.png)">
35    <td colspan="3" align="left"><img src="images/sdk_head-1.png" width="800" height="120" usemap="#Map" border="0"></td>
36  </tr>
37  <tr>
38    <td colspan="3"><img  class="nothing10" src="images/nada.gif"></td>
39  </tr>
40  <tr>
41    <td class="content1"><img class="nothing8" src="images/nada.gif"></td>
42    <td>
43      <table class="table2">
44	    <tr>
45		  <td colspan="3"><img class="nothing1" src="images/nada.gif"></td>
46        </tr>
47        <tr>
48          <td>
49          <table class="table3">
50		  <tr>
51			<td colspan="2" class="head1">Installation Guide</td>
52			<td align="right"><a href="../index.html" title="link to the SDK start page"><img class="navigate" src="images/nav_home.png"></a></td>
53		  </tr>
54		  </table>
55          </td>
56        </tr>
57		<tr>
58          <td>
59          <table class="table3">
60		  <tr>
61		  <td colspan="2">
62		  <p>The Apache OpenOffice %PRODUCT_RELEASE% SDK comes with a set of development tools, base
63		  libraries, header files and helper class files that can be used to
64		  develop Java/C++ components, to embed the Apache OpenOffice %PRODUCT_RELEASE% application in
65          your own programs, or to use the API (scripting or remote control the
66		  office). For a complete working environment, we have some additional
67		  requirements:</p>
68		  </td>
69		  </tr>
70		  <tr valign="top">
71          <td><b>Apache OpenOffice %PRODUCT_RELEASE% installation</td>
72          <td class="content80">The SDK works on top of an existing office
73		  installation and uses the same libraries as the office installation.</td>
74          </tr>
75		  </tr>
76		  <tr valign="middle">
77            <td colspan="2"><img class="line" src="images/sdk_line-1.gif"></td>
78          </tr>
79		  <tr valign="top">
80          <td><b>JDK (1.5 or higher)<b></td>
81          <td class="content80">
82		  <p>A JDK is necessary for developing Java components or applications. An appropriate Java SDK can be found on <a target="_blank" href="http://java.sun.com/products" title="link to the Java SDK download page (online)">http://java.sun.com/products</a>.</p>
83		  <p>Recommendation is to use Java 6 excepting for Mac OS because initially Mac OS supported a 64bit version of Java 6 only.</p>
84		  <p><b>Note</b>: The Java compiler is <b><u>optional</u></b>!</p></td>
85          </tr>
86		  <tr valign="middle">
87            <td colspan="2"><img class="line" src="images/sdk_line-1.gif"></td>
88          </tr>
89		  <tr valign="top">
90          <td><b>C++ compiler<b></td>
91          <td class="content80">A C++ compiler is necessary for developing C++
92		  components or applications. UNO depends on a compiler dependent language
93		  binding, so that we use the appropriate compiler where a language binding
94		  exists:
95		  <table class="table4">
96		  <tr>
97		  <td class="cell15">Solaris</td>
98		  <td class="cell85">Sun Studion 8 (20070730)</td>
99		  </tr>
100		  <tr>
101		  <td class="cell15">Linux</td>
102		  <td class="cell80">GNU C++ compiler, gcc version 4.0.1</td>
103		  </tr>
104		  <tr>
105		  <td class="cell15">Windows</td>
106		  <td class="cell80">Microsoft C++ Compiler, Microsoft Visual Studio 2008 or the Express version (cl, version 15.00.21022)</td>
107		  </tr>
108		  </table>
109		  <p><b>Note</b>: The C++ compiler is <b><u>optional</u></b>! If you use the Express edition you have to ensure that the <a href="http://www.microsoft.com/downloads/details.aspx?familyid=9B2DA534-3E03-4391-8A4D-074B9F2BC1BF&displaylang=en">Microsoft Visual Studio 2008 Redistributable Package</a> is also installed. You can download this package from Microsoft directly.</a></p></td>
110          </tr>
111		  <tr valign="middle">
112            <td colspan="2"><img class="line" src="images/sdk_line-1.gif"></td>
113          </tr>
114		  <tr valign="top">
115          <td><b>Microsoft .NET Framework SDK version 1.0 or higher<b></td>
116          <td class="content80">The SDK is required for building CLI applications.
117		  That is, programs written in languages, such as C# or VB.NET.<br>
118		  <p><b>Note</b>: The .NET Framework is <b><u>optional</u></b>!</p></td>
119          </tr>
120		  <tr valign="middle">
121            <td colspan="2"><img class="line" src="images/sdk_line-1.gif"></td>
122          </tr>
123		  <tr valign="top">
124          <td><b>GNU make (3.79.1 or higher)<b></td>
125          <td class="content80">
126		  <p>GNU make is used to build the examples of the SDK. GNU make is available from <a target="_blank" href="http://www.gnu.org" title="link to www.gnu.org (online)">http://www.gnu.org</a>. It can be ftped via <a target="_blank" href="ftp://ftp.gnu.org/gnu/make" title="link to gnumake on www.gnu.org (online)">ftp://ftp.gnu.org/gnu/make</a></p>
127		  <p><b>Note</b>: Windows user can find an executable of gnu make under <a target="_blank" href="http://www.mingw.org/wiki/Getting_Started" title="link to the MinGW Getting Started wiki (online)">http://www.mingw.org/wiki/Getting_Started</a> (see the mingw32-make link under &quot;Manual Installation&quot;). Do not use the Cygwin make, because it does not
128		  work well. On Solaris gnu make can be found often under <b><i>/usr/sfw/bin/gmake</i></b>, but keep in mind that you have to use <b>'gmake'</b> then. Or you can find gnu make also under <a target="_blank" href="http://www.sunfreeware.com/" title="link to www.sunfreeware.com (online)">http://www.sunfreeware.com/</a>.</td>
129          </tr>
130		  <tr valign="middle">
131            <td colspan="2"><img class="line" src="images/sdk_line-1.gif"></td>
132          </tr>
133		  <tr valign="top">
134          <td><b>zip tool (2.3 or higher)<b></td>
135          <td class="content80">The zip tool is used to create UNO packages. zip is
136		  a new requirement to make the SDK independent of a Java SDK.<br>
137		  If you do not have these already, you can download them from <a target="_blank" href="http://www.info-zip.org" title="link to www.ubfi-zip.org (online)">http://www.info-zip.org</a>. Note: The cygwin zip.exe does not work for the build under
138		  the 4NT shell. You have to use the native w32 version.</td>
139          </tr>
140		  <tr valign="middle">
141            <td colspan="2"><img class="line" src="images/sdk_line-1.gif"></td>
142          </tr>
143		  <tr>
144		    <td><img class="nothing10" src="images/nada.gif"></td>
145			<td align="right">
146			<a href="#install" title="link to the top of this page"><img class="navigate" src="images/nav_up.png"></a>
147			<a href="../index.html" title="link to the SDK start page"><img class="navigate" src="images/nav_home.png"></a></td>
148		  </tr>
149		  <tr valign="middle">
150          <td colspan="2">
151		  <p>The SDK provides an implicit configuration mechanism, which
152		  configures the SDK build environment to your personal needs the first
153		  time you use the SDK environment. This configuration step creates one or
154		  two new setsdkenv_XXX scripts in the user's home directory:</P>
155		  <ul>
156		    <li><b>$HOME/$OO_SDK_NAME/setsdkenv_unix.sh</b> and <b>$HOME/$OO_SDK_NAME/setsdkenv_unix.csh</b>&nbsp;&nbsp;-> for Unix
157            <li><b>C:\Documents and Settings\&lt;username&gt;\Application Data\%OO_SDK_NAME%\setsdkenv_windows.bat</b></a>&nbsp;&nbsp;-> for Windows2000/XP or later
158          </ul>
159		  <p>The automatically started configure script (Unix and Windows2000/XP)
160		  requests relevant information and directories (SDK, the Office, GNU make,
161		  Java, C++), in order to prepare a working SDK environment. After completing the
162		  configure script once, the newly created script is always used to set the
163		  necessary environment variables for using the SDK and the required
164		  tools.</P>
165		  <p>On UNIX operating systems, the configure script uses Perl. LINUX systems should have
166		  installed a working Perl version, and on Solaris you can find a working
167		  Perl version under <a target="_blank" href="http://www.sunfreeware.com/" title="link to www.sunfreeware.com (online)">http://www.sunfreeware.com/</a> if
168		  necessary. On Windows, the configure script uses Windows Script and
169		  a JScipt. If you have problems with Windows Script, you can download a
170		  newer version of <a href ="http://www.microsoft.com/downloads/details.aspx?FamilyId=C717D943-7E4B-4622-86EB-95A22B832CAA&displaylang=en" link"link to the download page for the Windows Script">Windows Script</a>.
171          </p>
172          <p>On other versions of Windows, use the batch
173		  file template <b>&lt;OO_SDK_HOME&gt;\setsdkenv_windows.template</b>,
174		  rename it to *.bat, and adapt it to your local environment.</p>
175		  <p>If you use the template batch file, edit and set
176		  the following variables:</p>
177		  <table class="table4">
178		  <tr valign="top">
179		  <td class="cell20"><b>OFFICE_HOME</b></td>
180		  <td class="cell80">Path to an existing Apache OpenOffice
181		  base installation, e.g. &quot;/opt/openoffice.org3&quot;. Be sure
182		  that it is not a user installation only. Exactly one of OFFICE_HOME
183          and OO_SDK_URE_HOME must be set. The other should be either unset or
184          set to an empty value.</td>
185		  </tr>
186          <tr><a name="oosdkname"/>
187          <td class="cell20"><b>OO_SDK_NAME</b></td>
188          <td class="cell80">The configuration uses the
189		  directory name of the SDK, but you can use another name as well.
190		  It is important that the name does not contain spaces, because of a limitation
191		  of gnu make which cannot handle spaces correctly. This name is, for
192		  example, used to create an output directory in the users home directory
193		  for any generated output when you use the SDK build environment.</td>
194          </tr>
195          <tr>
196          <td class="cell20"><b>OO_SDK_URE_HOME</b></td>
197          <td class="cell80">Path to an existing UNO Runtime Environment
198          installation, e.g. &quot;/opt/openoffice.org/ure&quot;. Exactly one of
199          OFFICE_HOME and OO_SDK_URE_HOME must be set. The other should be
200          either unset or set to an empty value.</td>
201          </tr>
202		  <tr>
203		  <td class="cell20"><b>OO_SDK_HOME</b></td>
204		  <td class="cell80">Path to the SDK root directory, e.g.
205		  &quot;/usr/local/StarOffice8_SDK&quot;</td>
206		  </tr>
207		  <tr>
208		  <td class="cell20"><b>OO_SDK_JAVA_HOME</b></td>
209		  <td class="cell80">Path to a JDK root directory. The JDK is
210		  <b>optional</b> and only necessary if you like to run the Java examples
211		  or if you like to use the SDK environment to develop your own Java
212		  solution.</td>
213		  </tr>
214		  <tr>
215		  <td class="cell20"><b>OO_SDK_CPP_HOME</b></td>
216		  <td class="cell80">Path to the C++ compiler (on Windows, the directory
217		  where the &quot;<i>vcvar32.bat</i>&quot; file can be found). The C++
218		  compiler is <b>optional</b> and only necessary for building the C++
219		  examples.</td>
220		  </tr>
221		  <tr>
222		  <td class="cell20"><b>OO_SDK_CLI_HOME</b></td>
223		  <td class="cell80">Path to the C# compiler and VB.NET compiler (on
224		  Windows, this directory can be found under the system directory (e.g.
225		  c:\WINXP\Microsoft.NET\Framework\v1.0.3705). The compilers are
226		  <b>optional</b> and only necessary for building the CLI examples.<br>
227		  <b>Note: Windows only!</b></td>
228		  </tr>
229		  <tr>
230		  <td class="cell20"><b>OO_SDK_MAKE_HOME</b></td>
231		  <td class="cell80">Path to GNU make.</td>
232		  </tr>
233		  <tr>
234		  <td class="cell20"><b>OO_SDK_ZIP_HOME</b></td>
235		  <td class="cell80">Path to the 'zip' tool.</td>
236		  </tr>
237		  <tr>
238		  <td class="cell20"><b>OO_SDK_OUTPUT_DIR</b></td>
239		  <td class="cell80">Path to an existing directory where the example output
240		  is generated. The output directory is <b>optional</b>, by default
241		  the output is generated in the SDK directory itself. If an output
242		  directory is specified, the output is generated in a SDK dependent
243		  subdirectory in this directory (e.g. &lt;OO_SDK_OUTPUT_DIR&gt;
244		  /OpenOffice.org %PRODUCT_RELEASE%/LINUXExample.out)</td>
245		  </tr>
246		  <tr>
247		  <td class="cell20"><b>SDK_AUTO_DEPLOYMENT</b></td>
248		  <td class="cell80">If this variable is set, the component examples are automatically deployed into the Office installation referenced by
249		  OFFICE_HOME. See also chapter <a href="http://wiki.services.openoffice.org/wiki/Documentation/DevGuide/Extensions/unopkg" title="link to the &quot;Extension Manager - unopkg&quot; chapter in the Developer's Guide">&quot;Extension Manager - unopkg&quot;</a> from the Developer's Guide.
250          This variable is only relevant when OFFICE_HOME is set.</td>
251		  </tr>
252		  </table>
253		  <p>You must run the <b>setsdkenv_XXX</b> script every time you want to
254		  use the configured SDK environment. The settings are local for the current
255		  shell on Windows or the new started shell on UNIX. On UNIX you
256		  can now source one of the prepared environment
257		  script files (&quot;setsdkenv_unix.sh&quot; or
258		  &quot;setsdkenv_unix.csh&quot; dependending on the shell you use) to prepare
259		  your current shell instead of starting a new shell.</p>
260		  </td>
261          </tr>
262		  <tr valign="middle">
263            <td colspan="2"><img class="line" src="images/sdk_line-1.gif"></td>
264          </tr>
265		  <tr>
266		    <td><img class="nothing10" src="images/nada.gif"></td>
267			<td align="right">
268			<a href="#install" title="link to the top of this page"><img class="navigate" src="images/nav_up.png"></a>
269			<a href="../index.html" title="link to the SDK start page"><img class="navigate" src="images/nav_home.png"></a></td>
270		  </tr>
271		  <tr>
272		  <td colspan="2">
273		  <p class="head2">Manual Setting</p>
274		  <p>If you do not want to use the script to set your working
275		  environment, you must set the appropriate environment variables
276		  yourself. The script sets the following environment variables:</p>
277		  <p class="head3">Common Environment Variables</p>
278		  <table class="table4">
279          <tr valign="top">
280          <td class="cell20">OO_SDK_NAME</td>
281          <td class="cell80">See description <a href="#oosdkname" title="link to the description of the environment variable OO_SDK_NAME">above</a>.</td>
282          </tr>
283          <tr valign="top">
284          <td class="cell20">OO_SDK_URE_BIN_DIR</td>
285          <td class="cell80">The path within the chosen office or URE
286          installation where binary executables are located (e.g.,
287          <i>$OFFICE_HOME/program</i> for an office installation, or
288          <i>$OO_SDK_URE_HOME/bin</i> for a Unix URE installation).</td>
289          </tr>
290          <tr valign="top">
291          <td class="cell20">OO_SDK_URE_LIB_DIR</td>
292          <td class="cell80">The path within the chosen office or URE
293          installation where dynamic libraries are located (e.g.,
294          <i>$OFFICE_HOME/program</i> for an office installation, or
295          <i>$OO_SDK_URE_HOME/lib</i> for a Unix URE installation).</td>
296          </tr>
297          <tr valign="top">
298          <td class="cell20">OO_SDK_URE_JAVA_DIR</td>
299          <td class="cell80">The path within the chosen office or URE
300          installation where Java JARs are located (e.g.,
301          <i>$OFFICE_HOME/program/classes</i> for an office installation, or
302          <i>$OO_SDK_URE_HOME/share/java</i> for a Unix URE installation).</td>
303          </tr>
304		  <tr valign="top">
305		  <td class="cell20">CLASSPATH</td>
306		  <td class="cell80">
307          =<i>$OO_SDK_URE_JAVA_DIR/juh.jar;
308              $OO_SDK_URE_JAVA_DIR/jurt.jar;
309              $OO_SDK_URE_JAVA_DIR/ridl.jar;
310              $OO_SDK_URE_JAVA_DIR/unoloader.jar;
311              [$OO_SDK_URE_JAVA_DIR/unoil.jar;]
312              $CLASSPATH</i><br>
313          <p>The classpath will be set or extended to the necessary jar files of
314		  the specified office installation. (<i>unoil.jar</i> is only included
315          when OFFICE_HOME is set.)</p>
316		  </td>
317		  </tr>
318		  <tr valign="top">
319		  <td class="cell20">OFFICE_PROGRAM_PATH</td>
320		  <td class="cell80">=<i>$OFFICE_HOME/program</i><br>
321		  <p>This variable is used to find, for example, the office type library and
322		  the UNO package deployment tool. This variable is only relevant when
323          OFFICE_HOME is set.</p>
324		  </td>
325		  </tr>
326		  <tr valign="top">
327		  <td class="cell20">UNO_PATH</td>
328		  <td class="cell80">=<i>$OFFICE_PROGRAM_PATH</i><br>
329          <p>This variable is used to ensure that the new C++ UNO bootstrap
330		  mechanism uses the configured office installation of the SDK. Normally
331		  the bootstrap mechanism finds the default office installation for the
332		  user on the system. This variable is optional but is set from the scripts
333		  to ensure a homogeneous environment. Especially useful during development
334		  where you might have more than one office installation installed. This
335          variable is only relevant when OFFICE_HOME is set.</p>
336		  </td>
337		  </tr>
338		  </table>
339		  <p class="head3">Environment Variables for UNIX</p>
340		  <p class="head4">Solaris</p>
341		  <table class="table4">
342		  <tr valign="top">
343		  <td class="cell20">LD_LIBRARY_PATH</td>
344		  <td class="cell80">=<i>$OO_SDK_URE_LIB_DIR: $OO_SDK_HOME/(solsparc|solintel)/lib: $LD_LIBRARY_PATH</i><br>
345		  <p>The LD_LIBRARY_PATH will be set or will be extended by the office/URE
346		  library path, the platform dependent lib directory for several additional
347		  libraries.</p>
348		  </td>
349		  </tr>
350		  <tr valign="top">
351		  <td class="cell20">PATH</td>
352		  <td class="cell80">=<i>$OO_SDK_HOME/(solsparc|solintel)/bin:$OO_SDK_MAKE_HOME: $OO_SDK_ZIP_HOME: [$OO_SDK_CPP_HOME:] [$OO_SDK_JAVA_HOME/bin:] $OO_SDK_URE_BIN_DIR: $PATH</i></b><br>
353          <p>The PATH variable will be extended by the paths for the SDK development
354		  tools, the compiler, the JDK, GNU make, the zip tool and the
355		  OO_SDK_URE_BIN_DIR, where the compiler or the JDK are
356		  optional.</p>
357		  </td>
358		  </tr>
359          <tr>
360          <td colspan="2" class="cell80">When OO_SDK_URE_HOME is set, the script
361          additionally creates symbolic links to the public dynamic libraries of
362          the URE in <i>$OO_SDK_HOME/(solsparc|solintel)/lib</i>, which are
363          needed for linking.</td>
364          </tr>
365		  </table>
366		  <p class="head4">Linux</p>
367		  <table class="table4">
368		  <tr valign="top">
369		  <td class="cell20">LD_LIBRARY_PATH</td>
370		  <td class="cell80">=<i>$OO_SDK_URE_LIB_DIR: $SDK_HOME/linux/lib: $LD_LIBRARY_PATH</i><br>
371		  <p>The LD_LIBRARY_PATH will be set or will be extended by the office/URE
372		  library path, the platform dependent lib directory for some additional
373		  libraries.</p>
374		  </td>
375		  </tr>
376		  <tr valign="top">
377		  <td class="cell20">PATH</td>
378		  <td class="cell80">=<i>$OO_SDK_HOME/linux/bin:$OO_SDK_MAKE_HOME: $OO_SDK_ZIP_HOME: [$OO_SDK_CPP_HOME:] [$OO_SDK_JAVA_HOME/bin:] $OO_SDK_URE_BIN_DIR: $PATH</i><br>
379		  <p>The PATH variable will be extended by the paths for the SDK development
380		  tools, the compiler, the JDK, GNU make, the zip tool and the
381		  OO_SDK_URE_BIN_DIR, where the compiler and the JDK are
382		  optional.</p>
383		  </td>
384		  </tr>
385          <tr>
386          <td colspan="2" class="cell80">When OO_SDK_URE_HOME is set, the script
387          additionally creates symbolic links to the public dynamic libraries of
388          the URE in <i>$OO_SDK_HOME/linux/lib</i>, which are needed for
389          linking.</td>
390          </tr>
391		  </table>
392		  <p class="head3">Environment Variables for Windows</p>
393		  <table class="table4">
394		  <tr valign="top">
395		  <td class="cell20">PATH</td>
396		  <td class="cell80">=<i>%OO_SDK_HOME%\windows\bin; %OO_SDK_MAKE_HOME%; %OO_SDK_ZIP_HOME%; [%OO_SDK_CLI_HOME%;] [%OO_SDK_CPP_HOME%;] [%OO_SDK_JAVA_HOME%\bin;] %OO_SDK_URE_BIN_DIR%; %PATH%</i><br>
397		  <p>The PATH variable will be extended by the paths for the SDK development
398		  tools, the compiler, the JDK, GNU make, the zip tool and the
399		  OO_SDK_URE_BIN_DIR.</p>
400		  </td>
401		  </tr>
402		  <tr valign="top">
403		  <td class="cell20">LIB</td>
404		  <td class="cell80">=<i>%OO_SDK_HOME%\windows\lib; %LIB%</i><br>
405		  <p>The LIB variable will be extended by the path to the import libraries
406		  that are necessary for Windows.</p>
407		  </td>
408		  </tr>
409		  <tr valign="top">
410		  <td colspan="2" class="cell80">In addition to setting these environment
411		  variables, the script calls the &quot;<i>vcvar32.bat</i>&quot; batch file
412		  which is provided by the Microsoft Developer Studio to set the necessary
413		  environment variables for the compiler.</td>
414		  </tr>
415		  </table>
416		  </td>
417		  </tr>
418		  </table>
419          </td>
420		</tr>
421	  </table>
422	</td>
423  </tr>
424  <tr>
425    <td colspan="3"><img class="nothing30" src="images/nada.gif"></td>
426  </tr>
427  <tr>
428    <td colspan="3"><img class="line" src="images/sdk_line-1.gif"></td>
429  </tr>
430  <tr>
431    <td colspan="3">
432      <div class="centertext">
433	<p><img class="apachelogo" src="images/odk-footer-logo.gif" title="Apache Feather" alt="Apache Feather" />
434            Copyright &copy; 2011 The Apache Software Foundation, Licensed under the Apache License, Version 2.0. Apache, the Apache feather logo, Apache OpenOffice and OpenOfifce.org are trademarks of The Apache Software Foundation. Other names may be trademarks of their respective owners.<p>
435      </div>
436    </td>
437  </tr>
438</table>
439<map name="Map">
440  <area shape="rect" coords="10,68,400,105" href="http://www.openoffice.org">
441</map>
442</body>
443</html>
444