~ubuntu-branches/ubuntu/karmic/openoffice.org-l10n/karmic

« back to all changes in this revision

Viewing changes to ooo-build/patches/src680/.#gcj-32bit-runtime-path.diff.1.1

  • Committer: Bazaar Package Importer
  • Author(s): Matthias Klose
  • Date: 2006-04-27 19:29:22 UTC
  • Revision ID: james.westby@ubuntu.com-20060427192922-2dburxv3b63f8v0u
Tags: 2.0.2-2ubuntu5
* Copy of the openoffice.org source.
  - debian/control.in: Change source name.
  - debian/changelog: Change source name.
  - debian/control: Regenerate control file.
* Add kurdish translations exported from Rosetta (2006-04-18).
* Workaround bad message strings in recently included GSI files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
--- jvmfwk/plugins/sunmajor/pluginlib/gnujre.cxx.old    2006-03-13 12:11:30.359949000 +0000
 
2
+++ jvmfwk/plugins/sunmajor/pluginlib/gnujre.cxx        2006-03-13 12:13:00.779949000 +0000
 
3
@@ -37,6 +37,11 @@
 
4
 #include "osl/thread.h"
 
5
 #include "gnujre.hxx"
 
6
 #include "util.hxx"
 
7
+extern "C"
 
8
+{
 
9
+#include <sys/utsname.h>
 
10
+#include <string.h>
 
11
+}
 
12
 
 
13
 using namespace rtl;
 
14
 using namespace std;
 
15
@@ -53,10 +58,12 @@
 
16
 char const* const* GnuInfo::getJavaExePaths(int * size)
 
17
 {
 
18
     static char const * ar[] = {
 
19
-        "gij",
 
20
-        "bin/gij",
 
21
+       "gij-4.1",
 
22
+       "bin/gij-4.1"
 
23
        "gij-4.0",
 
24
        "bin/gij-4.0"
 
25
+        "gij",
 
26
+        "bin/gij",
 
27
     };
 
28
     *size = sizeof (ar) / sizeof (char*);
 
29
     return ar;
 
30
@@ -72,8 +79,27 @@
 
31
         , "/lib/libgcj.so.4"
 
32
 #endif
 
33
     };
 
34
+#if defined(__linux__) && defined (__i386__)
 
35
+    struct utsname uts;
 
36
+    static char const* ar64[]= {
 
37
+          "/lib32/libgcj.so.7"
 
38
+          "/lib32/libgcj.so.6"
 
39
+    };
 
40
+    uname(&uts);
 
41
+    if (!strcmp("x86_64", uts.machine))
 
42
+    {
 
43
+        *size = sizeof(ar64) / sizeof (char*);
 
44
+       return ar64;
 
45
+    }
 
46
+    else
 
47
+    {
 
48
+        *size = sizeof(ar) / sizeof (char*);
 
49
+       return ar;
 
50
+    }
 
51
+#else
 
52
     *size = sizeof(ar) / sizeof (char*);
 
53
     return ar;
 
54
+#endif
 
55
 }
 
56
 
 
57
 bool GnuInfo::initialize(vector<pair<OUString, OUString> > props)