unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
* 1.6.3: libltdl troubles with error_t
@ 2003-02-27 17:42 Greg Troxel
  0 siblings, 0 replies; only message in thread
From: Greg Troxel @ 2003-02-27 17:42 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 2130 bytes --]

I have 1.6.3 imported into CVS, and am building it on NetBSD 1.6.
Because I modified Makefile.am and configure.in for pkgconfig, I am
running most of what's in autogen.sh from guile CVS, and I removed
Makefile.in/configure/aclocal from my own repo.

libltdl.c failed to build because error_t was not defined.  error_t
seems to be a glibc thing related to 'argz', but I'm not sure.  Newer
libtool versions have checks in ltdl.m4 to #define error_t to int if
it isn't defined.

I lost because NetBSD pkgsrc has an old, patched libtool, and the
ltdl.m4 used to make aclocal.m4 came from the old libtool.  The
central problem is that guile includes ltdl but does not include the
corresponding autoconf macros.

Of course, one can say that NetBSD is broken because it doesn't have
an up-to-date libtool.  But the libtool that comes with NetBSD seems
to be self-consistent and working ok otherwise.

So, I added the new ltdl.m4 to guile-config, and that failed because
it depends on new stuf libtool.m4.  Building with both included got me:

gmake[3]: Entering directory
`/home/gdt/QUIST-current/guile/libguile-ltdl'
source='guile-ltdl.c' object='guile-ltdl.lo' libtool=yes \
depfile='.deps/guile-ltdl.Plo' tmpdepfile='.deps/guile-ltdl.TPlo' \
depmode=gcc /usr/pkg/bin/bash ../depcomp \
/usr/pkg/bin/bash ../libtool --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I.. -I. -I. -I.. -I./..    -I/usr/pkg/include -Wall -Wmissing-prototypes -c -o guile-ltdl.lo `test -f 'guile-ltdl.c' || echo './'`guile-ltdl.c
libtool: ltconfig version `' does not match ltmain.sh version `1.4a'
Fatal configuration error.  See the libtool docs for more information.
gmake[3]: *** [guile-ltdl.lo] Error 1

This is really for libtool, not guile, but when using nonstandard
features like error_t (if indeed it is non-POSIX), it would be good to
conditionalize the source on HAVE_ERROR_T, so that simply declining to
define HAVE_ERROR_T causes the right behavior.  I did this, and
realized there was also a missing test for errno.h

With this patch, i can build 1.6.3 with the older libtool m4 files.
I know it's gross, but I thought it might help someone else.


[-- Attachment #2: libltdl patch --]
[-- Type: text/plain, Size: 573 bytes --]

Index: libguile-ltdl/raw-ltdl.c
===================================================================
RCS file: /QUIST-CVS/guile/libguile-ltdl/raw-ltdl.c,v
retrieving revision 1.1.1.1
diff -u -r1.1.1.1 raw-ltdl.c
--- libguile-ltdl/raw-ltdl.c	2002/12/07 22:41:33	1.1.1.1
+++ libguile-ltdl/raw-ltdl.c	2003/02/27 17:20:37
@@ -86,6 +86,14 @@
 #  include <argz.h>
 #endif
 
+#if HAVE_ERROR_T
+/* empty */
+#else
+/* Probably we were compiled without new enough ltdl.m4 support */
+#define error_t int
+#include <errno.h>
+#endif
+
 #if HAVE_ASSERT_H
 #  include <assert.h>
 #else

[-- Attachment #3: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://mail.gnu.org/mailman/listinfo/guile-devel

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-02-27 17:42 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-02-27 17:42 1.6.3: libltdl troubles with error_t Greg Troxel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).