Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorSimon Schampijer <simon@schampijer.de>2007-11-29 13:50:44 (GMT)
committer Simon Schampijer <simon@schampijer.de>2007-11-29 13:50:44 (GMT)
commit8c72c8033757c0624c57b3dc597cbaae0248e448 (patch)
tree62bc704eaab90e4117796ce34e848237b91068ff /lib
parent6e1065454de9c3d252cd92a453bd69de2410ec65 (diff)
Fix the path to the makeindex and and missing import #2856
Diffstat (limited to 'lib')
-rw-r--r--lib/sugar/bundle/contentbundle.py5
-rw-r--r--lib/sugar/env.py6
2 files changed, 6 insertions, 5 deletions
diff --git a/lib/sugar/bundle/contentbundle.py b/lib/sugar/bundle/contentbundle.py
index 517ee9a..9e2d36e 100644
--- a/lib/sugar/bundle/contentbundle.py
+++ b/lib/sugar/bundle/contentbundle.py
@@ -21,7 +21,8 @@ from ConfigParser import ConfigParser
import os
from sugar import env
-from sugar.bundle.bundle import Bundle, NotInstalledException
+from sugar.bundle.bundle import Bundle, NotInstalledException, \
+ MalformedBundleException
class ContentBundle(Bundle):
"""A Sugar content bundle
@@ -162,7 +163,7 @@ class ContentBundle(Bundle):
def _run_indexer(self):
os.spawnlp(os.P_WAIT, 'python',
'python',
- os.path.join(env.get_user_library_path(), 'makeIndex.py'))
+ env.get_prefix_path('share/library-common/make_index.py'))
def is_installed(self):
if self._unpacked:
diff --git a/lib/sugar/env.py b/lib/sugar/env.py
index c46b7d0..ea0be7b 100644
--- a/lib/sugar/env.py
+++ b/lib/sugar/env.py
@@ -18,7 +18,7 @@
import os
-def _get_prefix_path(base, path=None):
+def get_prefix_path(base, path=None):
if os.environ.has_key('SUGAR_PREFIX'):
prefix = os.environ['SUGAR_PREFIX']
else:
@@ -78,10 +78,10 @@ def get_user_library_path():
return os.path.expanduser('~/Library')
def get_locale_path(path=None):
- return _get_prefix_path('share/locale', path)
+ return get_prefix_path('share/locale', path)
def get_bin_path(path=None):
- return _get_prefix_path('bin', path)
+ return get_prefix_path('bin', path)
def get_service_path(name):
return _get_sugar_path('services', name)