unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* Compiling guile-1.8.5 on a recent Cygwin with libtool 2.2.6
@ 2008-11-21  8:16 Mike Gran
  2008-11-24 23:13 ` Ludovic Courtès
  0 siblings, 1 reply; 5+ messages in thread
From: Mike Gran @ 2008-11-21  8:16 UTC (permalink / raw)
  To: Guile User

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

Since cygwin has pushed up its libtool to 2.2.6 and Guile uses libtool 1.5.x, this mismatch can cause a compilation failure.

To work around this, you can try the following

I have attached 5 small patches configure.in.patch, Makefile.am.patch, guile.c.patch, srfi-14.c.patch and posix.c.patch.

The first three do the upgrade to libtool 2.2.6.  The last two fix totally harmless pedantic errors that could safely be ignored were it not for the -Werror.

$ tar xzvf guile-1.8.5.tar.gz
$ cd guile-1.8.5
$ cp ../Makefile.am.patch ../configure.in.patch .
$ patch < Makefile.am.patch
$ patch < configure.in.patch
$ cd libguile
$ cp ../../srfi-14.c.patch ../../posix.c.patch ../../guile.c.patch .
$ patch < srfi-14.c.patch 
$ patch < posix.c.patch
$ patch < guile.c.patch
$ cd ..
$ libtoolize
$ aclocal
$ autoconf
$ ./configure && make

The shell scripts that call the standalone tests in "make check" hang for some reason.  Also, you still get the "freeze on ^D in the REPL" bug that has been a longstanding cygwin mis-feature.

Thanks,

Mike Gran

[-- Attachment #2: configure.in.patch --]
[-- Type: application/octet-stream, Size: 464 bytes --]

--- configure.in	2008-05-07 10:51:15.000000000 -0700
+++ configure.in	2008-11-20 20:40:14.546875000 -0800
@@ -64,7 +64,6 @@
 
 dnl Some more checks for Win32
 AC_CYGWIN
-AC_LIBTOOL_WIN32_DLL
 
 AC_PROG_INSTALL
 AC_PROG_CC
@@ -79,8 +78,7 @@
 # for per-target cflags in the libguile subdir
 AM_PROG_CC_C_O
 
-AC_LIBTOOL_DLOPEN
-AC_PROG_LIBTOOL
+LT_INIT([dlopen win32-dll])
 AC_CHECK_LIB([ltdl], [lt_dlinit], ,
   [AC_MSG_ERROR([libltdl not found.  See README.])])
 

[-- Attachment #3: guile.c.patch --]
[-- Type: application/octet-stream, Size: 444 bytes --]

--- guile.c	2008-04-07 14:30:03.000000000 -0700
+++ guile.c	2008-11-20 23:37:01.203125000 -0800
@@ -68,8 +68,7 @@
 {
 #if !defined (__MINGW32__)
   /* libtool automagically inserts this variable into your executable... */
-  extern const lt_dlsymlist lt_preloaded_symbols[];
-  lt_dlpreload_default (lt_preloaded_symbols);
+  LTDL_SET_PRELOADED_SYMBOLS();
 #endif
   scm_boot_guile (argc, argv, inner_main, 0);
   return 0; /* never reached */

[-- Attachment #4: Makefile.am.patch --]
[-- Type: application/octet-stream, Size: 261 bytes --]

--- Makefile.am	2008-05-04 14:39:47.000000000 -0700
+++ Makefile.am	2008-11-20 23:41:02.531250000 -0800
@@ -35,7 +35,7 @@
 
 TESTS = check-guile
 
-ACLOCAL_AMFLAGS = -I guile-config
+ACLOCAL_AMFLAGS = -I m4 -I guile-config
 
 DISTCLEANFILES = check-guile.log
 

[-- Attachment #5: posix.c.patch --]
[-- Type: application/octet-stream, Size: 270 bytes --]

--- posix.c	2008-05-04 14:39:48.000000000 -0700
+++ posix.c	2008-11-20 21:01:26.234375000 -0800
@@ -22,7 +22,9 @@
 #endif
 
 /* Make GNU/Linux libc declare everything it has. */
+#ifndef _GNU_SOURCE
 #define _GNU_SOURCE
+#endif
 
 #include <stdio.h>
 #include <errno.h>

[-- Attachment #6: srfi-14.c.patch --]
[-- Type: application/octet-stream, Size: 276 bytes --]

--- srfi-14.c	2008-05-04 14:39:48.000000000 -0700
+++ srfi-14.c	2008-11-20 21:00:49.453125000 -0800
@@ -21,8 +21,9 @@
 #  include <config.h>
 #endif
 
-
+#ifndef _GNU_SOURCE
 #define _GNU_SOURCE  /* Ask for `isblank ()'.  */
+#endif
 
 #include <string.h>
 #include <ctype.h>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Compiling guile-1.8.5 on a recent Cygwin with libtool 2.2.6
  2008-11-21  8:16 Compiling guile-1.8.5 on a recent Cygwin with libtool 2.2.6 Mike Gran
@ 2008-11-24 23:13 ` Ludovic Courtès
  2008-11-25  3:47   ` Mike Gran
  2008-11-30 18:54   ` Ludovic Courtès
  0 siblings, 2 replies; 5+ messages in thread
From: Ludovic Courtès @ 2008-11-24 23:13 UTC (permalink / raw)
  To: guile-user

Hi Mike,

Mike Gran <spk121@yahoo.com> writes:

> Since cygwin has pushed up its libtool to 2.2.6 and Guile uses libtool
> 1.5.x, this mismatch can cause a compilation failure.
>
> To work around this, you can try the following
>
> I have attached 5 small patches configure.in.patch, Makefile.am.patch,
> guile.c.patch, srfi-14.c.patch and posix.c.patch.

Thanks for the patches!  I've started looking into this.  The
`srfi-14.c' and `posix.c' patches are no longer needed; the `guile.c'
patch has been in the pipeline for some time; the `configure.in' patch
appears to be required, despite the fact that Libtool is supposed to
honor the now-deprecated macros that we used; the `Makefile.am'
shouldn't be needed, at list not in HEAD from what I've seen.

Ludo'.





^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Compiling guile-1.8.5 on a recent Cygwin with libtool 2.2.6
  2008-11-24 23:13 ` Ludovic Courtès
@ 2008-11-25  3:47   ` Mike Gran
  2008-11-29 21:14     ` Julian Graham
  2008-11-30 18:54   ` Ludovic Courtès
  1 sibling, 1 reply; 5+ messages in thread
From: Mike Gran @ 2008-11-25  3:47 UTC (permalink / raw)
  To: guile-user

Ludo'

> Thanks for the patches!  I've started looking into this.  The
> `srfi-14.c' and `posix.c' patches are no longer needed; the `guile.c'
> patch has been in the pipeline for some time; the `configure.in' patch
> appears to be required, despite the fact that Libtool is supposed to
> honor the now-deprecated macros that we used; the `Makefile.am'
> shouldn't be needed, at list not in HEAD from what I've seen.

It is true that the Makefile.am patch is unnecessary, except to quiet a warning given by libtoolize.  IIRC, newer versions of automake will know to scan configure.[in|ac] for m4 subdirectories, but, older versions of automake do not.  Yet, there are probably no systems with old automake and new libtool.

-Mike




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Compiling guile-1.8.5 on a recent Cygwin with libtool 2.2.6
  2008-11-25  3:47   ` Mike Gran
@ 2008-11-29 21:14     ` Julian Graham
  0 siblings, 0 replies; 5+ messages in thread
From: Julian Graham @ 2008-11-29 21:14 UTC (permalink / raw)
  To: Mike Gran, Guile User

> It is true that the Makefile.am patch is unnecessary, except to quiet a warning given by libtoolize.  IIRC, newer versions of automake will know to scan configure.[in|ac] for m4 subdirectories, but, older versions of automake do not.  Yet, there are probably no systems with old automake and new libtool.


Actually, I'm unable to get autogen.sh to complete in HEAD unless I
append "-I m4" to ACLOCAL_AMFLAGS as in the patch (and remove
"AC_CONFIG_MACRO_DIR([m4])" from configure.in).  WIthout doing that, I
get:

  libtoolize: AC_CONFIG_MACRO_DIR([m4]) conflicts with
ACLOCAL_AMFLAGS=-I guile-config.
  autoreconf: libtoolize failed with exit status: 1

In case it matters, I'm using Autoconf 2.61, Automake 1.10.1, and
Libtool 2.2.4, as part of Ubuntu 8.10.




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Compiling guile-1.8.5 on a recent Cygwin with libtool 2.2.6
  2008-11-24 23:13 ` Ludovic Courtès
  2008-11-25  3:47   ` Mike Gran
@ 2008-11-30 18:54   ` Ludovic Courtès
  1 sibling, 0 replies; 5+ messages in thread
From: Ludovic Courtès @ 2008-11-30 18:54 UTC (permalink / raw)
  To: guile-user

Hello,

ludo@gnu.org (Ludovic Courtès) writes:

> Thanks for the patches!  I've started looking into this.  The
> `srfi-14.c' and `posix.c' patches are no longer needed; the `guile.c'
> patch has been in the pipeline for some time; the `configure.in' patch
> appears to be required, despite the fact that Libtool is supposed to
> honor the now-deprecated macros that we used; the `Makefile.am'
> shouldn't be needed, at list not in HEAD from what I've seen.

Actually, the `configure.in' patch to use `LT_INIT' wasn't even needed,
so the only changes were:

  http://git.savannah.gnu.org/gitweb/?p=guile.git;a=commit;h=664d1f5eb211d0ffd65f227e65d1fc02ef1bc8c0
  http://git.savannah.gnu.org/gitweb/?p=guile.git;a=commit;h=0328bf6a0e42c0c04908fb24c5f7d0c8d5133ea3

This has the nice property that both 1.5.x and 2.2.x will work.  The
1.8.6 release will come with 2.2.x, though, which will make people's
lives easier.

BTW, 2.2.x is faster, which is nice!

Thanks,
Ludo'.





^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2008-11-30 18:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-21  8:16 Compiling guile-1.8.5 on a recent Cygwin with libtool 2.2.6 Mike Gran
2008-11-24 23:13 ` Ludovic Courtès
2008-11-25  3:47   ` Mike Gran
2008-11-29 21:14     ` Julian Graham
2008-11-30 18:54   ` Ludovic Courtès

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).