Note by Apollia on Nov. 8, 2023: Please join my Patreon if you'd like to support me and my work!

My main personal website is now Apollia.org. I'm still not sure what to do with Astroblahhh.Com, so it's mostly staying as-is for now.





Puppy Linux Blog Post:

How to compile Guile-Gnome 2.16.4 in Lucid Puppy Linux 5.2.8
12/30/2015

Post Below
12/30/2015 - How to compile Guile-Gnome 2.16.4 in Lucid Puppy Linux 5.2.8 (Puppy Linux)

    Hide/Show:


   ▲ Top  ▼ Bottom  △ TOC
How to compile Guile-Gnome 2.16.4 in Lucid Puppy Linux 5.2.8
Wednesday, December 30th, 2015
14:39:36 GMT

Puppy Linux

It was another difficult process, but I finally managed to build Guile-Gnome for GNU Guile in Lucid Puppy Linux 5.2.8 version 004.

Now, I can actually make GNU Guile create GTK windows! So, perhaps GNU Guile will turn out to be a good substitute for PHP-GTK.

If I can get GNU Guile to work with MySQL and SQLite databases, and also have it output web pages (so I can keep Astroblahhh Desktop's web interface), perhaps a GNU Guile-based Astroblahhh Desktop might be feasible.

I wonder if GNU Guile can work with OrientDB?

However, I'm not sure if I should write the CMS (content management system, for lack of a better term) of my dreams in any very uncommonly used language or platform. PHP is available from most web hosts. Even figuring out how to make the Java-based OrientDB work with my websites seems like it might be difficult, though maybe less difficult than figuring out how to get some form of Lisp or Scheme like GNU Guile working on a web server.


But, back to the topic of how to build Guile-Gnome in Lucid Puppy Linux 5.2.8 version 004.

Once again, I had to use some trickery (or guile! Haha, I made a pun) to get past some hopefully mistaken errors. I'll explain more about that below.


  1. The first prerequisite is to build GNU Guile, if you haven't already. This earlier blog post of mine has instructions.


  2. You can download Guile-Gnome itself here:

    https://www.gnu.org/software/guile-gnome/download.html

    I used version 2.16.4.


  3. Guile-Gnome has various dependencies that you'll need to download.

    Here's most of what I needed:

    Those are the three easiest things to get. Downloading Guile-Cairo will be explained in step 3.


  4. Guile-Cairo can't so easily be downloaded because the needed version was never officially released - it seems to only be available by downloading it via Git (and not even GitHub).

    Fortunately, an at least partway functional copy of an old version of Git exists in the Lucid Puppy Linux DevX SFS file of development tools. The DevX, by the way, is what you need to use to compile software in Lucid Puppy Linux 5.2.8.

    My page of Some Puppy Linux Basics explains more about DevX files, and if you need the DevX for Lucid Puppy 5.2.8, it's available at this link:

    http://distro.ibiblio.org/puppylinux/puppy-5.2.8/

    (If you're using a different version of Puppy than Lucid Puppy 5.2.8, that DevX probably won't work, so you should instead download the DevX released for your Puppy.

    Also, if you're not using Lucid Puppy 5.2.8, please bear in mind that the instructions in this blog post might not all apply or work for you, since different Puppy Linux distros, and probably even different versions of the same Puppy distro, can differ quite substantially from each other.)

    And here's how to load SFS files.


  5. Once you have the DevX mounted, you should be able to run Git. Go to a folder that you want to download Guile-Cairo into, open a terminal window, and put in this command:

    git clone git://git.savannah.nongnu.org/guile-cairo.git

    If it worked, you'll see some text like this:

    # git clone git://git.savannah.nongnu.org/guile-cairo.git
    Initialized empty Git repository in /root/guile-cairo/.git/
    remote: Counting objects: 830, done.
    remote: Compressing objects: 100% (280/280), done.
    remote: Total 830 (delta 522), reused 830 (delta 522)
    Receiving objects: 100% (830/830), 594.72 KiB | 666 KiB/s, done.
    Resolving deltas: 100% (522/522), done.

    And there will now be a "guile-cairo" folder in the folder you opened the terminal window from.


  6. Now we can get started compiling things. First, an easy one. Unzip the G-Wrap source code tarball, open the G-Wrap folder, open a terminal window, and put in these commands:

    ./configure

    make

    make install

    (Or "new2dir make install" (without quotes) if you'd like to make a .pet or .sfs file.)


  7. Next, Pixman, which is also easy to compile. Unzip the Pixman source code tarball, open the Pixman folder, open a terminal window, and put in these commands:

    ./configure

    make

    make install

    (Or "new2dir make install" (without quotes) if you'd like to make a .pet or .sfs file.)


  8. Next, a more difficult one to compile - Cairo. Unzip the Cairo source code tarball, open the Cairo folder, open a terminal window, and put in these commands:

    export pixman_CFLAGS="-I/usr/local/include/pixman-1"

    export pixman_LIBS="-L/usr/local/lib/ -lpixman-1"

    ./configure --enable-gobject=yes

    make

    make install

    (Or "new2dir make install" (without quotes) if you'd like to make a .pet or .sfs file.)


  9. Next, Guile-Cairo. Mostly easy, once you have Cairo itself compiled correctly.

    If you want to make a .pet or .sfs file, rename the Guile-Cairo folder to something like "guile_cairo-1.10". (Though I'm not sure that's the actual version number. You can use any version number - this rename is just to make it so new2dir won't complain later on about not being in a folder with a version number.)

    Next, open the Guile-Cairo folder, open a terminal window, and put in these commands:

    ./configure --prefix=/usr/local

    make

    make install

    (Or "new2dir make install" (without quotes) if you'd like to make a .pet or .sfs file.)


  10. Now, it should be possible to compile Guile-Gnome itself. Unzip the Guile-Gnome source code tarball, open the Guile-Gnome folder, open a terminal window, and put in this command:

    ./configure --prefix=/usr/local/

    If all went well, somewhere in the messages printed by ./configure should be this text:

    All available wrappers will be built:
      atk cairo corba gconf glib gnome-vfs gtk libglade libgnome libgnomecanvas libgnomeui pango


  11. Don't type "make" yet. Here's where I had to do a maybe unwise trick, so Guile-Gnome won't complain that "Cairo was not compiled with support for GObject".

    Go to the folder /usr/local/include/cairo/ and open the file cairo-gobject.h in a text editor.

    Delete this line toward the top (line 42 in my cairo-gobject.h):

    #if CAIRO_HAS_GOBJECT_FUNCTIONS

    And delete these three lines near the bottom (starting at line 188 in my cairo-gobject.h):

    #else /* CAIRO_HAS_GOBJECT_FUNCTIONS */
    # error Cairo was not compiled with support for GObject
    #endif /* CAIRO_HAS_GOBJECT_FUNCTIONS */

    Then, save the cairo-gobject.h file.


    I believe that due to the way I compiled Cairo (described above), Cairo really does have GObject support.

    And also, I got an encouraging-looking response when I tried a command I found on this page:

    pkg-config --libs cairo-gobject

    The response was:

    -pthread -L/usr/local/lib -lcairo-gobject -lcairo -lgobject-2.0 -lgthread-2.0 -lrt -lglib-2.0


  12. Now, back in the Guile-Gnome folder's, type this in a terminal window:

    make

    Hopefully everything will go smoothly now that Guile-Gnome has no way not to acknowledge that Cairo really does have GObject support.


  13. Next, type either "make install" (without quotes) or "new2dir make install" if you want to make a .pet or .sfs file out of Guile-Gnome.


  14. For some reason, GNU Guile doesn't automatically know where the Guile-Gnome modules are, so you have to give GNU Guile this command:

    (use-modules (gnome-2))

    After doing that, it should be possible to run the example scripts from the Guile-Gtk Overview page, which will create a GTK window containing a button which says "Hello, World!"

I don't know yet how to make GNU Guile automatically find the Guile-Gnome modules.

But, I assume that similar to GNU Emacs, there's probably some sort of config file somewhere which you can put commands in like "(use-modules (gnome-2))" so those commands will be run automatically every time you start GNU Guile.

   ▲ Top  ▼ Bottom  △ TOC


    Hide/Show:





Note by Apollia on Nov. 8, 2023: Please join my Patreon if you'd like to support me and my work!

My main personal website is now Apollia.org. I'm still not sure what to do with Astroblahhh.Com, so it's mostly staying as-is for now.