[RFT/RFH] porting the poll module to win32

2008-08-18 Thread Paolo Bonzini
Hi, a while ago a user of GNU Smalltalk contributed code to run the emulation of poll in gnulib under Win32. The code was a little hackish, as it worked by emulating other POSIX system calls "as well as it was needed" to emulate poll; so I never contributed it to gnulib. Now, however, I mer

Re: how to use module `stdlib'

2008-08-18 Thread Simon Josefsson
Thien-Thi Nguyen <[EMAIL PROTECTED]> writes: > I just did: > $ gnulib-tool --import stdlib > > Now i see in stdlib_h.m4 the definition: > AC_DEFUN([gl_STDLIB_MODULE_INDICATOR], ...) > > Some questions on how to properly use this module: > > - What do i need to do wrt `gl_STDLIB_MODULE_INDICA

Re: [RFT/RFH] porting the poll module to win32

2008-08-18 Thread Simon Josefsson
Paolo Bonzini <[EMAIL PROTECTED]> writes: > Hi, > > a while ago a user of GNU Smalltalk contributed code to run the > emulation of poll in gnulib under Win32. The code was a little > hackish, as it worked by emulating other POSIX system calls "as well > as it was needed" to emulate poll; so I nev

Re: new module 'threadlib'

2008-08-18 Thread Bruno Haible
> 2008-08-17 Bruno Haible <[EMAIL PROTECTED]> > > New module 'threadlib'. Small fix: 2008-08-18 Bruno Haible <[EMAIL PROTECTED]> * lib/glthread/threadlib.c: Include . *** lib/glthread/threadlib.c.orig 2008-08-18 12:35:16.0 +0200 --- lib/glthread/threadlib.c2

Re: checkin of glthread/glcond modules

2008-08-18 Thread Bruno Haible
One more change in the 'thread' module (fixes a link error): 2008-08-18 Bruno Haible <[EMAIL PROTECTED]> * lib/glthread/thread.h [USE_SOLARIS_THREADS]: Use thread_in_use(), not pthread_in_use(). *** lib/glthread/thread.h.orig 2008-08-18 12:35:16.0 +0200 --- lib/glthrea

Re: gnulib manual

2008-08-18 Thread Bruno Haible
Simon Josefsson wrote: > Generally, see the chapter 'Invoking gnulib-tool' in the gnulib manual. Note that a copy of the gnulib manual is online at http://www.gnu.org/software/gnulib/manual/ Bruno

Re: Lock module improvement

2008-08-18 Thread Bruno Haible
Another fix: 2008-08-18 Bruno Haible <[EMAIL PROTECTED]> * lib/glthread/lock.h [USE_SOLARIS_THREADS]: Fix glthread_recursive_lock_* macros. * lib/glthread/lock.c (glthread_recursive_lock_destroy_multithreaded): Fix syntax error. *** lib/glthread/lock.h.orig2

Re: [RFT/RFH] porting the poll module to win32

2008-08-18 Thread Paolo Bonzini
If you believe I should be able to modify the code to use poll instead of select, That's for sure. I attach an example of a bidirectional I/O loop using poll. and to use your module successfully for mingw32, I could give it a try. Yes, stdin from the console is a console handle. The atta

[RFE] function to read a file descriptor

2008-08-18 Thread Debarshi Ray
I was wondering whether gnulib has a function to safely read or recv from a file desctiptor. I could not find one, and have had to hack them up on numerous occasions. Here is one such version I wrote while implementing a feature for GNU Inetutils: size_t recvbuf (int sockfd, void **buffer, size_t

Re: Lock module improvement

2008-08-18 Thread Yoann Vandoorselaere
Hi Bruno, Le lundi 18 août 2008 à 12:55 +0200, Bruno Haible a écrit : > Another fix: Here is another patch on top of current GnuLib HEAD: - Make use of the thread module in lock-test - Include missing cond unit-test. - Isolate thread specific CPP flags into THREADCPPFLAGS (this is useful for a li

autobuild.m4 time zone fix

2008-08-18 Thread Simon Josefsson
Pushed. /Simon >From 9fa188508ca3951b0fd6c04dfeefff5a622fe38a Mon Sep 17 00:00:00 2001 From: Simon Josefsson <[EMAIL PROTECTED]> Date: Mon, 18 Aug 2008 19:40:11 +0200 Subject: [PATCH] autobuild.m4: Use TZ=UTC to avoid time zone complexity. --- ChangeLog |4 m4/autobuild.m4 |6

Re: autobuild.m4 time zone fix

2008-08-18 Thread Simon Josefsson
Simon Josefsson <[EMAIL PROTECTED]> writes: > Pushed. This one too. /Simon >From e8ce1f16994aebc497cb91159149ec33baeadfe8 Mon Sep 17 00:00:00 2001 From: Simon Josefsson <[EMAIL PROTECTED]> Date: Mon, 18 Aug 2008 19:47:23 +0200 Subject: [PATCH] Use ISO 8601 format. Attribution. --- ChangeLog

Re: [RFE] function to read a file descriptor

2008-08-18 Thread Bruno Haible
Debarshi Ray wrote: > I was wondering whether gnulib has a function to safely read or recv > from a file desctiptor. How about using the 'read-file' module, passing it a FILE stream created with fdopen()? Bruno

Re: [RFT/RFH] porting the poll module to win32

2008-08-18 Thread Simon Josefsson
Hi Paolo. I'm trying to use your poll replacement. I have rewritten gnutls-cli to use poll, and it works fine under debian. However, building under mingw32 fails. With your original patch I get compile errors. What do you think about writing a gnulib self-test that tests whether poll works cor

Re: [RFE] function to read a file descriptor

2008-08-18 Thread Debarshi Ray
> *buffer = realloc (*buffer, *size); Oops, I meant to use xrealloc there. Happy hacking, Debarshi

Re: [RFE] function to read a file descriptor

2008-08-18 Thread Debarshi Ray
> How about using the 'read-file' module, passing it a FILE stream created with > fdopen()? Yes, I saw that. However there seems to be many instances of using the low-level system calls directly, especially in Inetutils where reading from sockets is quite common. Happy hacking, Debarshi

improve error message from gitlog-to-changelog with too-old Git

2008-08-18 Thread Ben Pfaff
GNU PSPP has started using the gitlog-to-changelog script, via the corresponding gnulib module. One of the PSPP developers (CC'd) reported the following error from the script: > fatal: invalid --pretty format: format:%ct %an <%ae>%n%n%s%n%b%n > gitlog-to-changelog: error closing pipe from git l

Re: [RFT/RFH] porting the poll module to win32

2008-08-18 Thread Paolo Bonzini
What do you think about writing a gnulib self-test that tests whether poll works correctly? It would help to test the replacement function on various platforms quicker, and also helps catch regression. I suspect writing a self test may be somewhat complicated though, you'll need to setup at le

Re: improve error message from gitlog-to-changelog with too-old Git

2008-08-18 Thread Jim Meyering
Ben Pfaff <[EMAIL PROTECTED]> wrote: > GNU PSPP has started using the gitlog-to-changelog script, via > the corresponding gnulib module. One of the PSPP developers > (CC'd) reported the following error from the script: > >> fatal: invalid --pretty format: format:%ct %an <%ae>%n%n%s%n%b%n >> gitl