public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* cygwin-1.7.28 getpwent header declaration changes ?
@ 2014-02-06  7:29 Marco Atzeri
  2014-02-06  9:01 ` Corinna Vinschen
  0 siblings, 1 reply; 69+ messages in thread
From: Marco Atzeri @ 2014-02-06  7:29 UTC (permalink / raw)
  To: cygwin

on cygwin-1.7.28 64 bit but not on cygwin-1.7.27,
(only system difference) compiling octave I see:

----------------------------------------------------------------
/pub/devel/octave/octave-3.8.0-2/src/octave-3.8.0/liboctave/system/oct-passwd.cc
:114:25: error: '::getpwent' has not been declared
    return octave_passwd (::getpwent (), msg);
                          ^
/pub/devel/octave/octave-3.8.0-2/src/octave-3.8.0/liboctave/system/oct-passwd.cc
: In static member function 'static int 
octave_passwd::setpwent(std::string&)':
/pub/devel/octave/octave-3.8.0-2/src/octave-3.8.0/liboctave/system/oct-passwd.cc
:171:3: error: '::setpwent' has not been declared
    ::setpwent ();
    ^
/pub/devel/octave/octave-3.8.0-2/src/octave-3.8.0/liboctave/system/oct-passwd.cc
: In static member function 'static int 
octave_passwd::endpwent(std::string&)':
/pub/devel/octave/octave-3.8.0-2/src/octave-3.8.0/liboctave/system/oct-passwd.cc
:191:3: error: '::endpwent' has not been declared
    ::endpwent ();
    ^
/pub/devel/octave/octave-3.8.0-2/src/octave-3.8.0/liboctave/system/oct-passwd.cc
: In static member function 'static octave_passwd 
octave_passwd::getpwent(std::s
tring&)':
/pub/devel/octave/octave-3.8.0-2/src/octave-3.8.0/liboctave/system/oct-passwd.cc
:119:1: warning: control reaches end of non-void function [-Wreturn-type]
  }
  ^
Makefile:8702: recipe for target 
'system/system_libsystem_la-oct-passwd.lo' fail
ed
make[4]: *** [system/system_libsystem_la-oct-passwd.lo] Error 1

----------------------------------------------------------------

the piece of code is a very simple:
-----------------------------------------------
octave_passwd
octave_passwd::getpwent (std::string& msg)
{
#if defined HAVE_GETPWENT
   msg = std::string ();
   return octave_passwd (::getpwent (), msg);
#else
   msg = NOT_SUPPORTED ("getpwent");
   return octave_passwd ();
#endif
}

----------------------------------------

Is something slightly changed in the  relative system headers ?

Regards
Marco


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 69+ messages in thread
* Re: cygwin-1.7.28 getpwent header declaration changes ?
@ 2014-02-07  9:27 Jan Nijtmans
  2014-02-07  9:29 ` Corinna Vinschen
  0 siblings, 1 reply; 69+ messages in thread
From: Jan Nijtmans @ 2014-02-07  9:27 UTC (permalink / raw)
  To: cygwin

2014-02-06 15:41 GMT+01:00 Corinna Vinschen:
> Jan, can you please check if SQlite builds *without* defining
> __BSD_VISIBLE, but adding the following lines to /usr/include/sys/file.h;

That addition makes SQLite build fine again. You can try it easily
by installing the "sqlite3-debug" package and then:

    gcc -c /usr/src/debug/sqlite3-3.8.3-2/sqlite3.c

