diff -Naur client-old/ggz-config-fake client-new/ggz-config-fake --- client-old/ggz-config-fake 1969-12-31 19:00:00.000000000 -0500 +++ client-new/ggz-config-fake 2005-06-21 10:30:43.000000000 -0400 @@ -0,0 +1,40 @@ +#!/usr/bin/perl + +use Getopt::Long; +use File::Temp; +use File::Copy; + +my $prefix = shift; +my $pkg = shift; + +unless ( grep { /--install/ } @ARGV ) { + print "Passing through to real ggz-config...\n"; + exec("$prefix/bin/ggz-config", @ARGV); +} + +my $destdir = $ENV{DESTDIR} or die "ERROR: No DESTDIR specified!\n"; + +my $moddir = "$destdir/$prefix/share/ggz/modules/$pkg"; + +my $modfile; +Getopt::Long::Configure qw(bundling pass_through); +GetOptions("modfile=s" => \$modfile); +die "ERROR: No module file specified!\n" unless defined $modfile; + +# Get a name +my $destfile; +open MOD, $modfile; +while () { + if (/^\s*name\s*=\s*(\S+)\s*$/i) { + $destfile = "$moddir/\L$1\E.dsc"; + last; + } +} +close MOD; +die "Can't find a name for this module!\n" unless defined $destfile; +print "WARNING: Module already exists!\n" if -f $destfile; + +print "Installing module file to $destfile\n"; +system("mkdir -p \Q$moddir\E") == 0 + or die "ERROR: Can't create module directory!\n"; +copy($modfile, $destfile) or die "ERROR: Can't copy module file!\n"; diff -Naur client-old/ggzmod/Makefile.in client-new/ggzmod/Makefile.in --- client-old/ggzmod/Makefile.in 2005-05-21 12:24:00.000000000 -0400 +++ client-new/ggzmod/Makefile.in 2005-06-21 10:15:21.000000000 -0400 @@ -215,7 +215,7 @@ include_HEADERS = ggzmod.h libggzmod_la_LIBADD = $(top_builddir)/ggzcore/libggzcore.la $(LIB_GGZ) -libggzmod_la_LDFLAGS = $(LIBGGZ_LDFLAGS) -version-info 3:1:1 +libggzmod_la_LDFLAGS = $(LIBGGZ_LDFLAGS) -version-info 3:1:0 AM_CPPFLAGS = $(LIBGGZ_INCLUDES) -I$(top_srcdir)/ggzcore all: all-am diff -Naur client-old/ggzmod-ggz/ggzmod-ggz.c client-new/ggzmod-ggz/ggzmod-ggz.c --- client-old/ggzmod-ggz/ggzmod-ggz.c 2005-05-07 12:45:01.000000000 -0400 +++ client-new/ggzmod-ggz/ggzmod-ggz.c 2005-06-21 10:15:21.000000000 -0400 @@ -824,7 +824,7 @@ /* FIXME: we need to select, with a maximum timeout. */ /* FIXME: this is insecure; it should be restricted to local * connections. */ - sock2 = accept(sock, NULL, NULL); + sock2 = ggz_accept(sock); if (sock2 < 0) { ggz_error_sys("Listening to socket failed."); return -1; @@ -889,7 +889,7 @@ /* FIXME: we need to select, with a maximum timeout. */ /* FIXME: this is insecure; it should be restricted to local * connections. */ - sock2 = accept(sock, NULL, NULL); + sock2 = ggz_accept(sock); if (sock2 < 0) { ggz_error_sys("Listening to socket failed."); return -1;