2004-10-12 10:06:43 -05:00
|
|
|
:
|
|
|
|
eval 'exec perl -S $0 ${1+"$@"}'
|
|
|
|
if 0;
|
|
|
|
|
2011-01-10 15:01:36 -06:00
|
|
|
use strict;
|
|
|
|
|
2004-10-12 10:06:43 -05:00
|
|
|
#*************************************************************************
|
|
|
|
#
|
|
|
|
# This app makes it easy to link a live build
|
|
|
|
# set into an install set. Then your devel iteration
|
|
|
|
# is: 'build', execute.
|
|
|
|
#
|
|
|
|
#*************************************************************************
|
|
|
|
#
|
2008-04-10 10:50:09 -05:00
|
|
|
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
|
|
#
|
2010-02-12 08:01:35 -06:00
|
|
|
# Copyright 2000, 2010 Oracle and/or its affiliates.
|
2004-10-12 10:06:43 -05:00
|
|
|
#
|
2008-04-10 10:50:09 -05:00
|
|
|
# OpenOffice.org - a multi-platform office productivity suite
|
2004-10-12 10:06:43 -05:00
|
|
|
#
|
2008-04-10 10:50:09 -05:00
|
|
|
# This file is part of OpenOffice.org.
|
2004-10-12 10:06:43 -05:00
|
|
|
#
|
2008-04-10 10:50:09 -05:00
|
|
|
# OpenOffice.org is free software: you can redistribute it and/or modify
|
|
|
|
# it under the terms of the GNU Lesser General Public License version 3
|
|
|
|
# only, as published by the Free Software Foundation.
|
2004-10-12 10:06:43 -05:00
|
|
|
#
|
2008-04-10 10:50:09 -05:00
|
|
|
# OpenOffice.org 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 version 3 for more details
|
|
|
|
# (a copy is included in the LICENSE file that accompanied this code).
|
2004-10-12 10:06:43 -05:00
|
|
|
#
|
2008-04-10 10:50:09 -05:00
|
|
|
# You should have received a copy of the GNU Lesser General Public License
|
|
|
|
# version 3 along with OpenOffice.org. If not, see
|
|
|
|
# <http://www.openoffice.org/license.html>
|
|
|
|
# for a copy of the LGPLv3 License.
|
2004-10-12 10:06:43 -05:00
|
|
|
#
|
|
|
|
#*************************************************************************
|
|
|
|
|
2005-04-11 02:58:17 -05:00
|
|
|
# ends up in program/ooenv
|
2011-01-10 15:01:36 -06:00
|
|
|
( my $moz_lib = `pkg-config --variable=libdir mozilla-nss` ) =~ tr/\n/:/;
|
|
|
|
my $env_script = '
|
2010-10-15 08:47:19 -05:00
|
|
|
java_path=`../basis-link/ure-link/bin/javaldx 2>/dev/null`
|
2005-04-11 02:58:17 -05:00
|
|
|
export LD_LIBRARY_PATH=".:$java_path:' . $moz_lib . '$LD_LIBRARY_PATH"
|
2004-10-12 10:06:43 -05:00
|
|
|
ulimit -c unlimited
|
2010-08-24 07:40:58 -05:00
|
|
|
export PATH=".:../basis-link/program:../basis-link/ure-link/bin:$PATH"
|
2004-10-12 10:06:43 -05:00
|
|
|
export GNOME_DISABLE_CRASH_DIALOG=1
|
2010-08-24 07:40:58 -05:00
|
|
|
export STAR_RESOURCEPATH=`pwd`/../basis-link/program/resource
|
2006-01-19 09:16:16 -06:00
|
|
|
# debugging assistance
|
2010-10-08 10:41:31 -05:00
|
|
|
export G_SLICE=always-malloc
|
2006-01-19 09:16:16 -06:00
|
|
|
export MALLOC_CHECK_=2
|
|
|
|
export OOO_DISABLE_RECOVERY=1
|
2010-08-24 06:54:49 -05:00
|
|
|
export SAL_ALLOW_LINKOO_SYMLINKS=1
|
2004-10-12 10:06:43 -05:00
|
|
|
';
|
|
|
|
|
2011-01-10 15:01:36 -06:00
|
|
|
my $dry_run = 0;
|
|
|
|
my $usage = 0;
|
2010-08-24 07:40:58 -05:00
|
|
|
|
2011-01-10 15:01:36 -06:00
|
|
|
my $LANG;
|
|
|
|
my $TARGET;
|
|
|
|
my $LIBVER;
|
|
|
|
my $OOO_BUILD;
|
|
|
|
my $OOO_INSTALL;
|
|
|
|
|
|
|
|
my $program_dir = 'basis-link/program';
|
|
|
|
my $brand_program_dir = 'program';
|
|
|
|
my $ure_misc_dir = 'basis-link/ure-link/share/misc';
|
|
|
|
my $ure_java_dir = 'basis-link/ure-link/share/java';
|
|
|
|
my $ure_lib_dir = 'basis-link/ure-link/lib';
|
2010-08-24 07:40:58 -05:00
|
|
|
$program_dir = 'openoffice.org/basis-link/MacOS' if ($ENV{OS} eq 'MACOSX'); # FIXME probably wrong
|
2007-07-05 03:01:53 -05:00
|
|
|
|
2009-10-08 08:48:40 -05:00
|
|
|
my @exceptions = ( 'cppuhelper', 'sunjavaplugin', 'libjvmfwk' );
|
2004-10-12 10:06:43 -05:00
|
|
|
|
2011-01-10 15:01:36 -06:00
|
|
|
my %replaceable = (
|
2010-12-03 10:57:17 -06:00
|
|
|
$program_dir => '\.so',
|
2010-12-07 14:52:15 -06:00
|
|
|
$ure_lib_dir => '\.so',
|
|
|
|
$ure_java_dir => '\.jar$',
|
2007-07-05 03:01:53 -05:00
|
|
|
$program_dir . '/resource' => '\.res$',
|
|
|
|
$program_dir . '/classes' => '\.jar$',
|
2010-08-24 07:40:58 -05:00
|
|
|
'basis-link/share/config' => '\.zip$',
|
2004-10-12 10:06:43 -05:00
|
|
|
# 'share/uno_packages' => '\.zip$'
|
|
|
|
);
|
|
|
|
|
2007-05-10 07:21:51 -05:00
|
|
|
# strangely enough, OSX has those small differences...
|
2007-07-05 03:01:53 -05:00
|
|
|
$replaceable{$program_dir} = '\.dylib$' if ($ENV{OS} eq 'MACOSX');
|
2011-01-10 15:01:36 -06:00
|
|
|
$replaceable{$ure_lib_dir} = '\.dylib$' if ($ENV{OS} eq 'MACOSX');
|
2007-05-10 07:21:51 -05:00
|
|
|
|
2011-01-10 15:01:36 -06:00
|
|
|
my @search_dirs = ( 'lib', 'bin', 'class' );
|
2004-10-12 10:06:43 -05:00
|
|
|
|
2011-01-10 15:01:36 -06:00
|
|
|
my @known_duplicates = ( 'db.jar', 'libi18n' );
|
2004-10-12 10:06:43 -05:00
|
|
|
|
|
|
|
sub sniff_target($)
|
|
|
|
{
|
|
|
|
my $build_dir = shift;
|
|
|
|
my ($dirhandle, $fname);
|
2010-12-03 10:57:17 -06:00
|
|
|
my ($target, $libver, $lang) = ( 'unxlngi6.pro', '680', 'en-US' ); # defaults
|
|
|
|
|
2004-10-12 10:06:43 -05:00
|
|
|
opendir ($dirhandle, $build_dir) || die "Can't open $build_dir";
|
|
|
|
while ($fname = readdir ($dirhandle)) {
|
|
|
|
$fname =~ /Set.sh$/ || next;
|
2010-12-03 10:57:17 -06:00
|
|
|
|
2004-10-12 10:06:43 -05:00
|
|
|
my $file;
|
|
|
|
open ($file, "$build_dir/$fname") || die "Can't open $build_dir/$fname";
|
|
|
|
while (<$file>) {
|
|
|
|
/\s*(\S+)\s*=\s*\"(\S+)\"/ || next;
|
|
|
|
if ($1 eq 'INPATH') {
|
|
|
|
$target = $2;
|
|
|
|
}
|
|
|
|
if ($1 eq 'UPD') {
|
|
|
|
$libver = $2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
close ($file);
|
|
|
|
}
|
|
|
|
|
|
|
|
closedir ($dirhandle);
|
|
|
|
|
2006-03-08 06:59:14 -06:00
|
|
|
print "Sniffed target: $target, $libver\n";
|
2004-10-12 10:06:43 -05:00
|
|
|
|
2006-03-08 06:59:14 -06:00
|
|
|
return ($target, $libver, $lang);
|
2004-10-12 10:06:43 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
sub build_installed_list($)
|
|
|
|
{
|
|
|
|
my $path = shift;
|
|
|
|
my %files = ();
|
|
|
|
|
|
|
|
for my $suffix (keys %replaceable) {
|
|
|
|
my $dirname = "$path/$suffix";
|
|
|
|
my $dirhandle;
|
|
|
|
my $pattern = $replaceable{$suffix};
|
|
|
|
if (opendir ($dirhandle, $dirname)) {
|
|
|
|
while (my $fname = readdir ($dirhandle)) {
|
|
|
|
$fname =~ m/$pattern/ || next;
|
|
|
|
|
|
|
|
my $skip = 0;
|
|
|
|
for $pattern (@exceptions) {
|
|
|
|
$fname =~ /$pattern/ || next;
|
|
|
|
$skip = 1;
|
|
|
|
}
|
|
|
|
$files{$fname} = $dirname if !$skip;
|
|
|
|
}
|
|
|
|
closedir ($dirhandle);
|
|
|
|
} else {
|
|
|
|
print "Couldn't find '$dirname': skipping\n";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return \%files;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub check_create_linked($)
|
|
|
|
{
|
|
|
|
my $path = shift;
|
|
|
|
my $linked_dir = "$path/linked";
|
|
|
|
if (! -d $linked_dir) {
|
|
|
|
mkdir $linked_dir || die "Can't make $linked_dir: $!";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2006-01-19 09:16:16 -06:00
|
|
|
sub do_link($$$$@)
|
2005-05-31 10:22:06 -05:00
|
|
|
{
|
|
|
|
my $src = shift;
|
|
|
|
my $dest = shift;
|
|
|
|
my $src_name = shift;
|
|
|
|
my $dest_name = shift;
|
2006-01-19 09:16:16 -06:00
|
|
|
my $dont_check_link = shift;
|
2005-05-31 10:22:06 -05:00
|
|
|
|
2007-01-30 01:23:55 -06:00
|
|
|
if (-l "$dest/$dest_name" ) {
|
2005-05-31 10:22:06 -05:00
|
|
|
my $link = readlink ("$dest/$dest_name");
|
|
|
|
if ($link =~ /^\//) { # Absolute path
|
|
|
|
if (!$dry_run) {
|
|
|
|
# re-write the link
|
|
|
|
unlink ("$dest/$dest_name");
|
|
|
|
symlink ("$src/$src_name", "$dest/$dest_name") || die "Failed to symlink: $!";
|
|
|
|
print " [$dest_name]";
|
|
|
|
} else {
|
|
|
|
print "re-make link $src/$src_name => $dest/$dest_name\n";
|
|
|
|
}
|
|
|
|
} elsif ($dry_run) {
|
|
|
|
print "skipping symbolic link $dest/$dest_name -> $link\n";
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
check_create_linked ($dest);
|
|
|
|
if (!$dry_run) {
|
|
|
|
# move / write the link
|
2006-01-19 09:16:16 -06:00
|
|
|
rename ("$dest/$dest_name", "$dest/linked/$dest_name") ||
|
|
|
|
defined $dont_check_link || die "Failed rename of $dest/$dest_name: $!";
|
2007-01-30 01:23:55 -06:00
|
|
|
|
2005-05-31 10:22:06 -05:00
|
|
|
symlink ("$src/$src_name", "$dest/$dest_name") || die "Failed to symlink: $!";
|
|
|
|
print " $dest_name";
|
|
|
|
} else {
|
|
|
|
print "move / symlink $src/$src_name => $dest/$dest_name\n";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2004-10-12 10:06:43 -05:00
|
|
|
|
2011-01-10 15:01:36 -06:00
|
|
|
sub scan_one_dir($$$$)
|
|
|
|
{
|
|
|
|
my ($installed_files, $build_files, $path, $solver) = @_;
|
|
|
|
|
|
|
|
for my $elem (@search_dirs) {
|
|
|
|
my $dirh_module;
|
|
|
|
my $module_path = "$path/$elem";
|
|
|
|
if (opendir ($dirh_module, $module_path)) {
|
|
|
|
while (my $file = readdir ($dirh_module)) {
|
|
|
|
if (defined $installed_files->{$file}) {
|
|
|
|
if (defined $build_files->{$file}) {
|
|
|
|
my $known = 0;
|
|
|
|
for my $regexp (@known_duplicates) {
|
|
|
|
if ($file =~ m/$regexp/) {
|
|
|
|
$known = 1;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (!$known && !$solver) {
|
2011-01-18 04:12:14 -06:00
|
|
|
print STDERR "\nlinkoo:: Unknown duplicate file '$file' in: '" .
|
2011-01-10 15:01:36 -06:00
|
|
|
$build_files->{$file} . "' vs '" .
|
|
|
|
$module_path . "' in module $path\n";
|
|
|
|
exit (1);
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
$build_files->{$file} = $module_path;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
closedir ($dirh_module);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2004-10-12 10:06:43 -05:00
|
|
|
sub scan_and_link_files($$$)
|
|
|
|
{
|
|
|
|
my $build_path = shift;
|
|
|
|
my $installed_files = shift;
|
|
|
|
my $target = shift;
|
2010-12-03 10:57:17 -06:00
|
|
|
|
2004-10-12 10:06:43 -05:00
|
|
|
my @modules = ();
|
|
|
|
my $dirh_toplevel;
|
|
|
|
opendir ($dirh_toplevel, $build_path) || die "Can't open '$build_path': $!";
|
|
|
|
while (my $subdir = readdir ($dirh_toplevel)) {
|
2005-05-31 10:22:06 -05:00
|
|
|
$subdir =~ m/\./ && next; # eg. vcl.old,
|
2004-10-12 10:06:43 -05:00
|
|
|
my $test = "$build_path/$subdir/$target";
|
2005-05-31 10:22:06 -05:00
|
|
|
-d $test || next;
|
|
|
|
push @modules, $test;
|
2004-10-12 10:06:43 -05:00
|
|
|
}
|
|
|
|
closedir ($dirh_toplevel);
|
|
|
|
|
2011-01-10 15:01:36 -06:00
|
|
|
# Scan the old-style module/$target/lib directories ...
|
2004-10-12 10:06:43 -05:00
|
|
|
my %build_files;
|
2011-01-10 15:01:36 -06:00
|
|
|
for my $module (@modules) {
|
|
|
|
scan_one_dir ($installed_files, \%build_files, $module, 0);
|
2004-10-12 10:06:43 -05:00
|
|
|
}
|
|
|
|
|
2011-01-10 15:01:36 -06:00
|
|
|
# Now scan the solver
|
|
|
|
my $upd = 330;
|
|
|
|
$upd = $ENV{UPD} if (defined $ENV{UPD});
|
|
|
|
scan_one_dir ($installed_files, \%build_files, "$build_path/solver/$upd/$target", 1);
|
|
|
|
|
2004-10-12 10:06:43 -05:00
|
|
|
for my $file (keys %build_files) {
|
|
|
|
my $src = $build_files{$file};
|
|
|
|
my $dest = $installed_files->{$file};
|
2010-12-03 10:57:17 -06:00
|
|
|
|
2005-05-31 10:22:06 -05:00
|
|
|
do_link ($src, $dest, $file, $file);
|
2004-10-12 10:06:43 -05:00
|
|
|
}
|
|
|
|
print "\n";
|
|
|
|
}
|
|
|
|
|
2005-04-11 02:58:17 -05:00
|
|
|
sub evilness($)
|
2005-02-11 08:23:57 -06:00
|
|
|
{
|
2005-04-11 02:58:17 -05:00
|
|
|
my $doit = shift;
|
2005-02-11 08:23:57 -06:00
|
|
|
my $name = 'librecentfile.so';
|
2005-04-11 02:58:17 -05:00
|
|
|
my $src = "$OOO_BUILD/shell/$TARGET/lib/$name";
|
|
|
|
my $dest = "$OOO_BUILD/sfx2/$TARGET/lib/$name";
|
|
|
|
|
|
|
|
if ($doit eq 'undo') {
|
|
|
|
if (-l $dest) {
|
|
|
|
print " unlink $name\n";
|
|
|
|
unlink $dest;
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
$doit eq 'do' || die;
|
|
|
|
if (-f $src) {
|
|
|
|
print " link $name\n";
|
|
|
|
symlink $src, $dest;
|
|
|
|
}
|
2005-02-11 08:23:57 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2005-05-31 10:22:06 -05:00
|
|
|
sub link_iso_res()
|
|
|
|
{
|
|
|
|
print "Special iso.res case: ";
|
2010-08-24 07:40:58 -05:00
|
|
|
my $ooo_res="$OOO_INSTALL/" . $brand_program_dir . "/resource/ooo".$LIBVER.$LANG.".res";
|
|
|
|
my $star_res="$OOO_INSTALL/" . $brand_program_dir . "/resource/iso".$LIBVER.$LANG.".res";
|
2005-05-31 10:22:06 -05:00
|
|
|
if (-l $ooo_res && -l $star_res) {
|
|
|
|
if ($dry_run) {
|
|
|
|
print "link $ooo_res to $star_res";
|
|
|
|
} else {
|
|
|
|
unlink ($star_res);
|
|
|
|
symlink ($ooo_res, $star_res);
|
|
|
|
print "clobbered";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
print "\n";
|
|
|
|
}
|
|
|
|
|
|
|
|
# Hack for (renamed) types.rdb (types.db)
|
2010-08-24 07:33:48 -05:00
|
|
|
sub link_oovbaapi_rdb()
|
|
|
|
{
|
|
|
|
print "oovbaapi.rdb case:";
|
|
|
|
my $src = "$OOO_BUILD/oovbaapi/$TARGET/ucr";
|
2010-08-24 07:40:58 -05:00
|
|
|
my $dest = "$OOO_INSTALL/" . $program_dir;
|
2010-08-24 07:33:48 -05:00
|
|
|
do_link ($src, $dest, 'oovbaapi.db', 'oovbaapi.rdb');
|
|
|
|
print "\n";
|
|
|
|
}
|
2010-12-03 10:57:17 -06:00
|
|
|
|
2005-05-31 10:22:06 -05:00
|
|
|
sub link_types_rdb()
|
|
|
|
{
|
|
|
|
print "Types.rdb case:";
|
|
|
|
my $src = "$OOO_BUILD/offapi/$TARGET/ucr";
|
2010-08-24 07:40:58 -05:00
|
|
|
my $dest = "$OOO_INSTALL/" . $ure_misc_dir;
|
2005-05-31 10:22:06 -05:00
|
|
|
do_link ($src, $dest, 'types.db', 'types.rdb');
|
|
|
|
print "\n";
|
|
|
|
}
|
|
|
|
|
2010-12-03 10:57:17 -06:00
|
|
|
sub link_pagein_files()
|
|
|
|
{
|
|
|
|
print "pagein case:";
|
|
|
|
my $src = "$OOO_BUILD/desktop/$TARGET/misc";
|
|
|
|
my $dest = "$OOO_INSTALL/" . $program_dir;
|
|
|
|
for my $c ('calc', 'draw', 'impress', 'writer', 'common') {
|
|
|
|
do_link ($src, $dest, "pagein-$c", "pagein-$c");
|
|
|
|
}
|
|
|
|
print "\n";
|
|
|
|
}
|
|
|
|
|
2011-01-10 15:01:36 -06:00
|
|
|
for my $a (@ARGV) {
|
2004-10-12 10:06:43 -05:00
|
|
|
|
2004-12-23 03:52:43 -06:00
|
|
|
# options
|
2011-01-10 15:01:36 -06:00
|
|
|
if ($a =~ /--dry-run/) {
|
2004-12-23 03:52:43 -06:00
|
|
|
$dry_run = 1;
|
|
|
|
} elsif (($a eq '--help') || ($a eq '-h')) {
|
|
|
|
$usage = 1;
|
2004-10-12 10:06:43 -05:00
|
|
|
|
2004-12-23 03:52:43 -06:00
|
|
|
# ordered arguments
|
|
|
|
} elsif (!defined $OOO_INSTALL) {
|
|
|
|
$OOO_INSTALL = $a;
|
|
|
|
} elsif (!defined $OOO_BUILD) {
|
|
|
|
$OOO_BUILD = $a;
|
|
|
|
} else {
|
|
|
|
print "Unknown argument '$a'\n";
|
|
|
|
$usage = 1;
|
|
|
|
}
|
|
|
|
}
|
2004-10-12 10:06:43 -05:00
|
|
|
|
2004-12-23 03:52:43 -06:00
|
|
|
if (!defined $OOO_BUILD && defined $ENV{SRC_ROOT}) {
|
|
|
|
$OOO_BUILD = $ENV{SRC_ROOT};
|
2004-10-12 10:06:43 -05:00
|
|
|
}
|
|
|
|
|
2004-12-23 03:52:43 -06:00
|
|
|
if ($usage || !defined $OOO_INSTALL || !defined $OOO_BUILD) {
|
2011-01-10 15:01:36 -06:00
|
|
|
printf "Usage: linkoo </path/to/ooo/install> [</path/to/ooo/build/tree>] [--dry-run]\n";
|
2004-10-12 10:06:43 -05:00
|
|
|
exit (1);
|
|
|
|
}
|
|
|
|
|
2007-07-05 03:01:53 -05:00
|
|
|
substr ($OOO_INSTALL, 0, 1) eq '/' || die "linkoo requires absolute paths ($OOO_INSTALL does not qualify)";
|
|
|
|
substr ($OOO_BUILD, 0, 1) eq '/' || die "linkoo requires absolute paths ($OOO_BUILD does not qualify)";
|
2004-12-23 03:52:43 -06:00
|
|
|
|
2004-10-12 10:06:43 -05:00
|
|
|
-d $OOO_INSTALL || die "No such directory $OOO_INSTALL";
|
|
|
|
-w $OOO_INSTALL || die "You need write access to $OOO_INSTALL";
|
|
|
|
-d $OOO_BUILD || die "No such directory $OOO_BUILD";
|
2007-07-05 03:01:53 -05:00
|
|
|
-d "$OOO_INSTALL/" . $program_dir . "/resource" || die "$OOO_INSTALL doesn't look like an OO install";
|
2004-10-12 10:06:43 -05:00
|
|
|
|
2006-03-08 06:59:14 -06:00
|
|
|
($TARGET, $LIBVER, $LANG) = sniff_target ($OOO_BUILD);
|
2004-10-12 10:06:43 -05:00
|
|
|
|
2005-04-11 02:58:17 -05:00
|
|
|
evilness ('undo');
|
|
|
|
|
2004-10-12 10:06:43 -05:00
|
|
|
my $installed_files = build_installed_list ($OOO_INSTALL);
|
|
|
|
|
|
|
|
scan_and_link_files ($OOO_BUILD, $installed_files, $TARGET);
|
2005-05-31 10:22:06 -05:00
|
|
|
link_iso_res();
|
|
|
|
link_types_rdb();
|
2010-08-24 07:33:48 -05:00
|
|
|
link_oovbaapi_rdb();
|
2010-12-03 10:57:17 -06:00
|
|
|
link_pagein_files();
|
2004-10-12 10:06:43 -05:00
|
|
|
|
2010-08-24 07:40:58 -05:00
|
|
|
if (!-f "$OOO_INSTALL/" . $brand_program_dir . "/ooenv") {
|
2011-01-10 15:01:36 -06:00
|
|
|
my $ooenv;
|
2010-08-24 07:40:58 -05:00
|
|
|
print "Creating '$OOO_INSTALL/", $brand_program_dir, "/ooenv'\n";
|
|
|
|
open ($ooenv, ">$OOO_INSTALL/" . $brand_program_dir . "/ooenv") || die "Can't open $OOO_INSTALL/" . $brand_program_dir . "/ooenv: $!";
|
2005-04-11 02:58:17 -05:00
|
|
|
print $ooenv $env_script;
|
2010-08-24 08:55:33 -05:00
|
|
|
print $ooenv "# testtool\nexport SRC_ROOT=$OOO_BUILD\n";
|
2005-04-11 02:58:17 -05:00
|
|
|
close ($ooenv);
|
2004-10-12 10:06:43 -05:00
|
|
|
}
|
2005-02-11 08:23:57 -06:00
|
|
|
|
2005-04-11 02:58:17 -05:00
|
|
|
evilness ('do');
|
2007-07-18 08:59:37 -05:00
|
|
|
|
|
|
|
print "\nlinkoo finished, please don't forget to source ooenv before ./soffice.\n";
|