If this command produces an "sqlite3.o" file in the
current directory without complaining, everything is OK.
(The current sqlite3-3.8.3-2 package doesn't set
__BSD_VISIBLE, and with your proposed change
it won't be necessary to add it)

Thank you very much!

Regards,
       Jan Nijtmans

> Index: sys/file.h
> ===================================================================
> RCS file: /cvs/src/src/winsup/cygwin/include/sys/file.h,v
> retrieving revision 1.8
> diff -u -p -r1.8 file.h
> --- sys/file.h  17 Jan 2014 11:01:46 -0000      1.8
> +++ sys/file.h  6 Feb 2014 14:41:23 -0000
> @@ -31,4 +31,16 @@
>  #define L_INCR         SEEK_CUR
>  #define L_XTND         SEEK_END
>
> +/* Including <sys/file.h> always defines flock & macros. */
> +#if __BSD_VISIBLE - 0  == 0
> +
> +#define LOCK_SH                0x01            /* shared file lock */
> +#define LOCK_EX                0x02            /* exclusive file lock */
> +#define LOCK_NB                0x04            /* don't block when locking */
> +#define LOCK_UN                0x08            /* unlock file */
> +
> +extern int flock _PARAMS ((int, int));
> +
> +#endif
> +
>  #endif

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

end of thread, other threads:[~2014-02-14  9:45 UTC | newest]

Thread overview: 69+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-06  7:29 cygwin-1.7.28 getpwent header declaration changes ? Marco Atzeri
2014-02-06  9:01 ` Corinna Vinschen
2014-02-06 10:20   ` Marco Atzeri
2014-02-06 13:00     ` Jan Nijtmans
2014-02-06 14:02       ` Corinna Vinschen
     [not found]         ` <CAO1jNws3H_Wbec=y_UoYkhrb5nMX7iT7_A5XaHcQKCw32o055g@mail.gmail.com>
2014-02-06 14:15           ` Fwd: " Jan Nijtmans
2014-02-06 14:28             ` Corinna Vinschen
2014-02-06 14:41               ` Corinna Vinschen
2014-02-06 14:13     ` Corinna Vinschen
2014-02-06 21:43       ` get rid of getpwent? (Was: cygwin-1.7.28 getpwent header declaration changes ?) Warren Young
2014-02-07  9:49         ` Corinna Vinschen
2014-02-07 12:50           ` Andrey Repin
2014-02-07 17:26             ` Warren Young
2014-02-07 18:20               ` Andrey Repin
2014-02-07 13:53           ` David Stacey
2014-02-07 17:51             ` Warren Young
2014-02-07 19:21               ` Corinna Vinschen
2014-02-09 16:10               ` Warren Young
2014-02-09 16:16                 ` Corinna Vinschen
2014-02-09 16:31                   ` Corinna Vinschen
2014-02-09 16:37                     ` Ken Brown
2014-02-09 17:12                 ` David Stacey
2014-02-10 10:48                   ` Warren Young
2014-02-10 13:16                     ` Peter Rosin
2014-02-10 22:05                       ` Warren Young
2014-02-10 23:35                         ` David Stacey
2014-02-11  2:35                           ` Andrey Repin
2014-02-12  0:06                             ` David Stacey
2014-02-12  2:06                               ` Warren Young
2014-02-12  3:54                                 ` Eric Blake
2014-02-12  9:09                                   ` Corinna Vinschen
2014-02-12 12:05                                     ` Andrey Repin
2014-02-12 15:16                                     ` Richard
2014-02-12 16:24                                     ` Ken Brown
2014-02-12 17:05                                       ` Richard
2014-02-12 17:15                                       ` Andrey Repin
2014-02-12 20:49                                       ` Corinna Vinschen
2014-02-12 22:53                                         ` Christopher Faylor
2014-02-13 11:46                                           ` Corinna Vinschen
2014-02-13 14:35                                             ` Andrey Repin
2014-02-13 14:38                                             ` Christopher Faylor
2014-02-13 15:37                                               ` Corinna Vinschen
2014-02-13 15:48                                                 ` Christopher Faylor
2014-02-13 16:09                                                   ` Corinna Vinschen
2014-02-13 18:33                                             ` get rid of getpwent? Achim Gratz
2014-02-13 19:02                                               ` Andrey Repin
2014-02-13 20:41                                               ` Corinna Vinschen
2014-02-13 21:48                                                 ` Achim Gratz
2014-02-14  9:46                                                   ` Corinna Vinschen
2014-02-12  4:40                                 ` get rid of getpwent? (Was: cygwin-1.7.28 getpwent header declaration changes ?) Andrey Repin
2014-02-07 20:09           ` Warren Young
2014-02-07 20:25             ` Warren Young
2014-02-07 21:01               ` Corinna Vinschen
2014-02-07 21:30             ` Corinna Vinschen
2014-02-07 21:49               ` Lavrentiev, Anton (NIH/NLM/NCBI) [C]
2014-02-08 10:38                 ` Corinna Vinschen
2014-02-08 21:29                   ` Lavrentiev, Anton (NIH/NLM/NCBI) [C]
2014-02-09  1:29                     ` Lavrentiev, Anton (NIH/NLM/NCBI) [C]
2014-02-07 21:44             ` Larry Hall (Cygwin)
2014-02-07 22:45               ` David Stacey
2014-02-07 23:39                 ` Larry Hall (Cygwin)
2014-02-08  0:50                   ` Andrey Repin
2014-02-08 15:19                     ` Warren Young
2014-02-08 15:39                       ` Warren Young
2014-02-09 20:06   ` cygwin-1.7.28 getpwent header declaration changes ? Marco Atzeri
2014-02-09 20:20     ` Corinna Vinschen
2014-02-10 16:14       ` Marco Atzeri
2014-02-07  9:27 Jan Nijtmans
2014-02-07  9:29 ` Corinna Vinschen

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