Declare some functions already exported by msys DLL

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Declare some functions already exported by msys DLL

Charles Wilson-8
The following functions are already exported by msys-1.0.dll, but are
not declared in the installed header files.  The attached patch should
fix that; and silences some compile warnings when building msys-inetutils.

FYI, the following is still true:

*** Microsoft Vista and above ***
  The r* clients will not operate correctly on this platform.  This is
  because the underlying 'rcmd()' (actually, "cygwin_rcmd()") function
  used by these applications is implemented on MSYS in terms of the
  winsock 'rcmd()' function in wsock32.dll.  However, with the release
  of Microsoft Vista, these important functions:
     rcmd() / rexec() / rresvport()
  are no longer provided by wsock32.dll -- in fact, they are not
  provided at all.  Newer cygwin implementations (since 2006-07-12)
  have (re)implemented rcmd() and friends without relying the missing
  winsock2 functions.  However, MSYS (as of 1.0.13) has not done so;
  until that happens, the r* commands will remain non-functional on
  Vista clients.


Now, these msys-exported rcmd()/rexec()/rresvport() functions DO work
just fine if you're on XP or earlier.  So, since we provide them, and
they work (on some platforms), we should declare them in the installed
headers.

Fixing their operation, on Vista and above, is a project for another patch.

newlib/ChangeLog.MSYS:

2010.03.29  Charles Wilson  <xxx>

        * libc/include/sys/unistd.h: Declare fchdir and getdomainname.

winsup/cygwin/ChangeLog.MSYS:

2010.03.29  Charles Wilson  <xxx>

        * include/netdb.h: Declare rcmd, rexec, and rresvport.

OK?

--
Chuck


------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Mingw-msys mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/mingw-msys

msys-headers.patch (2K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Declare some functions already exported by msys DLL

Cesar Strauss-2
Charles Wilson wrote:
> The following functions are already exported by msys-1.0.dll, but are
> not declared in the installed header files.  The attached patch should
> fix that; and silences some compile warnings when building msys-inetutils.

> OK?

Sure, please go ahead and commit.

Thanks,
Cesar


------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Mingw-msys mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/mingw-msys
Reply | Threaded
Open this post in threaded view
|

Re: Declare some functions already exported by msys DLL

Charles Wilson-8
On 3/30/2010 5:42 PM, Cesar Strauss wrote:
> Charles Wilson wrote:
>> The following functions are already exported by msys-1.0.dll, but are
>> not declared in the installed header files.  The attached patch should
>> fix that; and silences some compile warnings when building msys-inetutils.
>
>> OK?
>
> Sure, please go ahead and commit.

Done.



FWIW, after a little investigation I believe the "r*tools on Vista"
issue is best solved by providing replacement functions for
rcmd()/rexec()/rresvport() *in the rtools* themselves, rather than in
msys -- at least until a sea change in MSYS itself occurs. Reasoning:

1) porting the cygwin patchset that fixed this problem for them, back in
2006, is...basically impossible. It happens that THIS commit, the one
that added built-in support rather than relying on wsock32 for these
functions, is THE commit that caused Corinna to bump the cygwin version
from 1.5.x to 1.7.0-devel.  This patchset added not just r*()
implementations, but full support throughout cygwin for IPv6, and
matching r*_sa() functions.  That's a WAY bigger project than it needs
to be, just for this little issue, for some rarely used utilities.

2) So...grabbing BSD sources for "plain" non-IPv6-enabled r*()
implementations, and integrating them into msys, is kind of a dead end
IMO.  The future is, I hope, to re-implement the things that make MSYS
"msys", on top of the cygwin-1.7 code base -- and then you get all these
things for free; rather than spending more time re-inventing the wheel,
porting (or re-engineering, or just plain redo-ing) stuff that cygwin
has already done, since the MSYS fork seven years ago.

So...once you have those BSD sources, it's actually easier NOT to try to
shoehorn them into msys, and instead just use existing automake/autoconf
idioms to turn them into rpl_* replacement functions, within the
r*tools/inetutils package.

I'm already 75% of the way there on that.

--
Chuck



--
Chuck

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Mingw-msys mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/mingw-msys