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.
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.
I used version 2.16.4.
Here's most of what I needed:
Those are the three easiest things to get. Downloading Guile-Cairo will be explained in step 3.
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:
(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.
If it worked, you'll see some text like this:
And there will now be a "guile-cairo" folder in the folder you opened the terminal window from.
make
make install
(Or "new2dir make install" (without quotes) if you'd like to make a .pet or .sfs file.)
make
make install
(Or "new2dir make install" (without quotes) if you'd like to make a .pet or .sfs file.)
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.)
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:
make
make install
(Or "new2dir make install" (without quotes) if you'd like to make a .pet or .sfs file.)
If all went well, somewhere in the messages printed by ./configure should be this text:
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):
And delete these three lines near the bottom (starting at line 188 in my cairo-gobject.h):
Then, save the cairo-gobject.h file.
And also, I got an encouraging-looking response when I tried a command I found on this page:
The response was:
Hopefully everything will go smoothly now that Guile-Gnome has no way not to acknowledge that Cairo really does have GObject support.
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.
But, back to the topic of how to build Guile-Gnome in Lucid Puppy Linux 5.2.8 version 004.
git clone git://git.savannah.nongnu.org/guile-cairo.git
# 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.
./configure
./configure
export pixman_CFLAGS="-I/usr/local/include/pixman-1"
./configure --prefix=/usr/local
./configure --prefix=/usr/local/
All available wrappers will be built:
atk cairo corba gconf glib gnome-vfs gtk libglade libgnome libgnomecanvas libgnomeui pango
#if CAIRO_HAS_GOBJECT_FUNCTIONS
#else /* CAIRO_HAS_GOBJECT_FUNCTIONS */
# error Cairo was not compiled with support for GObject
#endif /* CAIRO_HAS_GOBJECT_FUNCTIONS */
I believe that due to the way I compiled Cairo (described above), Cairo really does have GObject support.
pkg-config --libs cairo-gobject
-pthread -L/usr/local/lib -lcairo-gobject -lcairo -lgobject-2.0 -lgthread-2.0 -lrt -lglib-2.0
make
(use-modules (gnome-2))