From 0b3335f137b61ab13ce03c66c803b224ced1ab2a Mon Sep 17 00:00:00 2001 From: Daniel Drake Date: Tue, 04 Oct 2011 11:54:18 +0000 Subject: Add ARM support Created per-arch plugins and bin dirs. The "bin" symlink is created on first run appropriately based on host arch. Added ARM binaries. --- diff --git a/bin-arm/m4 b/bin-arm/m4 new file mode 100755 index 0000000..f20732a --- /dev/null +++ b/bin-arm/m4 Binary files differ diff --git a/bin-arm/mozplugger-controller b/bin-arm/mozplugger-controller new file mode 100755 index 0000000..3e11ece --- /dev/null +++ b/bin-arm/mozplugger-controller Binary files differ diff --git a/bin-arm/mozplugger-helper b/bin-arm/mozplugger-helper new file mode 100755 index 0000000..422c9e9 --- /dev/null +++ b/bin-arm/mozplugger-helper Binary files differ diff --git a/bin-arm/mozplugger-linker b/bin-arm/mozplugger-linker new file mode 100755 index 0000000..5c063e8 --- /dev/null +++ b/bin-arm/mozplugger-linker Binary files differ diff --git a/bin/sugar-pdf-viewer b/bin-arm/sugar-pdf-viewer index b9719ec..b9719ec 100755 --- a/bin/sugar-pdf-viewer +++ b/bin-arm/sugar-pdf-viewer diff --git a/bin/m4 b/bin-x86/m4 index b7c5640..b7c5640 100755 --- a/bin/m4 +++ b/bin-x86/m4 Binary files differ diff --git a/bin/mozplugger-controller b/bin-x86/mozplugger-controller index b764962..b764962 100755 --- a/bin/mozplugger-controller +++ b/bin-x86/mozplugger-controller Binary files differ diff --git a/bin/mozplugger-helper b/bin-x86/mozplugger-helper index 471db8f..471db8f 100755 --- a/bin/mozplugger-helper +++ b/bin-x86/mozplugger-helper Binary files differ diff --git a/bin/mozplugger-linker b/bin-x86/mozplugger-linker index 9021249..9021249 100755 --- a/bin/mozplugger-linker +++ b/bin-x86/mozplugger-linker Binary files differ diff --git a/bin/sugar-pdf-viewer b/bin-x86/sugar-pdf-viewer index b9719ec..b9719ec 100755 --- a/bin/sugar-pdf-viewer +++ b/bin-x86/sugar-pdf-viewer diff --git a/plugins/conf/mozpluggerrc b/plugins-arm/conf/mozpluggerrc index e2c90cd..e2c90cd 100644 --- a/plugins/conf/mozpluggerrc +++ b/plugins-arm/conf/mozpluggerrc diff --git a/plugins-arm/mozplugger.so b/plugins-arm/mozplugger.so new file mode 100755 index 0000000..d5d2f65 --- /dev/null +++ b/plugins-arm/mozplugger.so Binary files differ diff --git a/plugins/conf/mozpluggerrc b/plugins-x86/conf/mozpluggerrc index e2c90cd..e2c90cd 100644 --- a/plugins/conf/mozpluggerrc +++ b/plugins-x86/conf/mozpluggerrc diff --git a/plugins/mozplugger.so b/plugins-x86/mozplugger.so index fd9c1a7..fd9c1a7 100644 --- a/plugins/mozplugger.so +++ b/plugins-x86/mozplugger.so Binary files differ diff --git a/webactivity.py b/webactivity.py index 1e9280e..b703c5e 100644 --- a/webactivity.py +++ b/webactivity.py @@ -20,6 +20,7 @@ import logging from gettext import gettext as _ from gettext import ngettext import os +import platform import gobject gobject.threads_init() @@ -68,11 +69,20 @@ if not NEW_TOOLBARS: _TOOLBAR_EDIT = 1 _TOOLBAR_BROWSE = 2 -# Setup some env variables for the embedded PDF viewer +# Setup some files and env variables for the embedded PDF viewer +if platform.machine().startswith("arm"): + arch="arm" +else: + arch="x86" + +bindir = os.path.join(os.environ['SUGAR_BUNDLE_PATH'], 'bin') +if not os.path.exists(bindir): + archbindir = os.path.join(os.environ['SUGAR_BUNDLE_PATH'], 'bin-%s' % arch) + os.symlink(archbindir, bindir) + os.environ['MOZ_PLUGIN_PATH'] = os.path.join(os.environ['SUGAR_BUNDLE_PATH'], - 'plugins') -os.environ['OPERA_DIR'] = os.path.join(os.environ['SUGAR_BUNDLE_PATH'], - 'plugins', 'conf') + 'plugins-%s' % arch) +os.environ['OPERA_DIR'] = os.path.join(os.environ['MOZ_PLUGIN_PATH'], 'conf') if os.path.exists(_version_file): f = open(_version_file) -- cgit v0.9.1