octave-maintainers
[Top][All Lists]
Advanced

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

Re: link error of liboctave (MinGW build)


From: Tatsuro MATSUOKA
Subject: Re: link error of liboctave (MinGW build)
Date: Fri, 8 Jan 2010 10:08:43 +0900 (JST)

Hello

With your patch for ..../gnulib/lib/glob.in.h  and updated wctype.in.h in 
gnulib repository, a compile
error related to wctype.h and a link error in liboctave.dll linking related 
glob.h were disappeared.

The remaining error at present is that related 'getlogin'.

I will try the code you mentioned in the gnulib ML as a temporal trial. 

http://gcc.gnu.org/viewcvs/trunk/libgfortran/intrinsics/getlog.c?view=markup
in
http://old.nabble.com/getlogin-on-Windows-systems-to27055535.html 

Thanks!

Tatsuro
 
 

--- "John W. Eaton"  wrote:

> On  7-Jan-2010, John W. Eaton wrote:
> 
> | On  7-Jan-2010, Tatsuro MATSUOKA wrote:
> | 
> | | I add a 'extern "C" {} block' in glob.h in libgnu generated in build tree 
> and confirmed that
>  
> | | errors which came from glob were disappeared as,
> | 
> | Can you please send me a copy of the generated libgnu/glob.h file from
> | your build tree?  I need to see precisely what is in that file before
> | I can try to come up with the correct gnulib-ish way to insert an
> | extern "C" block, or at least ask the gnulib maintainers what the
> | best way to do that is.
> 
> Never mind.  Just after hitting send, I saw the light.  I think the
> correct fix is to defined __BEGIN_DECLS __END_DECLS in glob.in.h as in
> the attached patch.
> 
> jwe
> 
> > From 1641dbca79baee5b57a3bc691f2050d3da6dd135 Mon Sep 17 00:00:00 2001
> From: John W. Eaton <address@hidden>
> Date: Thu, 7 Jan 2010 13:08:33 -0500
> Subject: [PATCH] glob.in.h: define __BEGIN_DECLS and __END_DECLS for C++
> 
> ---
>  ChangeLog     |    5 +++++
>  lib/glob.in.h |    9 +++++++--
>  2 files changed, 12 insertions(+), 2 deletions(-)
> 
> diff --git a/ChangeLog b/ChangeLog
> index edd55bf..994e8a5 100644
> --- a/ChangeLog
> +++ b/ChangeLog
> @@ -1,5 +1,10 @@
>  2010-01-07  John W. Eaton  <address@hidden>
>  
> +     * lib/glob.in.h [__cplusplus]: Define __BEGIN_DECLS and
> +     __END_DECLS for C++.
> +
> +2010-01-07  John W. Eaton  <address@hidden>
> +
>       * lib/wctype.in.h: Add extern "C" block for C++.
>  
>  2010-01-06  Eric Blake  <address@hidden>
> diff --git a/lib/glob.in.h b/lib/glob.in.h
> index 562f1c5..8f32a79 100644
> --- a/lib/glob.in.h
> +++ b/lib/glob.in.h
> @@ -33,8 +33,13 @@
>  #include <sys/stat.h>
>  
>  #ifndef __BEGIN_DECLS
> -# define __BEGIN_DECLS
> -# define __END_DECLS
> +# ifdef __cplusplus
> +#  define __BEGIN_DECLS  extern "C" {
> +#  define __END_DECLS    }
> +# else
> +#  define __BEGIN_DECLS
> +#  define __END_DECLS
> +# endif
>  #endif
>  #ifndef __THROW
>  # define __THROW
> -- 
> 1.6.5
> 
> 


--------------------------------------
Get the new Internet Explorer 8 optimized for Yahoo! JAPAN
http://pr.mail.yahoo.co.jp/ie8/


reply via email to

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