# I include two versions of Guile below. 2.2.x is the legacy series and
# 2.0.x is ... older than that.
# I use --disable-nls below because I only read & write English (well).
# If that is not the case for you, leave that off (and update gettext).
# If you ever want to uninstall Guile, skip down to the bottom for
# instructions. If you go from version 2.0.x to 2.2.x, you may want to
# follow these instructions to ensure that 2.0.x's files are gone.
## If you run configure and you get this:
# configure: error: No iconv support. Please recompile libunistring with
# iconv enabled.
## You may need to recompile and reinstall libunistring...
## If libunistring's configure says iconv is there but does not work,
## you can either fix libunistring's configure tests, or fix glibc's iconv,
## or install libiconv in the /usr/local prefix, then
## let libunistring use that, or maybe do something potentially
## stupid - change libunistring's config.h to define HAVE_ICONV and
## see how that goes. (I did not do that)
## You could also install the Slackware-current package for libunistring
## depending on how old your running Slackware is...
# Get the tarball
cd
test -f installed/guile-3.0.9.tar.lz && mv installed/guile-3.0.9.tar.lz .
test ! -f guile-3.0.9.tar.lz &&
wget https://ftpmirror.gnu.org/gnu/guile/guile-3.0.9.tar.lz
# Verify tarball w/ sha256sum:
#
# It was provided in the announcement as base64 encoded binary instead of
# hex so some extra steps are required to get the same output:
#
# vA7go2D7E5GcFOtuJFMxmt8eyZgojJk4KbzxePtIzJo=
# ->
# sha256sum guile-3.0.9.tar.lz | xxd -r -p | base64
# -or-
# openssl sha256 -binary guile-3.0.9.tar.lz | openssl base64
# ->
echo "bc0ee0a360fb13919c14eb6e2453319adf1ec998288c993829bcf178fb48cc\
9a guile-3.0.9.tar.lz" | sha256sum -c
# Extract the source
mkdir -p -m 0700 ~/src
cd ~/src
find -maxdepth 1 -type d -name "guile-3.0.*" -exec rm -r {} \;
tar xvf ~/guile-3.0.9.tar.lz
cd guile-3.0.9
test $UID = 0 && chown -R root:root .
# Configure the build for 64-bit
test $(uname -m) = 'x86_64' &&
./configure --prefix=/usr --infodir=/usr/info \
--libdir=/usr/lib64 --mandir=/usr/man --disable-static --disable-nls
# Configure the build for anything else
test $(uname -m) = 'x86_64' &&
./configure --prefix=/usr --infodir=/usr/info --mandir=/usr/man \
--disable-static --disable-nls
# Build it
make
# Become root to install it
su
# Remove the Slackware package, if there is one
test -x /sbin/removepkg && /sbin/removepkg guile
## If you are upgrading from a previous version of Guile and are 100%
## sure leftover files are not needed, here are some places you might
## find some extras. To remove _everything_, skip down to the bottom.
# /usr/include/guile/
# /usr/lib*/guile/
# /usr/lib*/pkgconfig/guile-3.0.pc
# /usr/lib*/libguile*
# /usr/share/guile/
# Remove library files from old versions, if you are sure they are no longer
# needed by software that may be linked to them
for libdir in /usr/lib /usr/lib64;
do
test -d $libdir &&
( cd $libdir
rm -f libguile-3.0.* libguile-2.* libguile-ltdl.* libguile-srfi* \
libguilereadline-* )
done
# Install it
make install
# Move this to avoid ldconfig complaints
test $(uname -m) = 'x86_64' &&
mv -f /usr/lib64/libguile-3.0.so.1.6.0-gdb.scm \
/usr/share/gdb/auto-load/usr/lib64/
test $(uname -m) != 'x86_64' &&
mv -f /usr/lib/libguile-3.0.so.1.6.0-gdb.scm \
/usr/share/gdb/auto-load/usr/lib/
# Update /etc/ld.so.cache
ldconfig
# Make sure your non-root account can remove the source later
chown -R $(logname) .
chmod -R u+w .
# Become yourself again
exit
# Keep the source for later
cd
mkdir -p -m 0700 installed
rm -f installed/guile-2.2.*.tar.*
mv guile-3.0.9.tar.lz installed/
# Get the tarball
cd
test -f installed/guile-2.2.7.tar.lz && mv installed/guile-2.2.7.tar.lz .
test ! -f guile-2.2.7.tar.lz &&
wget https://ftpmirror.gnu.org/gnu/guile/guile-2.2.7.tar.lz
# Extract the source
mkdir -p -m 0700 ~/src
cd ~/src
find -maxdepth 1 -type d -name "guile-2.2.*" -exec rm -r {} \;
tar xvf ~/guile-2.2.7.tar.lz
cd guile-2.2.7
test $UID = 0 && chown -R root:root .
# Configure the build for 64-bit
test $(uname -m) = 'x86_64' &&
./configure --prefix=/usr --infodir=/usr/info \
--libdir=/usr/lib64 --mandir=/usr/man --disable-static --disable-nls
# Configure the build for anything else
test $(uname -m) = 'x86_64' &&
./configure --prefix=/usr --infodir=/usr/info --mandir=/usr/man \
--disable-static --disable-nls
# Build it
make
# Become root to install it
su
# Remove the Slackware package, if there is one
test -x /sbin/removepkg && /sbin/removepkg guile
## If you are upgrading from a previous version of Guile and are 100%
## sure leftover files are not needed, here are some places you might
## find some extras. To remove _everything_, skip down to the bottom.
# /usr/include/guile/
# /usr/lib*/guile/
# /usr/lib*/pkgconfig/guile-3.0.pc
# /usr/lib*/libguile*
# /usr/share/guile/
# Remove library files from old versions, if you are sure they are no longer
# needed by software that may be linked to them
for libdir in /usr/lib /usr/lib64;
do
test -d $libdir &&
( cd $libdir
rm -f libguile.* libguile-2.* libguile-ltdl.* libguile-srfi* \
libguilereadline-* )
done
# Install it
make install
# Move this to avoid ldconfig complaints
test $(uname -m) = 'x86_64' &&
mv -f /usr/lib64/libguile-2.2.so.1.4.2-gdb.scm \
/usr/share/gdb/auto-load/usr/lib64/
test $(uname -m) != 'x86_64' &&
mv -f /usr/lib/libguile-2.2.so.1.4.2-gdb.scm \
/usr/share/gdb/auto-load/usr/lib/
# Update /etc/ld.so.cache
ldconfig
# Make sure your non-root account can remove the source later
chown -R $(logname) .
chmod -R u+w .
# Become yourself again
exit
# Keep the source for later
cd
mkdir -p -m 0700 installed
rm -f installed/guile-2.2.*.tar.*
mv guile-2.2.7.tar.lz installed/
# Get it
cd
test -f installed/guile-2.0.14.tar.xz && mv installed/guile-2.0.14.tar.xz .
test ! -f guile-2.0.14.tar.xz &&
wget http://ftpmirror.gnu.org/gnu/guile/guile-2.0.14.tar.xz
# Extract the source
mkdir -p -m 0700 ~/src
cd ~/src
find -maxdepth 1 -type d -name "guile-*" -exec rm -r {} \;
tar xJvf ~/guile-2.0.14.tar.xz
cd guile-2.0.14
test $UID = 0 && chown -R root:root .
# Configure the build for 64-bit
test $(uname -m) = 'x86_64' &&
./configure --prefix=/usr --infodir=/usr/info \
--libdir=/usr/lib64 --mandir=/usr/man --disable-static --disable-nls \
--disable-error-on-warning
# Configure the build for anything else
test $(uname -m) = 'x86_64' &&
./configure --prefix=/usr --infodir=/usr/info --mandir=/usr/man \
--disable-static --disable-nls --disable-error-on-warning
# Build it
make
# Become root to install it
su
# You may want to copy /usr/lib*/libguile* somewhere just in case
# (see below)
# Remove the Slackware package, if there is one
test -x /sbin/removepkg && /sbin/removepkg guile
# If you did remove the Slackware package, you may have a /usr/share/guile
# but may want to keep the files in there
# Remove library files from old versions, if you are sure they are no longer
# needed by software that may be linked to them
for libdir in /usr/lib /usr/lib64;
do
test -d $libdir &&
( cd $libdir
rm -f libguile.* libguile-2.* libguile-ltdl.* libguile-srfi* \
libguilereadline-* )
done
## NOTE: 'make' itself may be linked with libguile, so if you
## run it after running 'removepkg' above and it says it can't
## find libguile-2.0.so.22 or something like that, copy the one
## you just compiled as a Band-aid:
# cp -a libguile/.libs/libguile-2.0.so.22.8.1 /usr/lib64/
# ln -s /usr/lib64/libguile-2.0.so.22.8.1 /usr/lib64/libguile-2.0.so.22
# ldconfig
# Install it
make install
# Move this to avoid ldconfig complaints
test $(uname -m) = 'x86_64' &&
mv -f /usr/lib64/libguile-2.0.so.22.8.1-gdb.scm \
/usr/share/gdb/auto-load/usr/lib64/
test $(uname -m) != 'x86_64' &&
mv -f /usr/lib/libguile-2.0.so.22.8.1-gdb.scm \
/usr/share/gdb/auto-load/usr/lib/
# Update /etc/ld.so.cache
ldconfig
# Make sure your non-root account can remove the source later
chown -R $(logname) .
chmod -R u+w .
# Become yourself again
exit
# Keep the source for later
cd
mkdir -p -m 0700 installed
rm -f installed/guile-*.tar.*
mv guile-2.0.14.tar.xz installed/
# If you ever want to uninstall Guile, this should do it:
cd
su
test -d src/guile-* && ( cd src/guile-* ; make uninstall )
( cd /usr/bin
rm -f guild guile guile-config guile-snarf guile-tools )
test -d /usr/include/guile && rm -r /usr/include/guile
test -d /usr/include/guile-readline && rm -r /usr/include/guile-readline
test -d /usr/include/libguile && rm -r /usr/include/libguile
( cd /usr/info ; rm -f goops.info guile.info guile-tut.info r5rs.info )
( cd /usr/lib ; rm -f libguile.* libguile-ltdl.* libguile-srfi* \
libguileopts.* libguilereadline-v-* )
test -d /usr/lib64 &&
( cd /usr/lib64
test -d ./guile && rm -r ./guile
rm -f libguile-* libguilereadline-* )
test -d /usr/share/guile && rm -r /usr/share/guile
rm -f /usr/include/libguile.h /usr/lib*/pkgconfig/guile-*.pc \
/usr/man/man1/guile.1 /usr/share/man/man1/guile.1 \
/usr/share/aclocal/guile.m4
ldconfig
exit
find ~/src -maxdepth 1 -type d -name "guile-*" -exec rm -r {} \;
rm -f ~/installed/guile-*.tar.*