lt__private.h patch for windows targets without unistd.h

2007-04-04 Thread Christopher Hulbert

This patch defined R_OK to what I think it should be for windows and
changes access to _access. I think MS has access in an oldnames
library, but I chose to redefine it since according to MS, the POSIX
name access is deprecated
(http://msdn2.microsoft.com/en-us/library/ms235395(vs.80).aspx).

Chris
Index: libltdl/libltdl/lt__private.h
===
RCS file: /sources/libtool/libtool/libltdl/libltdl/lt__private.h,v
retrieving revision 1.13
diff -u -r1.13 lt__private.h
--- libltdl/libltdl/lt__private.h	25 Mar 2007 12:12:43 -	1.13
+++ libltdl/libltdl/lt__private.h	4 Apr 2007 14:08:56 -
@@ -45,6 +45,9 @@
 
 #if defined(HAVE_UNISTD_H)
 #  include 
+#elif defined (_WIN32) || defined (_WIN64)
+#  define access(a,b) _access(a,b)
+#  define R_OK 4
 #endif
 
 /* Import internal interfaces...  */


Re: ltmain.m4sh patch for cwrappersource

2007-04-04 Thread Christopher Hulbert

On 4/4/07, Ralf Wildenhues <[EMAIL PROTECTED]> wrote:

* Christopher Hulbert wrote on Tue, Apr 03, 2007 at 09:22:31PM CEST:
>  On 4/3/07, Ralf Wildenhues <[EMAIL PROTECTED]> wrote:
> > Thanks for your patch.  But really when porting to a w64 system
> > (including a specific compiler and toolset), I'd prefer a reasonably
> > complete port, at least including testsuite output and the like, so
> > we can tell our users what to expect.  I imagine it needs several more
> > changes, at least for libltdl.
>
>  What about without the _WIN64 defines? I can work around that. I've
>  never had much luck running the testsuite.

Why do you need luck to run the testsuite?  Just run it verbosely as
shown in README, post its output (but please pack with gzip or bzip2,
and to the libtool-patches list only).  We'll see to the rest then.


I tried to run the test suite, but it fails trying to use dlpreopen.
Attached is the check-local.log. The lib file exists, but when trying
to extract the members, the directory path does not exist?

In addition, to get the loaders to build, I had to patch lt__private.h
due to the use of R_OK in access. I will send this patch in a separate
thread.

 host-triplet: x86_64-pc-cygwin
 shell:/bin/sh
 compiler: pgcc
 compiler flags:   -Minform=severe
 linker:   /usr/bin/ld (gnu? no)
 libtool:  (GNU libtool 1.2442 2007/03/29 22:24:31) 2.1a
 automake: automake (GNU automake) 1.10
 autoconf: autoconf (GNU Autoconf) 2.61



Chris



Cheers,
Ralf



check-local.log.gz
Description: GNU Zip compressed data