Difference between revisions of "Documentation/Building Guide AOO/Step by step"

From Apache OpenOffice Wiki
< Documentation‎ | Building Guide AOORedirect page
Jump to: navigation, search
(Windows 7, Windows 8.1, Windows 10: indicate more clearly further lynx and apt-cyg installations as secondary compared to the cygwin interface)
(Substitute contents with redirect to the section of the building guide)
 
(160 intermediate revisions by 12 users not shown)
Line 1: Line 1:
{{DISPLAYTITLE:Step by step building guides for different platforms}}
+
#REDIRECT [[Documentation/Building Guide AOO#Step-by-Step Building Guide for Different Platforms]]
 
+
__TOC__
+
 
+
This page is intended as a collection of simple step-by-step recipes to build Apache OpenOffice from source code.  A more thorough explanation of what the individual steps do and why they are necessary can be found in the [[Documentation/Building_Guide_AOO|building guide]].
+
 
+
=Ubuntu 14.04=
+
 
+
The basic building steps under Ubuntu 12.04 (see below) are to be followed in Ubuntu 14.04 as well; however, there are some minor build issues that any developer, using this OS, needs to be aware of, if he gets stuck while building. The following is the list of issues, with their fixes, that a developer may face with:
+
 
+
* Issue 124712 (build broken in svl); see the link https://issues.apache.org/ooo/show_bug.cgi?id=124712 for detailed information.
+
If you are building trunk, the patch is already applied; if you are building from a release tag or tarball, the patch needs to be applied for all releases <= 4.1.1.
+
 
+
* Issue 125475; see the link https://issues.apache.org/ooo/show_bug.cgi?id=125475 for detailed information. This happens if you explicitly upgraded your GCC and related tools to version 4.9; it will not appear if you use GCC 4.8.x.
+
 
+
As the BZ says, it is because of buggy toolchain g++4.9. So for now in Ubuntu Linux 14.04, build the source using g++4.8.2, gcc4.8.2; these are the default compilers in Ubuntu Linux 14.04 anyway; please check it using the following commands:
+
 
+
  g++ -v
+
  gcc -v
+
 
+
if not, you've to download them.
+
 
+
  sudo apt-get install g++-4.8
+
  cd /usr/bin
+
  rm gcc
+
  rm g++
+
  ln -s gcc-4.8 gcc
+
  ln -s g++-4.8 g++
+
 
+
* Failed to find ./solver/420/unxlngx6.pro/lib/x86_64-linux-gnu/libstdc++.so.6.0.20 error.
+
 
+
  cp /usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.20 ./solver/420/unxlngx6.pro/lib/
+
  rm ./solver/420/unxlngx6.pro/lib/libstdc++.so.6
+
  ln -s ./solver/420/unxlngx6.pro/lib/libstdc++.so.6.0.20 ./solver/420/unxlngx6.pro/lib/libstdc++.so.6
+
 
+
* No such file or directory - connectivity/virtualdbtools.hxx while building svx.
+
 
+
if you get an error like this, then that means connectivity is not built properly. Build connectivity using build --all:connectivity and this error will go away.
+
 
+
=Ubuntu 12.04=
+
 
+
* Setup VirtualBox with Ubuntu 12.04 64 bit on Windows7 64bit host.  A native installation is of course fine, too.
+
* Let updater update ca. 380 packages. Restart.
+
* Get the source.  You can start with the source release or by checking out from SVN:
+
 
