Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
2929c2a4
Kaydet (Commit)
2929c2a4
authored
Ock 10, 2011
tarafından
Michael Meeks
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
make linkoo scan the solver too, for Norbert's gnumake work
üst
6caa9c0b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
66 additions
and
47 deletions
+66
-47
linkoo
solenv/bin/linkoo
+66
-47
No files found.
solenv/bin/linkoo
Dosyayı görüntüle @
2929c2a4
...
@@ -2,6 +2,8 @@
...
@@ -2,6 +2,8 @@
eval 'exec perl -S $0 ${1+"$@"}'
eval 'exec perl -S $0 ${1+"$@"}'
if 0;
if 0;
use strict;
#*************************************************************************
#*************************************************************************
#
#
# This app makes it easy to link a live build
# This app makes it easy to link a live build
...
@@ -36,8 +38,8 @@
...
@@ -36,8 +38,8 @@
#*************************************************************************
#*************************************************************************
# ends up in program/ooenv
# ends up in program/ooenv
( $moz_lib = `pkg-config --variable=libdir mozilla-nss` ) =~ tr/\n/:/;
(
my
$moz_lib = `pkg-config --variable=libdir mozilla-nss` ) =~ tr/\n/:/;
$env_script = '
my
$env_script = '
java_path=`../basis-link/ure-link/bin/javaldx 2>/dev/null`
java_path=`../basis-link/ure-link/bin/javaldx 2>/dev/null`
export LD_LIBRARY_PATH=".:$java_path:' . $moz_lib . '$LD_LIBRARY_PATH"
export LD_LIBRARY_PATH=".:$java_path:' . $moz_lib . '$LD_LIBRARY_PATH"
ulimit -c unlimited
ulimit -c unlimited
...
@@ -51,17 +53,25 @@ export OOO_DISABLE_RECOVERY=1
...
@@ -51,17 +53,25 @@ export OOO_DISABLE_RECOVERY=1
export SAL_ALLOW_LINKOO_SYMLINKS=1
export SAL_ALLOW_LINKOO_SYMLINKS=1
';
';
$program_dir = 'basis-link/program';
my $dry_run = 0;
$brand_program_dir = 'program';
my $usage = 0;
$ure_misc_dir = 'basis-link/ure-link/share/misc';
$ure_java_dir = 'basis-link/ure-link/share/java';
$ure_lib_dir = 'basis-link/ure-link/lib';
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';
$program_dir = 'openoffice.org/basis-link/MacOS' if ($ENV{OS} eq 'MACOSX'); # FIXME probably wrong
$program_dir = 'openoffice.org/basis-link/MacOS' if ($ENV{OS} eq 'MACOSX'); # FIXME probably wrong
my @exceptions = ( 'cppuhelper', 'sunjavaplugin', 'libjvmfwk' );
my @exceptions = ( 'cppuhelper', 'sunjavaplugin', 'libjvmfwk' );
%replaceable = (
my
%replaceable = (
$program_dir => '\.so',
$program_dir => '\.so',
$ure_lib_dir => '\.so',
$ure_lib_dir => '\.so',
$ure_java_dir => '\.jar$',
$ure_java_dir => '\.jar$',
...
@@ -73,11 +83,11 @@ my @exceptions = ( 'cppuhelper', 'sunjavaplugin', 'libjvmfwk' );
...
@@ -73,11 +83,11 @@ my @exceptions = ( 'cppuhelper', 'sunjavaplugin', 'libjvmfwk' );
# strangely enough, OSX has those small differences...
# strangely enough, OSX has those small differences...
$replaceable{$program_dir} = '\.dylib$' if ($ENV{OS} eq 'MACOSX');
$replaceable{$program_dir} = '\.dylib$' if ($ENV{OS} eq 'MACOSX');
$replaceable{$ure_lib_dir
_dir
} = '\.dylib$' if ($ENV{OS} eq 'MACOSX');
$replaceable{$ure_lib_dir} = '\.dylib$' if ($ENV{OS} eq 'MACOSX');
@search_dirs = ( 'lib', 'bin', 'class' );
my
@search_dirs = ( 'lib', 'bin', 'class' );
@known_duplicates = ( 'db.jar', 'libi18n' );
my
@known_duplicates = ( 'db.jar', 'libi18n' );
sub sniff_target($)
sub sniff_target($)
{
{
...
@@ -184,6 +194,39 @@ sub do_link($$$$@)
...
@@ -184,6 +194,39 @@ sub do_link($$$$@)
}
}
}
}
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) {
print "Unknown duplicate file '$file' in: '" .
$build_files->{$file} . "' vs '" .
$module_path . "' in module $path\n";
exit (1);
}
} else {
$build_files->{$file} = $module_path;
}
}
}
}
closedir ($dirh_module);
}
}
sub scan_and_link_files($$$)
sub scan_and_link_files($$$)
{
{
my $build_path = shift;
my $build_path = shift;
...
@@ -201,38 +244,17 @@ sub scan_and_link_files($$$)
...
@@ -201,38 +244,17 @@ sub scan_and_link_files($$$)
}
}
closedir ($dirh_toplevel);
closedir ($dirh_toplevel);
# FIXME: re-implement the $product functionality
# Scan the old-style module/$target/lib directories ...
my $module;
my %build_files;
my %build_files;
for $module (@modules) {
for my $module (@modules) {
for $elem (@search_dirs) {
scan_one_dir ($installed_files, \%build_files, $module, 0);
my $dirh_module;
my $module_path = "$module/$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) {
print "Unknown duplicate file '$file' in: '" .
$build_files{$file} . "' vs '" .
$module_path . "' in module $module\n";
exit (1);
}
}
$build_files{$file} = $module_path;
}
}
}
closedir ($dirh_module);
}
}
}
# 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);
for my $file (keys %build_files) {
for my $file (keys %build_files) {
my $src = $build_files{$file};
my $src = $build_files{$file};
my $dest = $installed_files->{$file};
my $dest = $installed_files->{$file};
...
@@ -310,14 +332,10 @@ sub link_pagein_files()
...
@@ -310,14 +332,10 @@ sub link_pagein_files()
print "\n";
print "\n";
}
}
my $a;
for my $a (@ARGV) {
my $usage = 0;
for $a (@ARGV) {
# options
# options
if ($a =~ /--product/) {
if ($a =~ /--dry-run/) {
$product = 1;
} elsif ($a =~ /--dry-run/) {
$dry_run = 1;
$dry_run = 1;
} elsif (($a eq '--help') || ($a eq '-h')) {
} elsif (($a eq '--help') || ($a eq '-h')) {
$usage = 1;
$usage = 1;
...
@@ -338,7 +356,7 @@ if (!defined $OOO_BUILD && defined $ENV{SRC_ROOT}) {
...
@@ -338,7 +356,7 @@ if (!defined $OOO_BUILD && defined $ENV{SRC_ROOT}) {
}
}
if ($usage || !defined $OOO_INSTALL || !defined $OOO_BUILD) {
if ($usage || !defined $OOO_INSTALL || !defined $OOO_BUILD) {
printf "Usage: linkoo </path/to/ooo/install> [</path/to/ooo/build/tree>] [--
product] [--
dry-run]\n";
printf "Usage: linkoo </path/to/ooo/install> [</path/to/ooo/build/tree>] [--dry-run]\n";
exit (1);
exit (1);
}
}
...
@@ -363,6 +381,7 @@ link_oovbaapi_rdb();
...
@@ -363,6 +381,7 @@ link_oovbaapi_rdb();
link_pagein_files();
link_pagein_files();
if (!-f "$OOO_INSTALL/" . $brand_program_dir . "/ooenv") {
if (!-f "$OOO_INSTALL/" . $brand_program_dir . "/ooenv") {
my $ooenv;
print "Creating '$OOO_INSTALL/", $brand_program_dir, "/ooenv'\n";
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: $!";
open ($ooenv, ">$OOO_INSTALL/" . $brand_program_dir . "/ooenv") || die "Can't open $OOO_INSTALL/" . $brand_program_dir . "/ooenv: $!";
print $ooenv $env_script;
print $ooenv $env_script;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment