[Home]GaleInstall

HomePage | RecentChanges | Preferences

For the most part, installing Gale is a matter of building the binaries and getting them in the right places. The exception is the authentication system, which requires a certain amount of finicky setup -- including setuid binaries -- to do its job correctly and securely.

Note that if you just want to use gale to chat, and not run a server, there are easier ways. such as http://yammer.net/ and standalone clients like ginsu

1. Download Gale

Download the latest version from http://download.ofb.net/gale/ and unpack it. It should create a directory named "gale-(version)", where (version) is the version number you downloaded. (We'll refer to this directory as "gale".)

2. Fetch Required Libraries

OpenSSL?
You can get the OpenSSL? library from http://www.openssl.org/. This library is available as a package for many operating system distributions; if you use a package, make sure you also have the "-dev" or "-devel" version that includes the header files.

The Boehm conservative garbage collector
You can get this from http://www.hpl.hp.com/personal/Hans_Boehm/gc/. Install the garbage collector library using the default settings. Make sure you know where to find libgc.a (or libgc.so) and gc.h. Note: Red Hat Linux 7.3 or greater requires GC 6.1 or better.

Ian Jackson's asynchronous DNS library (ADNS)
ADNS is now required for Gale. Get it from http://www.chiark.greenend.org.uk/~ian/adns/. Follow the included directions to configure and install this library. Make sure you know where adns.h and libadns.* are.

Unicode conversion library (iconv)
Gale requires the Unix98 standard iconv(3) functions to perform Unicode character set translation. However, some operating systems do not yet provide this function, or do not provide a sufficiently powerful version. To use Unicode character sets on these systems, you will need to install Bruno Haible's libiconv from http://www.gnu.org/software/libiconv/. The GNU libc 2.1 iconv is broken, but GNU libc 2.2 will work, but may require a patch (see Appendix). Without these functions, Gale will still work, but I/O will be limited to the ASCII character set. (This is perfectly sufficient for many English-speaking users.)

3. Run "configure"

Get ready to run the provided "configure" script. The typical "configure" options (--prefix etc.) apply; run "sh configure --help" for usage information.

Include the appropriate -L and -I flags in the LDFLAGS and CPPFLAGS environment variables (respectively) so "configure" can find libcrypto.a (or libcrypto.so) and the OpenSSL? headers (openssl/evp.h and friends).

Similarly, make sure $LDFLAGS and $CPPFLAGS include the location of libgc.a (or libgc.so) and gc.h, respectively. ADNS, libiconv, and any other required libraries must also be available via these paths.

By default and where supported, Gale will install static and shared libraries, and install binaries linked against shared libraries. You may use --disable-shared or --disable-static to modify this behavior.

Once you've figured out the right options and set the right environment variables, run the script.

4. Run "make" and "make install"

Run "make" in the top-level Gale directory. With luck, this will build everything without incident. If not, now you get to figure out what went wrong and why; enjoy! Feel free to contact me (egnor-gale at ofb.net) with questions and patches. Many architectures are currently unsupported, but the changes are typically not too painful.

Then become a user (eg. "root") which has permission to write (and create, if necessary) the install directories (/usr/local/..., unless you specified otherwise). Run "make install" from the top-level "gale" directory; this should install the Gale binaries, libraries, and header files.

Make sure the installed binaries are on the PATH for future steps!

5. Run "gale-install"

Fifth, run the "gale-install" script that was installed by "make install". This may ask questions if it can't find a previous configuration. Feel free to interrupt and re-start it at any point.

Finally, if you have not already set up your domain, you need to do so. Become the "gale user" selected in the last step and run "gale-install" again. Follow the directions; these will involve sending your key to the proper authority to get it signed. I manage ROOT and most "top-level" domains (.edu, .com, .org, .nu, .ml.org, etc.) for now. When in doubt, ask me.

6. When you get the signed key back

Re-run "gale-install" as the gale user. It will ask you for the file containing the signed key. It will then take that and install it in the correct place for you and complete the setup.

Happy Puffing!

Enjoy your new installation. If you have any problems, feel free to send e-mail to egnor-gale at ofb.net.