+
{| class="prettytable"
+
|-
+
! Source release
+
! SVN
+
|- valign="top"
+
| Build from source release if you want to build OpenOffice once but don't want to do any development.
+
| Build from SVN if you want to development work with OpenOffice.
+
|- valign="top"
+
|
+
 
+
* Download AOO 4.1.1 source tarball from
+
http://people.apache.org/~jsc/developer-snapshots/r1372282/src/aoo-4.1.1-incubating-src.tar.bz2
+
 
+
* Optional: Download signature from
+
http://people.apache.org/~jsc/developer-snapshots/r1372282/src/aoo-4.1.1-incubating-src.tar.bz2.asc
+
 
+
and verify the source tarball with
+
 
+
gpg --verify aoo-4.1.1-incubating-src.tar.bz2.asc \
+
              aoo-4.1.1-incubating-src.tar.bz2
+
 
+
Note that you have to have the keys already imported to your key chain. The keys can be found on the download page:
+
 
+
http://www.apache.org/dist/incubator/ooo/KEYS
+
 
+
* Unpack source:
+
  cd /tmp
+
  tar -xjf ~/Downloads/aoo-4.1.1-incubating-src.tar.bz2
+
  cd aoo-4.1.1/main
+
 
+
|
+
 
+
* Start with creating a parent directory for the source code.  Don't use <code>/tmp</code> because that is deleted on every boot:
+
 
+
  sudo mkdir /source
+
  sudo chown <your-user-name> /source
+
  cd /source
+
 
+
* Install subversion and checkout the source:
+
 
+
  sudo apt-get install subversion
+
  svn co https://svn.apache.org/repos/asf/openoffice/trunk aoo-trunk
+
  cd aoo-trunk/main
+
 
+
|}
+
 
+
* Install requirements (this will also install packages that are not listed):
+
 
+
  sudo apt-get install g++ gcc bison flex libarchive-zip-perl libcups2-dev \
+
      libpam0g-dev gperf libfreetype6-dev libxaw7-dev libfontconfig1-dev \
+
      libxrandr-dev patch libgconf2-dev libgnomevfs2-dev ant libgtk2.0-dev \
+
      junit junit4 libidl-dev liborbit2-dev openjdk-6-jdk libwww-perl \
+
      libxml-parser-perl autoconf libssl-dev
+
 
+
* Run autoconf to generate configure script:
+
 
+
  autoconf
+
 
