]> git.donarmstrong.com Git - lilypond.git/blobdiff - buildscripts/guile-gnome.sh
remove <hr>.
[lilypond.git] / buildscripts / guile-gnome.sh
index 7ebc6dbd9edc0b6e95b5e3c217064b56de8212ec..194dad2c27e649bccdaa49c6724e4b306c593efe 100644 (file)
@@ -1,7 +1,5 @@
 #!@BASH@
 
-# WIP - this (the guile-gnome canvas) is broken ATM.
-
 # guile-gnome.sh -- download, compile, install g-wrap, guile-gnome,
 # pango
 
@@ -13,10 +11,22 @@ set -ex
 
 # Where user built stuff will be installed
 OPT=$HOME/usr/pkg
+# When using GUILE CVS, make a slib/require like so
+cat > /dev/null <<EOF
+cd ~/usr/pkg/guile/share/guile/1.7 && ln -s /usr/share/guile/1.6/slib .
+cd && guile -c "(use-modules (ice-9 slib)) (require 'new-catalog)"
+EOF
+# otherwise, this may fix it...
+SLIB_PATH=`locate slib/require.scm | head -1 | sed -s 's/require.scm//g'`
 
 # What extra modules to pull (eg: EXTRA="libgnomecanvas libwnck")
 EXTRA=${EXTRA-libgnomecanvas}
-GGVERSION=2.5.992
+GGVERSION=2.7.91
+GWRAPVERSION=1.9.3
+
+download=$HOME/usr/src/releases
+[ -d $download ] || mkdir -p $download
+WGET="wget -N -P $download"
 
 export AUTOMAKE=automake-1.8
 export ACLOCAL=aclocal-1.8
@@ -37,7 +47,7 @@ fi
 
 # test: the name of our download and build directory
 rm -rf test
-mkdir test
+mkdir -p test
 cd test
 
 ## 1.  install gnome-devel
@@ -57,8 +67,8 @@ if ! pkg-config --atleast-version=1.5.1 pango; then
        echo "." > CVS/Repository
        cvs -z3 checkout -P pango
     else
-        wget ftp://ftp.gtk.org/pub/gtk/v2.5/pango-1.5.2.tar.gz
-       tar -zf pango-1.5.2.tar.gz
+        $WGET ftp://ftp.gtk.org/pub/gtk/v2.5/pango-1.5.2.tar.gz
+       tar -xzf pango-1.5.2.tar.gz
        ln -s pango-1.5.2 pango
     fi
     cd pango
@@ -71,8 +81,10 @@ if ! pkg-config --atleast-version=1.5.1 pango; then
     cd ../..
 fi
 
-## 3. Currently (2004-9-15) GUILE CVS works again
-## PATH=/usr/bin:$PATH
+## 3. Currently (2004-9-15) GUILE CVS works somewhat
+##    But there's a guile/g-wrap problem with integer parameters
+unset GUILE_LOAD_PATH
+PATH=/usr/bin:$PATH
 
 if [ -d $OPT/libffi/ ]; then
     export LDFLAGS=-L$OPT/libffi/lib
@@ -81,7 +93,8 @@ fi
 
 PKG_CONFIG_PATH=$OPT/g-wrap/lib/pkgconfig:$PKG_CONFIG_PATH
 LD_LIBRARY_PATH=$OPT/g-wrap/lib:$LD_LIBRARY_PATH
-GUILE_LOAD_PATH=$OPT/g-wrap/share/guile/site:$GUILE_LOAD_PATH
+GUILE_LOAD_PATH=$OPT/g-wrap/share/guile/site:$GUILE_LOAD_PATH:$SLIB_PATH
+
 
 ## 4.  get g-wrap 2.0
 ## note that bleeding edge (2004-9-13) g-wrap breaks guile-gnome.
@@ -96,9 +109,9 @@ if ! pkg-config --exact-version=1.9.1 g-wrap-2.0-guile; then
         ## ughr:
        mkdir -p g-wrap/libffi
     else
-       wget http://savannah.nongnu.org/download/g-wrap/g-wrap-1.9.1.tar.gz
-       tar zxf g-wrap-1.9.1.tar.gz
-       ln -s g-wrap-1.9.1 g-wrap
+       $WGET http://savannah.nongnu.org/download/g-wrap/g-wrap-$GWRAPVERSION.tar.gz
+       tar xzf $download/g-wrap-$GWRAPVERSION.tar.gz
+       ln -s g-wrap-$GWRAPVERSION g-wrap
     fi
     cd g-wrap
     
@@ -123,7 +136,6 @@ fi
 PKG_CONFIG_PATH=$OPT/guile-gnome/lib/pkgconfig:$PKG_CONFIG_PATH
 LD_LIBRARY_PATH=$OPT/guile-gnome/lib:$LD_LIBRARY_PATH
 GUILE_LOAD_PATH=$OPT/guile-gnome/share/guile:$GUILE_LOAD_PATH
-
 ## 5.  get guile-gnome
 if ! pkg-config --atleast-version=$GGVERSION guile-gnome-glib; then
     if [ -n "$BLOEDIGE_RAND" ]; then
@@ -165,8 +177,8 @@ if ! pkg-config --atleast-version=$GGVERSION guile-gnome-glib; then
        fi
        cd ..
     else
-       wget http://ambient.2y.net/wingo/tmp/guile-gnome-platform-$GGVERSION.tar.gz
-       tar xzf guile-gnome-platform-$GGVERSION.tar.gz
+       $WGET http://download.gna.org/guile-gnome/releases/guile-gnome-platform-$GGVERSION.tar.gz
+       tar xzf $download/guile-gnome-platform-$GGVERSION.tar.gz
        ln -s guile-gnome-platform-$GGVERSION guile-gnome
        cd guile-gnome
        ln -s . src