3
# guile-gnome.sh -- download, compile, install g-wrap, guile-gnome,
6
# LilyPond has an experimental gnome canvas output backend -- hackers
7
# only. This depends on rather new versions of guile-gnome, g-wrap
12
# Where user built stuff will be installed
14
# When using GUILE CVS, make a slib/require like so
16
cd ~/usr/pkg/guile/share/guile/1.7 && ln -s /usr/share/guile/1.6/slib .
17
cd && guile -c "(use-modules (ice-9 slib)) (require 'new-catalog)"
19
# otherwise, this may fix it...
20
SLIB_PATH=`locate slib/require.scm | head -1 | sed -s 's/require.scm//g'`
22
# What extra modules to pull (eg: EXTRA="libgnomecanvas libwnck")
23
EXTRA=${EXTRA-libgnomecanvas}
29
download=$HOME/usr/src/releases
30
[ -d $download ] || mkdir -p $download
31
WGET="wget -N -P $download"
33
export AUTOMAKE=automake-1.8
34
export ACLOCAL=aclocal-1.8
35
export AUTOCONF=$(which autoconf2.50)
36
export AUTOHEADER=$(which autoheader2.50)
38
export PKG_CONFIG_PATH
39
export LD_LIBRARY_PATH
40
export GUILE_LOAD_PATH
42
if [ -z "$AUTOCONF" ]; then
45
if [ -z "$AUTOHEADER" ]; then
50
# test: the name of our download and build directory
55
## 1. install gnome-devel
56
## - Debian/unstable: apt-get install gnome-devel
61
PKG_CONFIG_PATH=$OPT/pango/lib/pkgconfig:$PKG_CONFIG_PATH
62
LD_LIBRARY_PATH=$OPT/pango/lib:$LD_LIBRARY_PATH
65
if ! pkg-config --atleast-version=1.5.1 pango; then
67
if [ -n "$BLOEDIGE_RAND" ]; then
68
echo ":pserver:anonymous@anoncvs.gnome.org:/cvs/gnome" > CVS/Root
69
echo "." > CVS/Repository
70
cvs -z3 checkout -P pango
72
$WGET ftp://ftp.gtk.org/pub/gtk/v2.6/pango-$PANGOVERSION.tar.gz
73
tar -xzf $download/pango-$PANGOVERSION.tar.gz
74
ln -s pango-$PANGOVERSION pango
78
if [ ! -f configure ]; then
81
./configure --prefix=$OPT/pango --enable-maintainer-mode --enable-gtk-doc
82
make XFT_LIBS="-L/usr/lib -lXft -L/usr/X11R6/lib -lfreetype -lz -lXrender -lX11 -lfontconfig" all install
86
## 3. Currently (2004-9-15) GUILE CVS works somewhat
87
## But there's a guile/g-wrap problem with integer parameters
88
## PATH=/usr/bin:$PATH
90
if [ -d $OPT/libffi/ ]; then
91
export LDFLAGS=-L$OPT/libffi/lib
92
export CPPFLAGS=-I$OPT/libffi/include
96
if ! pkg-config --atleast-version=$GWRAPVERSION g-wrap-2.0-guile; then
97
if [ -n "$BLOEDIGE_RAND" ]; then
98
tla register-archive a.rottmann@gmx.at--2004-main \
99
http://people.debian.org/~rotty/arch/a.rottmann@gmx.at/2004-main || true
101
## tla get a.rottmann@gmx.at--2004-main/g-wrap--tng g-wrap
102
## tla get a.rottmann@gmx.at--2004-main/g-wrap--mainline--1.9.0 g-wrap
103
tla get a.rottmann@gmx.at--2004-main/g-wrap--dev--0 g-wrap
105
mkdir -p g-wrap/libffi
107
$WGET http://savannah.nongnu.org/download/g-wrap/g-wrap-$GWRAPVERSION.tar.gz
108
tar xzf $download/g-wrap-$GWRAPVERSION.tar.gz
109
ln -s g-wrap-$GWRAPVERSION g-wrap
114
if [ ! -f configure ]; then
115
sh autogen.sh --noconfigure
119
../configure --prefix=$OPT/g-wrap --enable-maintainer-mode
122
PKG_CONFIG_PATH=$OPT/g-wrap/lib/pkgconfig:$PKG_CONFIG_PATH
123
LD_LIBRARY_PATH=$OPT/g-wrap/lib:$LD_LIBRARY_PATH
124
GUILE_LOAD_PATH=$OPT/g-wrap/share/guile/site:$GUILE_LOAD_PATH:$SLIB_PATH
127
## 4a. get g-lib 0.1.2
128
if ! guile -c "(use-modules (srfi srfi-35))"; then
129
if [ -n "$BLOEDIGE_RAND" ]; then
132
$WGET http://download.gna.org/guile-lib/guile-lib-$GLVERSION.tar.gz
133
tar xzf $download/guile-lib-$GLVERSION.tar.gz
134
ln -s guile-lib-$GLVERSION guile-lib
138
rm -rf $OPT/guile-lib
139
if [ ! -f src/configure ]; then
140
sh autogen.sh --noconfigure
144
../src/configure --prefix=$OPT/guile-lib #--enable-maintainer-mode
147
cp ./guile-lib/doc/guile-library.info doc
148
install -d $OPT/guile-lib/share/info
152
GUILE_LOAD_PATH=$OPT/guile-lib/share/guile:$GUILE_LOAD_PATH
156
## cp srfi-34.scm from CVS head ? --hwn
157
#(cd $OPT/g-wrap/share/guile/site
158
# mv srfi-34.scm srfi-34.scm-g-wrap
159
# cp $OPT/guile/share/guile-1.7/srfi/srfi-34.scm .)
161
## 5. get guile-gnome
162
if ! pkg-config --atleast-version=$GGVERSION guile-gnome-glib; then
163
if [ -n "$BLOEDIGE_RAND" ]; then
165
if false; then # rotty
166
tla register-archive guile-gnome-devel@gnu.org--2004 \
167
http://people.debian.org/~rotty/arch/guile-gnome-devel@gnu.org/2004/ || true
168
tla get guile-gnome-devel@gnu.org--2004/dists--dev guile-gnome
170
tla build-config -r configs/gnu.org/dev
173
# 5a. get extra modules (gnome canvas)
175
tla get guile-gnome-devel@gnu.org--2004/$i--dev $i
178
tla register-archive wingo@pobox.com--2004-main \
179
http://ambient.2y.net/wingo/arch/wingo@pobox.com--2004-main || true
181
tla get wingo@pobox.com--2004-main/guile-gnome-dists--release guile-gnome
183
tla build-config -r configs/gnu.org/guile-gnome-platform-$GGVERSION
185
EXTRA="pkg atk defs glib gstreamer gtk gtksourceview libgda libglade libgnome libgnomeui pango libgnomecanvas"
188
# 5a. get extra modules (gnome canvas)
190
tla get wingo@pobox.com--2004-main/guile-gnome-$i--release $i
197
if [ ! -f configure ]; then
198
sh autogen.sh --noconfigure
203
#$WGET http://download.gna.org/guile-gnome/releases/guile-gnome-platform-$GGVERSION.tar.gz
204
$WGET ftp://ftp.gnu.org/gnu/guile-gnome/guile-gnome-platform/guile-gnome-platform-$GGVERSION.tar.gz
205
tar xzf $download/guile-gnome-platform-$GGVERSION.tar.gz
206
ln -s guile-gnome-platform-$GGVERSION guile-gnome
211
rm -rf $OPT/guile-gnome
215
# Using libtool < 1.6.0 together with gcc-3.4 may trigger this problem:
217
# If a tag has not been given, and we're using a compiler which is
218
# not one of the ones with which libtool was built, attempt to
219
# infer the compiler from the first word of the command line passed
222
if [ -z "$GCC34" ]; then
223
# Use libtool-1.5.6, gcc-3.{2,3} without -O2,
224
CFLAGS='-O -g' $srcdir/configure --prefix=$OPT/guile-gnome --enable-maintainer-mode
226
# or use gcc-3.4 with libtool-1.6.0
227
CC=$GCC34 $srcdir/configure --prefix=$OPT/guile-gnome --enable-maintainer-mode
229
make all install G_WRAP_MODULE_DIR=$OPT/g-wrap/share/guile/site
230
PKG_CONFIG_PATH=$OPT/guile-gnome/lib/pkgconfig:$PKG_CONFIG_PATH
231
LD_LIBRARY_PATH=$OPT/guile-gnome/lib:$LD_LIBRARY_PATH
232
GUILE_LOAD_PATH=$OPT/guile-gnome/share/guile:$GUILE_LOAD_PATH
236
***********************************************************************
237
Before using with Lily, do
239
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH
240
export GUILE_LOAD_PATH=$GUILE_LOAD_PATH
241
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH
244
# simple test -- fails atm
245
# guile -s ../src/libgnomecanvas/examples/canvas.scm