+
* Configure (see the building guide section on [[Documentation/Building_Guide_AOO#Configuration_and_bootstrapping|configuration]] for further options):
+
 
+
  ./configure \
+
      --with-dmake-url=http://sourceforge.net/projects/oooextras.mirror/files/dmake-4.12.tar.bz2 \
+
      --with-epm-url=https://sourceforge.net/projects/oooextras.mirror/files/epm-3.7.tar.gz \
+
      --disable-odk \
+
      --disable-binfilter
+
 
+
* Finish configuration and download missing tarballs and extensions:
+
 
+
  ./bootstrap
+
 
+
* Include the configured environment:
+
 
+
  source LinuxX86-64Env.Set.sh
+
 
+
* Build:
+
 
+
  cd instsetoo_native/
+
  build --all
+
 
+
This may take a while to complete.  Several hours are not uncommon.  To speed things up you may want to run 'build' like this
+
 
+
  build --all -P<n> -- -P<n>
+
 
+
to start a parallel build.  Replace <n> with the number of CPU cores.
+
 
+
* Install:
+
 
+
  sudo dpkg -i unxlngx6.pro/Apache_OpenOffice/deb/install/en-US/DEBS/*.deb
+
  sudo dpkg -i unxlngx6.pro/Apache_OpenOffice/deb/install/en-US/DEBS/desktop-integration/openoffice4.2-debian-menus_4.2-9800_all.deb
+
 
+
* Start Apache OpenOffice:
+
 
+
  /opt/openoffice4/program/soffice
+
 
+
=CentOS 5=
+
 
+
CentOS 5 is our reference environment for build through the 4.1.x series. As it is a very old environment, it is '''not''' recommended to use it for your first build. But is important to document how to build on CentOS 5 since this is where the release through 4.1.x are built.
+
 
+
* Setup a VM (KVM given here as example):
+
 
+
  $ wget -O /tmp/CentOS-5.iso http://mi.mirror.garr.it/mirrors/CentOS/5.11/isos/x86_64/CentOS-5.11-x86_64-netinstall.iso
+
  $ fallocate -l 20480M /vms/centos5_64.img
+
  $ sudo virt-install --boot cdrom --name centos5_64 --memory 8192 -f /vms/centos5_64.img --cdrom /tmp/CentOS-5.iso
+
 
+
* Install the system; installation will start with the above command and use the following values when asked:
+
** Installation method: HTTP with website mirror.centos.org and CentOS directory /centos/5/os/x86_64
+
** Partitioning: one 20000M for /, rest swap
+
** Setup Base system only
+
* Reboot the VM and configure it
+
** You'll probably want a non-root user with sudo access and you may want to disable some services.
+
* Install dependencies from CentOS repository
+
 
+
  $ sudo yum install subversion autoconf tcsh perl-Archive-Zip gcc gcc-c++ cups-devel pam-devel java-1.7.0-openjdk-devel gperf freetype-devel gtk2-devel libIDL-devel libXaw-devel bison patch GConf2-devel gnome-vfs2-devel ant make tar rpm-build flex perl-XML-Parser ORBit2-devel
+
 
+
* Install and configure ccache:
+
 
+
  $ sudo yum install ccache
+
  $ ccache -M 2G
+
 
+
* This leaves out four packages ('''to be handled later'''):
+
** junit4
+
** perl-LWP-UserAgent-Determined
+
** perl-Digest-SHA → This one is available on EPEL (<code>sudo yum install epel-release && sudo yum install perl-Digest-SHA</code>) but it is not worth to do that for a single module, as other modules must be fixed anyway
+
** perl-LWP-Protocol-https
+
* You can still configure with
+
 
+
  $ ./configure --enable-category-b --with-dmake-url=http://sourceforge.net/projects/oooextras.mirror/files/dmake-4.12.tar.bz2 --with-epm-url=https://sourceforge.net/projects/oooextras.mirror/files/epm-3.7.tar.gz --enable-bundled-dictionaries --with lang="en it" --without-stlport --with-package-format="installed rpm" --without-junit
+
 
+
* Bootstrap will fail
+
** Error: Can't locate object method "show_progress" via package "LWP::UserAgent" at .../main/solenv/bin/modules/ExtensionsLst.pm line 484.
+
** Solution in http://markmail.org/message/mnqv3ncast7754zw does not work: Can't locate object method "upgrade" via package
+
** Discussion at https://s.apache.org/6pWq is promising but incomplete
+
* Once one works around bootstrap (for example, using a local package cache) build succeeds.
+
 
+
= Fedora 21 =
+
 
+
'''soon to come'''
+
 
+
= Fedora 19 and 20 =
+
 
+
== Build Instructions ==
+
 
+
The [[Building|build procedure]] is the same as for other Linux systems.
+
 
+
Required packages:
+
 
+
$ yum install tcsh perl-Archive-Zip gcc gcc-c++ cups-devel \
+
              pam-devel java-1.7.0-openjdk-devel gperf freetype-devel \
+
              gtk2-devel libIDL-devel libXaw-devel bison patch GConf2-devel \
+
              gnome-vfs2-devel ant make tar rpm-build flex junit4 \
+
              perl-LWP-UserAgent-Determined perl-XML-Parser \
+
              perl-Digest-SHA ORBit2-devel perl-LWP-Protocol-https
+
 
+
Build notes:
+
 
+
* The perl-Digest-SHA dependency is not caught until bootstrap
+
* The ORBit2-devel dependency is not caught until building the "shell" module
+
* Build breaks in "hsqldb": to build with Java7, you need to apply the patch at https://issues.apache.org/ooo/attachment.cgi?id=80961&action=diff
+
* Build breaks in "moz": configure with --disable-mozilla to work around it.
+
 
+
= Fedora 10 and 14 =
+
 
+
== Build Instructions ==
+
 
+
The [[Building|build procedure]] is the same as for other Linux systems.
+
 
+
Required packages:
+
 
+
$ yum install tcsh perl-Archive-Zip gcc gcc-c++ cups-devel \
+
              pam-devel java-1.6.0-openjdk-devel gperf freetype-devel \
+
              gtk2-devel libIDL-devel libXaw-devel bison patch GConf2-devel \
+
              gnome-vfs2-devel ant make
+
 
+
== Quick start guide ==
+
 
+
<font color="red">Still valid?</font>
+
 
+
$ yum -y install mono-devel perl-Archive-Zip ant bison \
+
        flex pam-devel cups-devel gperf libxslt-devel openldap-devel \
+
        firefox-devel xorg-x11-devel gstreamer-devel \
+
        gstreamer-plugins-base-devel db4-devel unixODBC-devel \
+
        xml-commons-jaxp-1.3-apis xalan-j2 boost-devel \
+
        unixODBC-devel qt-devel subversion autoconf automake \
+
        gtk2-devel gcc-c++  gnome-vfs2-devel rpm-build \
+
        expat-devel python-devel curl-devel
+
 
+
$ ./autogen.sh -with-distro=SUSE \
+
        --with-jdk-home=/usr/lib/jvm/java-1.5.0-gcj \
+
        --with-ant-home=/usr/share/ant \
+
        --with-system-mozilla=firefox \
+
        --disable-Xaw \
+
        --disable-kde \
+
        --disable-mono \
+
        --enable-opengl --enable-ogltrans \
+
        --disable-neon \
+
        --enable-debug
+
 
+
Another list:
+
* http://people.redhat.com/caolanm/ooocvs/makefc3chroot
+
 
+
Blog about building ooo-build on Fedora 7:
+
* http://openofficeorgfoo.blogspot.com/2007/12/building-ooo-build-from-source.html
+
 
+
== Fedora packaging ==
+
 
+
=== Fedora 14 ===
+
 
+
The Fedora 14 spec file can be found at http://koji.fedoraproject.org/koji/buildinfo?buildID=276232 (download the srpm, and uncompress it (rpm2cpio <file> | cpio -idv) ); you'll see the single spec file openoffice.org.spec ; note that it doesn't build cleanly, you need to apply the patch from https://issues.apache.org/ooo/show_bug.cgi?id=114999
+
 
+
=== Fedora 19 ===
+
 
+
* HSQLDB does not build with Java 7: see https://issues.apache.org/ooo/show_bug.cgi?id=121754 for the relevant patches.
+
* Spec files for dmake and epm by Fred Ollinger are at https://github.com/fredollinger/aooo-fedora-rawhide
+
* A note from Ariel about dictionaries: http://mail-archives.apache.org/mod_mbox/openoffice-dev/201303.mbox/%3C20130329145345.GC2969%40localhost%3E
+
 
+
= Windows 7, Windows 8.1, Windows 10 =
+
 
+
'''Complete requirements found at [http://wiki.openoffice.org/wiki/Documentation/Building_Guide_AOO#General_Build_Requirements General Build Requirements] and [http://wiki.openoffice.org/wiki/Documentation/Building_Guide_AOO/Building_on_Windows Building on Windows].'''
+
 
+
This is a '''sample''' step-by-step guide - check the complete requirements and report on dev@openoffice.apache.org, if problems with this step-by-step guide occurs.
+
 
+
*Install cygwin, '''32bit version'''
+
**Browse to [http://www.cygwin.com http://www.cygwin.com] and click on the setup-x86.exe link to download the most recent 32 bit version (the most recent Cygwin DLL at the moment is 2.6.0) or use [https://www.cygwin.com/setup-x86.exe this direct link]
+
**Run the installer and click through the questions
+
**On the "Choose A Download Site" select a nearby download server
+
**Expect a "Setup Alert" dialog box on the first cygwin install on the computer: click OK to close it
+
**On the page that allows you to select additional packages select: <br /><br /> From the '''Archive''' category: <pre>zip, unzip</pre> From the '''Devel''' category: <pre>gperf, gcc-g++, bison, flex, patch, subversion, make</pre> From the '''Net''' category: <pre>rsync</pre>From the '''Perl''' category: <pre>perl, perl-XML-SAX-Expat, perl-Archive-Zip, perl-LWP-Protocol-https, perl-XML-parser, perl-libwww-perl, perl-Digest-SHA, perl-Net-SSLeay</pre>If you will use git, you need in addition from the '''Devel''' category the packages:<pre>git, git-svn</pre><i>(If you prefer to install packages with a linux kind of touch, you can skip selecting the packages and instead select just the package <b>lynx</b> (enter lynx in the Search box and select the lynx entry in the Web/Default section). You would then install the other packages from the cygwin command line using lynx as explained ahead. However, selecting the packages from the cygwin interface is recommended.)</i>
+
**Click Next to finish package selection.
+
**Click Next to resolve dependencies.
+
**After installation is finished click the Finish button to close the dialog.
+
 
+
*Start cygwin bash in a terminal
+
 
+
::In Windows 7 and later you can just type "cygwin" into the Start Menu search bar and then click on the cygwin App. Or you can:
+
::*Press WindowsKey-R
+
::*Type "C:\cygwin\Cygwin.bat" (if that's the path you installed cygwin to)
+
::*Hit Return.
+
:::<i>(If you haven't installed the necessary packages from the cygwin interface yet because you would prefer to install them using lynx from the cygwin command line, then you should do so now. First install <b>apt-cyg</b> from the Github repository:)<pre>cd /cygdrive/c/temp</pre>(or any other temporary directory of your choice)<pre>lynx -source rawgit.com/transcode-open/apt-cyg/master/apt-cyg > apt-cyg&#10;chmod +x apt-cyg&#10;mv apt-cyg /usr/local/bin/</pre>Use <b>apt-cyg</b> to install missing cygwin packages:<pre>apt-cyg install perl zip unzip gperf autoconf rsync gcc-g++ bison flex patch subversion make</pre>(You must also provide to install the missing perl packages, for example with "cpan -i LWP::Protocol" etc. however there can be some dependency conflicts, the recommended method is installing the packages from the cygwin interface)</i>
+
 
+
* Replace symlinked awk with copy of gawk.exe:<pre>rm /usr/bin/awk&#10;mv /usr/bin/gawk.exe /usr/bin/awk.exe</pre>Note that if the <code>rm</code> command fails then the <code>mv</code> is not necessary.
+
 
+
* Install Java, '''32bit version'''
+
::Choose between JDK or OpenJDK. Versions 1.7 and 1.8 are known to work.
+
::(We need the 32 bit version because JNI requires the JVM's bitness to match the C/C++ bitness).
+
 
+
* Install Ant
+
**Browse to http://ant.apache.org/bindownload.cgi
+
**Chose a mirror near you.
+
**Download the zip archive (currently that is apache-ant-1.8.4-bin.zip).
+
**Open downloaded archive in file explorer and unzip it to a location of your choice, eg <code>c:\</code>.  Note that <code>C:\Program Files (x86)</code> will not work due to problems of quoting the spaces and parentheses.
+
   
+
* Install Microsoft Windows SDK for Windows 7 and .NET Framework 3.5. SP1 (recommended by Microsoft. Note: later versions of the Windows SDK will not work. AOO can not be built with MSVC 2010 or 2012 - MSVC 2008 is needed and is found in the Windows 7 SDK)
+
** Browse to http://www.microsoft.com/en-us/download/details.aspx?id=3138.
+
** Download winsdk_web.exe and run the web installer.  You can use the default values in the installation dialog, except when prompted with the installation path use a path that has no spaces or parentheses (e.g. "C:\Microsoft_SDKs\Windows\v7.0"), because otherwise the build process will choke on those spaces or parentheses.
+
** Alternatively download the iso image http://www.microsoft.com/en-us/download/details.aspx?id=18950. Burn it to a dvd or unzip it.
+
 
+
* Download MS Visual C++ 2008 SP1 Redistributable Package (x86)
+
** http://www.microsoft.com/en-us/download/details.aspx?id=26368 ( There have been security updates, which are not included in older versions.)
+
**Download files vcredist_x86.exe and vcredist_x64.exe<br />  If you download the most actual version of Apache OpenOffice and unpack it, you will find the files vcredist_x86.exe and vcredist_x64.exe in folder redist. You can use them as well.
+
 
+
* Optional: Install DirectX SDK (for graphics hardware support in the slide show)
+
** Browse to http://www.microsoft.com/en-us/download/details.aspx?displaylang=en&id=6812
+
** Download and run DXSDK_Jun10.exe. Choose to install to a custom path, and use a path that has neither spaces nor parentheses (e.g. <code>C:\Microsoft_DirectX_SDK_June_2010</code>), because otherwise the build will not be able to parse the path and will choke on the spaces or parentheses. <i>(If you receive an S1023 error towards the end of the installation, [https://support.microsoft.com/it-it/kb/2728613 the fix is simple]. The issue occurs because a newer version of the Visual C++ 2010 Redistributable is present on the computer. The June 2010 DirectX SDK installs version 10.0.30319 of the Visual C++ Redistributable. To resolve this issue, you must uninstall all versions of the Visual C++ 2010 Redistributable before installing the June 2010 DirectX SDK. You may have one or more of the following products installed: Visual C++ 2010 Redistributable x86, Visual C++ 2010 Redistributable x64.  You can use Add or Remove Programs in Control Panel to uninstall the products. Or, you can run the following commands from an administrator command prompt: <pre>MsiExec.exe /passive /X{F0C3E5D1-1ADE-321E-8167-68EF0DE699A5} &#10;MsiExec.exe /passive /X{1D8E6291-B0D5-35EC-8441-6616F567A0F7}</pre> and then run the DirectX SDK installer. After installing the June 2010 DirectX SDK, you may then reinstall the most current version of the [http://www.microsoft.com/download/details.aspx?id=26999 Visual C++ 2010 Redistributable Package].)</i>
+
 
+
* Optional: Install Windows Driver Kit 7.1.0 (for enabling activex)
+
** Download [http://www.microsoft.com/en-us/download/details.aspx?id=11800 WDK 7.1.0] (is an ISO image). Cannot use later versions of Windows Driver Kit because they do not have ATL which is needed to build AOO with ActiveX. (I recommend to download using Internet Explorer, otherwise the install may fail a Windows Authenticity test, whereas this does not happen using Internet Explorer to download the ISO image.)
+
** Mount the ISO image and install.
+
 
+
* Optional: Install NSIS installer (for creating the EXE installer)
+
** Browse to http://nsis.sourceforge.net
+
** Download and run the installer. Recommended to install to custom location, choose a path without any spaces (e.g. "C:\NSIS").
+
 
+
* Get AOO source code. You can use the source release or check out from SVN. Build from source release if you want to build OpenOffice once but don't want to contribute patches. If you will contribute patches, you need to generate them against an actual version of trunk. In this case check out from SVN to be able to rebase before generating patches. You can work with subversion or with git-svn. Do not use a tool that changes line endings, such as the default configuration of TortoiseSVN.
+
 
+
::; Source release:
+
::* Browse to http://www.openoffice.org/download/other.html#tested-sdk and locate the table row that starts with "Source code"
+
::* Download source code in an archive format of your choice (note that tar.bz2 is typically smaller than tar.gz and zip)
+
::* Optional: Verify the archive - following given link or instructions.
+
::* Unpack source (in cygwin-terminal). Use the file name exactly as downloaded.<pre>cd /tmp&#10;tar -xjf <download-location>/<downloaded-source-release.tar.bz2>&#10;cd <unpacked-source>/main&#10;</pre>Do not use Windows unpacker, they might cause access right problems.
+
 
+
::; Checkout from SVN using subversion :
+
::*<i>(If you haven't installed the subversion package from the cygwin interface, please do so now by re-running the cygwin installer, or if you used lynx and apt-cyg then:)<pre>apt-cyg install subversion</pre></i>
+
::*Start with creating a parent directory for the source code: <pre>mkdir /cygdrive/c/source&#10;cd /cygdrive/c/source</pre>
+
::*Check out source from Apache SVN repository<pre>svn co https://svn.apache.org/repos/asf/openoffice/trunk aoo-trunk&#10;cd aoo-trunk/main</pre>
+
 
+
::; Checkout from SVN using git-svn :
+
::*<i>(If you haven't installed git and git-svn from the cygwin interface, please do so now by re-running the cygwin installer, or if you used lynx and apt-cyg then:)<pre>apt-cyg install git git-svn</pre></i>
+
::*Get the actual revision number from http://svn.apache.org/viewvc/OpenOffice/trunk/, e.g. 1234567
+
::*Create an empty directory and change to it, e.g.<pre>mkdir /cygdrive/c/source&#10;cd /cygdrive/c/source</pre>
+
::*Check out source from Apache SVN repository<pre>git svn clone --revision 1234567:HEAD https://svn.apache.org/repos/asf/openoffice/trunk&#10;cd trunk/main</pre>
+
 
+
* Remember the source path (this is optional, it makes for an easy reference):<pre>SourceMain=`pwd`</pre> [Why? I have not used it. [[User:Regina|Regina]] ([[User talk:Regina|talk]]) 21:42, 24 February 2013 (UTC)]
+
:[Added explanation above [[User:Andre|Andre]]]
+
 
+
* Optional: Get dbghelp.dll (for using the <code>--enable-dbgutil</code> configure option)
+
** This dll is part of MS Visual Studio. If you do not have it installed, download and install "Visual Studio Community" from https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx
+
** Copy file to <code>main/external/dbghelp</code>. Use Windows file manager or in cygwin terminal<pre>cp /cygdrive/c/Program\ Files\ \(x86\)/Microsoft\ Visual\ Studio\ 9.0/Common7/IDE/dbghelp.dll $SourceMain/external/dbghelp</pre>
+
 
+
* Copy vcredist_x86.exe and vcredist_x64.exe (see above) to main/external/vcredist.
+
** Use Windows file manager or in cygwin terminal<pre>cp <download-location>/vcredist_x86.exe $SourceMain/external/vcredist&#10;cp <download-location>/vcredist_x64.exe $SourceMain/external/vcredist</pre>
+
 
+
* Get GDI+ redistributable.
+
**Browse to http://www.microsoft.com/en-us/download/details.aspx?id=18909
+
**Download WindowsXP-KB975337-x86-ENU.exe
+
**Run WindowsXP-KB975337-x86-ENU.exe
+
**Enter a temporary path (eg c:\temp\gdiplus) in the dialog and click OK to extract files
+
**Copy gdiplus.dll to main/external<pre>cp /cygdrive/c/temp/gdiplus/asms/10/msft/windows/gdiplus/gdiplus.dll $SourceMain/external/gdiplus/</pre>
+
** Remove the temporary path<pre>rm -fr /cygdrive/c/temp/gdiplus</pre>
+
 
+
* Get msvcr100.dll:<pre>cp /cygdrive/c/Windows/System32/msvcr100.dll $SourceMain/external/msvcp100</pre>[I don't believe this is necessary? Looking through the configuration stage output I see it is done automatically: <pre> Copying /cygdrive/C/Program Files (x86)/Microsoft Visual Studio 9.0/VC/redist/x86/Microsoft.VC90.CRT/msvcp90.dll to ./external/msvcp90 &#10; Copying /cygdrive/C/Program Files (x86)/Microsoft Visual Studio 9.0/VC/redist/x86/Microsoft.VC90.CRT/msvcr90.dll to ./external/msvcp90 &#10; Copying /cygdrive/C/Program Files (x86)/Microsoft Visual Studio 9.0/VC/redist/x86/Microsoft.VC90.CRT/msvcm90.dll to ./external/msvcp90 &#10; Copying /cygdrive/C/Program Files (x86)/Microsoft Visual Studio 9.0/VC/redist/x86/Microsoft.VC90.CRT/Microsoft.VC90.CRT.manifest to ./external/msvcp90</pre> --[[User:Johnrdorazio|Johnrdorazio]] ([[User talk:Johnrdorazio|talk]]) 19:54, 19 September 2016 (UTC)]
+
 
+
* Make sure that you are in the main source directory:<pre>cd $SourceMain</pre>
+
 
+
* Run autoconf to create the configure script:<pre>autoconf</pre>
+
 
+
* Make sure you have the correct Perl modules installed, if you haven't yet installed them from the cygwin setup: <pre>cpan -i Archive::Zip LWP::UserAgent LWP::Protocol</pre>
+
 
+
* Call configure
+
** Run configure (adapt paths as necessary)<pre>SDK_PATH="/cygdrive/c/Microsoft_SDKs/Windows/v7.0"&#10;./configure \&#10;    --with-frame-home="$SDK_PATH" \&#10;    --with-psdk-home="$SDK_PATH" \&#10;    --with-midl-path="$SDK_PATH/bin" \&#10;    --with-directx-home="C:/Microsoft_DirectX_SDK_June_2010" \&#10;    --with-ant-home="/cygdrive/c/apache-ant-1.8.4" \&#10;    --with-dmake-url="http://sourceforge.net/projects/oooextras.mirror/files/dmake-4.12.tar.bz2" \&#10;    --with-epm-url="https://sourceforge.net/projects/oooextras.mirror/files/epm-3.7.tar.gz" \&#10;    --disable-pch \&#10;    --disable-atl \&#10;    --disable-activex \&#10;    --without-junit</pre>If you have not installed the optional DirectX SDK then remove the <code>--with-directx-home switch</code>. Likewise if you have installed Windows Driver Kit 7.1.0 and would like to build with ATL and ActiveX functionality then remove the <code>--disable-activex</code> directive and add the atl home directives: <pre>    --with-atl-include-dir=/cygdrive/c/WinDDK/7600.16385.1/inc/atl71 \&#10;    --with-atl-lib-dir=/cygdrive/c/WinDDK/7600.16385.1/lib/ATL/i386 \&#10;    --with-mfc-include-dir=/cygdrive/c/WinDDK/7600.16385.1/inc/mfc42 \&#10;    --with-mfc-lib-dir=/cygdrive/c/WinDDK/7600.16385.1/lib/Mfc/i386</pre>If you have installed NSIS you can use the relative directive <pre>    --with-nsis-path="C:/NSIS"</pre>
+
*Finish configuration and download missing external source tarballs and extensions<pre>./bootstrap</pre>
+
* Include the configured environment<pre>source winenv.set.sh</pre>
+
* Build<pre>cd instsetoo_native/&#10;build --all</pre>Depending on your computer this will take one or more hours to finish. You may want to experiment with the -P options for multi process builds to reduce the build time. <pre>build --all -P<m> -- -P<n></pre> tells build to use <code>m</code> processes (build up to <code>m</code> modules in parallel) and <code>n</code> threads for each module.
+
 
+
 
+
* Install<br/>There are three options:
+
*# Regular install with integration into Windows.<br/>This allows only one instance of AOO to be installed.
+
*#* Start setup.exe and click through dialog:<br/><pre>$SourceMain/instsetoo_native/wntmsci12.pro/OpenOffice/msi/install/en-US/setup.exe</pre>
+
*#* Apache OpenOffice can be started via the Windows start menu.
+
*# Install without integration into Windows.<br/>This allows several instance of AOO, based on the same version, to be installed side by side.<br/>It still requires Administrator permissions.
+
*#* Start <code>setup.exe</code> with option <code>-a</code>:<br/><pre>$SourceMain/instsetoo_native/wntmsci12.pro/OpenOffice/msi/install/en-US/setup.exe -a</pre>
+
*#* Enter an installation path into the dialog and click through the dialog to finish installation.
+
*#* Start AOO by running<br/><pre><installation-path>/program/soffice.exe</pre>
+
*# Unpack archive without installation.<br/>This does not require Administrator permissions
+
*#* Go to installation directory:<br/><pre>cd <installation-target></pre>
+
*#* Unzip archive:<br/><pre>unzip $SourceMain/instsetoo_native/wntmsci12.pro/Apache_OpenOffice/msi/install/en-US/Apache_OpenOffice_4.0.1_Win_x86_install-arc_en-US.zip</pre>
+
*#* Start AOO by running:<br/><pre>./Apache_OpenOffice_4.0.1_Win_x86_install-arc_en-US/program/soffice.exe</pre>
+
::: (Change the version number in the file name to match the version you built)
+
 
+
=Mac OS X=
+
The build guide for [https://wiki.openoffice.org/wiki/Documentation/Building_Guide/Building_on_MacOSX Mac OS X] can be found on a separate page.
+
 
+
[[Category:Documentation]][[Category:Development]][[Category:Porting]]
+

Latest revision as of 21:21, 9 January 2021

Personal tools