Talk:Sugar on MacOS X


Jump to: navigation, search

Could the person who flagged this as inaccurate (or anyone else who knows details) please add some information here as to *what* might be inaccurate?

jtauber: I wasn't the one who flagged it but one thing I'd note is that this only describes how to get pygtk working. Sugar has lots of other dependencies which aren't even mentioned on this page. I've successfully built pygtk but that's just the first step of getting Sugar up and running. I still have a long way to go.


errors about "import (module)"

you need to add "import pygtk; pygtk.require('2.0')" before "import gtk", "import gobject" or any module depending on pygtk at all if you want it to work, at least in my experience

also, you might want to make sure all the modules you're building have no undefined symbols (usually adding -no-undefined -Wl,-bundle_loader,/usr/bin/python takes care of any loose ends)

and you need to add #define NO_IMPORT_PYGOBJECT in sugar/lib/sugar/_sugarext.override to prevent having PyGObject multiply defined when linking

Nobody 02:59, 24 January 2008 (EST)


sugar-jhbuild is nice, but it assumes some things, you might want to download it and then replace certain things in to get to working on your system, although you're likely to not get it working 100%, it will give you a more accurate list of what you've got missing currently

diff --git a/ b/
index bc5e15f..812a952 100644
--- a/
+++ b/
@@ -90,7 +90,7 @@ class DependencyChecker:
             self._append_missing_command(command, desc)
     def check_python_import(self, name):
-        p = subprocess.Popen(['python', '-c', 'import ' + name], stderr=subprocess.PIPE)
+        p = subprocess.Popen(['python', '-c', 'import pygtk; pygtk.require(\'2.0\'); import ' + name], stderr=subprocess.PIPE)
         if 'ImportError' in p.communicate()[1]:
             self._missing.append(name + ' (python module)')
@@ -107,7 +107,7 @@ class DependencyChecker:
             self._missing.append('automake %s' % version)
     def check_libtool(self, version):
-        if not _check_command(['libtoolize', '--version'],
+        if not _check_command(['glibtoolize', '--version'],
                               r'libtoolize \([^)]*\) ([\d.]+)', version):
             self._missing.append('libtool %s' % version)
@@ -210,8 +210,8 @@ class cmd_sanitycheck(Command):
-        checker.check_library('')
-        checker.check_library('')
         # GNOME 2.18

adding import for pygtk as a catchall for leaf dependancies

renaming libtoolize command to find gnu's libtoolize that lives on macosx

removing and because they do not exist and will never exist on macosx and apparently the method to check for libraries requires loading them and dylibs don't meet that criteria as libraries

Nobody 03:40, 24 January 2008 (EST)

i just realized this wiki entry is essentially a copy of the windows "guide" to installing

which doesn't really help much and for the fact that so much content that belongs on a talk page is right there i'm feeling the urge to start from scratch and move the talk to the talk page in hopes of clearing things up for the casual browser and maybe the interested user Nobody 01:13, 25 January 2008 (EST)

Getting a jhbuild GTK+ working in Leopard (28.08.2009)

  1. Before you start be sure to have the os x developer tools installed (need a login, then download "Xcode x.x.x Developer DVD (Disk Image)"), check if you have a folder /Developer in your system, if you do they are probably installed.
  2. I used the instructions jhbuild gkt+ from gnome to get a working gtk+ environment. Be sure to folow each step, but don't build gimp.
  3. When you reach that point you can follow the first step on this page: pygtk faq which is no more than "jhbuild build meta-gtk-osx-python".
  4. If you are able to compile and you have no errors your environment should be read. To test it you could simply try this:
    1. open an editor and create this file
    2. open the terminal
    3. go to your files directory and type: python
    4. a window near the mac logo should open and if you click on the text "Hello World" the terminal should show: Hello World \n destroy signal occurred
  5. if this works you have a working python gtk+ environment. No you can help me get jhbuild-sugar running, or edit this if you solved it.

If somebody else with more activity in this wiki could check it and it works, maybe we could update the page that had me working with old libraries and links for hours. Thanks.

sossio 14:17, 28 August 2009 (UTC)
Personal tools
  • Log in
  • Login with OpenID
About OLPC
About the laptop
About the tablet
OLPC wiki