Appendix: Patch to use glibc iconv

The stock source code assumes iconv is in its own library, and furthermore that unsigned -> signed assignment doesn't generate a warning. This patch will let you use iconv with modern glibcs and gccs.

--- gale-0.99fruit-orig/configure       2004-02-19 21:13:59.000000000 +0000
+++ gale-0.99fruit/configure    2006-11-29 21:56:15.582370000 +0000
@@ -7747,7 +7747,6 @@
 echo $ECHO_N "checking for working iconv... $ECHO_C" >&6
 save_libs="$LIBS"
 save_flags="$CFLAGS"
-LIBS="$LIBS -liconv"
 CFLAGS="$error_flags $save_flags -DICONV_CONST="
 if test "$cross_compiling" = yes; then
   echo "$as_me:$LINENO: result: unknown, assuming no" >&5
--- gale-0.99fruit-orig/iconvtest.c     2000-11-18 06:38:47.000000000 +0000
+++ gale-0.99fruit/iconvtest.c  2006-11-29 21:53:05.945193000 +0000
@@ -27,7 +27,7 @@
     ||  utf[0] != 0x7f 
     ||  utf[1] != 0xdf || utf[2] != 0xbf
     ||  utf[3] != 0xef || utf[4] != 0xbf || utf[5] != 0xbf) exit(1);
-    inbuf = utf; inbytes = 6;
+    inbuf = (char *) utf; inbytes = 6;
     outbuf = (char *) wch; outbytes = sizeof(wch);
     if (0 != iconv(from,&inbuf,&inbytes,&outbuf,&outbytes)
     ||  0 != inbytes || (sizeof(wch) - 3*sizeof(wchar_t)) != outbytes

NOTES

Note that it may be necessary to add "-ldl" to the LDFLAGS environment variable when running "configure" on the main gale source, in order to overcome an apparent bug.

The RPMs at http://www.slackers.net/gale/ will work on Redhat 7.3, but not 9.0 (as of 11 Nov 2003). Redhat 9.0 users should upgrade to at least GC 6.2.

I recently compiled from source using the above instructions, and found them incomplete, so below is a detailed description of what I did. This is not the only way to do so, and may not even be the best way.

-- Beland

I got these files:

 gale.tar.gz 
  from http://gale.org/download
 gc6.2.tar.gz
  from http://www.hpl.hp.com/personal/Hans_Boehm/gc/gc_source/
 openssl-devel-0.9.7a-20.i386.rpm
  from the Redhat distribution (see http://rpmfind.net/)
 adns-0.9-2.i686.rpm
  from http://www.slackers.net/gale/
 (I did not bother with iconv)

I installed the relevant RPMs with:

 rpm -Uvh openssl-devel-0.9.7a-20.i386.rpm
 rpm -Uvh adns-0.9-2.i686.rpm

In the directory I downloaded gale.tar.gz and gc6.2.tar.gz, I ran the following commands:

 gtar -xzvf gale.tar.gz
 gtar -xzvf gc6.2.tar.gz

 cd gc6.2/
 ./configure --prefix=/usr/local/gc
 make
 ("su" to become root)
 make install
 (add the line "/usr/local/gc/lib" to /etc/ld.so.conf)
 ("exit" to become a normal user again)

This makes, among other files:

 /usr/local/gc/lib/libgc.a
 /usr/local/gc/include/gc.h

Then I ran these commands:

 cd ../gale-0.99fruit/
 setenv LDFLAGS "-ldl -L/usr/local/gc/lib"
 setenv CPPFLAGS -I/usr/local/gc/include
 (run "tcsh" if the above 2 lines don't work)
 ./configure --prefix=/usr/local/gale
 make
 ("su" to become root)
 make install

Now all the Gale binaries are in /usr/local/gale/bin/, so I do the following before running anything (easy enough to put in my .cshrc):

 setenv PATH `printenv PATH`:/usr/local/gale/bin

Be sure to run:

 /usr/local/gale/bin/gale-install

HomePage | RecentChanges | Preferences
This page is read-only | View other revisions
Last edited November 29, 2006 14:36 by ofb.net (diff)
Search: