guile-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: native Win32 guile 1.7.0


From: stefan
Subject: Re: native Win32 guile 1.7.0
Date: Fri, 30 May 2003 05:23:15 +0200 (CEST)

On Fri, 30 May 2003, Kevin Ryde wrote:

> stefan <address@hidden> writes:
> >
> >       * posix.c (s_scm_putenv): Disable use of unsetenv() for the
> >       mingw32 build.
> >
> > #ifndef __MINGW32__
>
> It'd be good autoconf style to test unsetenv with AC_CHECK_FUNCS if
> it's not always available.  In particular that way it gets used if
> added to mingw in the future.
>
> Perhaps environ could be munged directly if unsetenv doesn't exist.
> Might end up being a memory leak.  Probably not ideal to silently do
> nothing.

I can remember that on Win32 an environment variable can be unset via
putenv somehow... I'll investigate that.

> >       * mkstemp.c: Provide prototype to avoid compiler warning.
>
> It's usually best to just omit prototypes if they're not in a standard
> header, and the return value is only an int.  It's all too easy to end
> up with a conflict on some obscure system.  AC_CHECK_DECLS is the way
> to go if you really want a declaration.

In fact there is no mkstemp() on Win32.  Basically the mkstemp.o gets
added to the list of objects when there is no in the libc.  That is why I
think the prototype can be written there (same as with inet_aton).

> >       * configure.in: Removed -lm check
> >
> > if test $MINGW32 = no; then
> >         AC_CHECK_LIB(m, main)
> > fi
>
> Doesn't it simply find -lm doesn't exist and continue?  If there has
> to be a hard system dependency, autoconf deprecates $MINGW32 in favour
> of "case $host in *-*-mingw*)" etc.
>
> Libtool has an AC_CHECK_LIBM which knows about a few systems.  We use
> it in gmp, not actually documented though.

The -lm is found but not used for anything.  When -lm is on the linker
line libtool would fail to create a dll, that is why I removed it for
mingw32.

Cheers,
        address@hidden





reply via email to

[Prev in Thread] Current Thread [Next in Thread]