#1 modify build.xml to allow building on linux


Paths for basis and URE are different on linux - thus build.xml needs to be adapted in order to be able to build on linux.

Attached patch accounts for that. Alternatively, you could hardcode
/op/openoffice.org/ure/share/ava and

(* since the basis directory is versioned, but as the typical user only has one version of OOo installed...)

Although then you'd still need the application home dir for the uno-deploy target (or you hardcode /opt/openoffice.org3 for that)


  • patch to account for paths on linux

  • Holger Brandl
    Holger Brandl

    I've already built on linux (Ubuntu) and it worked fine.

    probably there's no way around providing different deployment ant-tasks for the different platforms. OOo does not seem to follow a standardized scheme here. But maybe just I didn't got the idea yet...


  • Not sure whether I got you right. If you mean you already built on linux without any patch, without modifying build.xml, then my counter-question is: When was that? Surely not with three-layer office...

    Even distro versions of OOo surely don't have a Basis/program directory (no uppercase B, and the generic one (the link to the versioned one) is always basis-link.

    Also regarding the deployment - Again I'm not sure whether you mean what usually is meant with deploy, or what is done by the deploy target in OpenCards.

    Yes, without having different path property values for the different platforms, building without modifying build.xml won't work. However both distro versions as well as distributor's version (well, at least Mandrivas version of go-oo builds) will work with the attached patch out-of-the-box, both for "deploy" target, as well as for actually deploying the extension (uno-deploy target).

    Vanilla paths on linux are:
    OOo-home is /opt/openoffice.org3/ in that directory, there's (amongst others)
    basis-link (a symlink pointing to ../openoffice.org/basis3.2
    program (where soffice, simpress, ... launchers as well as unopkg reside)

    And then there's the /opt/openoffice.org directory, that is the real home of URE and basis so /opt/openoffice.org only contains basis3.2 and ure subdirectories.

    Now for go-oo based tree. They have /usr/lib/ooo and within there, you also have basis-link, pointing to the versioned basis3.x directory in the same directory, you got program, with soffice, simpress,... unopkg, and you got ure directory.
    and you got basis-link/ure-link as well. Hooray :-)

    So thinking again about it, you don't need the tricks in the patch for the ure dir, since there is also a /opt/openoffice.org3/basis-link/ure-link pointing to ../ure (i.e. /op/openoffice.org/ure) and with that you avoid the ../ in the path that is evaluated by ant itself, and thus get to the real path. This simplifies the patch quite a bit. And there won't be a dependency on vanilla OOo. Updated patch to follow.

    With the patch it will work with both vanilla OOo installed
    ant -Doffice.home=/opt/openoffice.org3
    as well as with the go-oo/distro version (given that you installed java-bits of OOo)
    ant -Doffice.home=/usr/lib/ooo

  • use basis-link/ure-link instead of relying on vanilla directory layout