[prev in list] [next in list] [prev in thread] [next in thread] 

List:       mingw-cvs
Subject:    MinGW-cvs Digest, Vol 62, Issue 4
From:       mingw-cvs-request () lists ! sourceforge ! net
Date:       2013-06-17 17:34:58
Message-ID: mailman.54530.1371490498.12996.mingw-cvs () lists ! sourceforge ! net
[Download RAW message or body]

Send MinGW-cvs mailing list submissions to
	mingw-cvs@lists.sourceforge.net

To subscribe or unsubscribe via the World Wide Web, visit
	https://lists.sourceforge.net/lists/listinfo/mingw-cvs
or, via email, send a message with subject or body 'help' to
	mingw-cvs-request@lists.sourceforge.net

You can reach the person managing the list at
	mingw-cvs-owner@lists.sourceforge.net

When replying, please edit your Subject line so it is more specific
than "Re: Contents of MinGW-cvs digest..."


This list will notify you of updates to the code stored in CVS.  Typically only \
developers with access to update the CVS are interested in this list.  However, this \
list can be beneficial to see what is happening with your changes.  If you wish to \
unsubscribe please do so at https://lists.sourceforge.net/lists/listinfo/mingw-cvs.

Today's Topics:

   1. [git push mingw-org-wsl]Repository: mingw-org-wsl	branch,
      4.0-dev, updated. d4a74a9c3f2752d7cf6c35180f3672501f6b91a2
      (Earnie Boyd)
   2. [git push mingw-org-wsl]Repository: mingw-org-wsl	branch,
      4.0-dev, updated. 8614d1f4afc8f7e8d15abbf71ebc0243253c014a
      (Earnie Boyd)
   3. [git push mingw-org-wsl]Repository: mingw-org-wsl	branch,
      4.0-dev, updated. 16281c42c1f0351fb4cdd2c14307894d1e106fa1
      (Earnie Boyd)


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

Message: 1
Date: Sun, 16 Jun 2013 18:24:52 +0000
From: "Earnie Boyd" <noreply@sourceforge.net>
Subject: [MinGW-cvs] [git push mingw-org-wsl]Repository: mingw-org-wsl
	branch, 4.0-dev, updated. d4a74a9c3f2752d7cf6c35180f3672501f6b91a2
To: mingw-cvs@lists.sourceforge.net
Message-ID:
	<mailman.54531.1371490498.12996.mingw-cvs@lists.sourceforge.net>

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Repository: mingw-org-wsl".

The branch, 4.0-dev has been updated
       via  d4a74a9c3f2752d7cf6c35180f3672501f6b91a2 (commit)
      from  aae1b310df39d2d33a3b42dcc8e159ec933f6f3d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sf.net/p/mingw/mingw-org-wsl/ci/d4a74a9c3f2752d7cf6c35180f3672501f6b91a2/

commit d4a74a9c3f2752d7cf6c35180f3672501f6b91a2
Author: Earnie Boyd <earnie@users.sourceforge.net>
Date:   Sun Jun 16 14:23:18 2013 -0400

    Correct malformations and missed definitions to finish _USE_32BIT_TIME_T coding.

diff --git a/ChangeLog b/ChangeLog
index 96e0515..91c6818 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,28 @@
+2013-06-16  Earnie Boyd  <earnie@users.sourceforge.net>
+
+	* include/_mingw.h (GCC system_header): Add a __CRT_TESTING__ filter.
+	* include/string.h (GCC system_header): Ditto.
+	* include/sys/stat.h (GCC system_header): Ditto.
+	(string.h): Move the include toward the top of the file.
+	(extern "C" {): Move above the filters so that it is not incorrectly
+	conditional.
+	Correct some comments and move the opening brace to the function
+	definition line throughout.
+	* include/sys/utime.h (utime): Move declaration to after the declaration
+	of _utime64().  Create a _CRTALIAS when _USE_32BIT_TIME_T is undefined.
+	Add datatype specifiers within the _CRTALIAS definitions throughout.
+	* include/wchar.h (GCC system_header): Add a __CRT_TESTING__ filter.
+	(FILENAME_MAX): Define macro if not already defined.
+	Correct comments throughout.
+	Correct #if...#endif misaligned pair.
+	(wcsicmp): Use _CRTALIAS instead of __CRT_INLINE since it is a one line
+	function definition.
+	(*wfinddata*): Use FILENAME_MAX throughout.
+	(_wstat32): Make a _CRTALIAS rather than a _CRTIMP.
+	(_wstat64i32): Use __CRT_MAYBE_INLINE instead of __CRT_INLINE.
+	(_wstat32i64): Define.
+	(_wstat, _wstati64): Remove the MSVCRT_VERSION >= 800 filter.
+
 2013-06-07  Earnie Boyd  <earnie@users.sourceforge.net>
 
 	* include/_mingw.h (_CRTALIAS): Add comments explaining its purpose.
diff --git a/include/_mingw.h b/include/_mingw.h
index f038fdf..eb7c41f 100644
--- a/include/_mingw.h
+++ b/include/_mingw.h
@@ -29,7 +29,9 @@
  */
 #ifndef __MINGW_H
 #define __MINGW_H
+#ifndef __CRT_TESTING__
 #pragma GCC system_header
+#endif
 #include <sdkddkver.h>
 
 #define __MINGW_VERSION             4.0
diff --git a/include/string.h b/include/string.h
index 11f6601..65ba493 100644
--- a/include/string.h
+++ b/include/string.h
@@ -8,11 +8,11 @@
  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
  * and/or sell copies of the Software, and to permit persons to whom the
  * Software is furnished to do so, subject to the following conditions:
- * 
+ *
  * The above copyright notice and this permission notice (including the next
  * paragraph) shall be included in all copies or substantial portions of the
  * Software.
- * 
+ *
  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
@@ -23,7 +23,9 @@
  */
 #ifndef _STRING_H
 #define	_STRING_H
+#ifndef __CRT_TESTING__
 #pragma GCC system_header
+#endif
 #include <_mingw.h>
 
 /*
diff --git a/include/sys/stat.h b/include/sys/stat.h
index 36198f0..43047ba 100644
--- a/include/sys/stat.h
+++ b/include/sys/stat.h
@@ -23,7 +23,9 @@
  */
 #ifndef _STAT_H_
 #define _STAT_H_
+#ifndef __CRT_TESTING__
 #pragma GCC system_header
+#endif
 #include <_mingw.h>
 
 #define __need_size_t
@@ -33,6 +35,7 @@
 #endif /* Not RC_INVOKED */
 
 #include <sys/types.h>
+#include <string.h> /* Need memset declaration */
 
 /*
  * Constants for the stat st_mode member.
@@ -86,6 +89,10 @@
 
 #ifndef RC_INVOKED
 
+#ifdef	__cplusplus
+extern "C" {
+#endif
+
 #ifndef _STAT_DEFINED
 /*
  * The structure manipulated and returned by stat and fstat.
@@ -170,10 +177,6 @@ struct _stat64i32 {
 	__time64_t	st_ctime;
 };
 
-#ifdef	__cplusplus
-extern "C" {
-#endif
-
 /* _stat32 does not exist in MSVCRT.DLL */
 _CRTIMP int __cdecl __MINGW_NOTHROW _stat (const char*, struct _stat32*);
 _CRTALIAS int __cdecl __MINGW_NOTHROW _stat32 (const char* _v1, struct _stat32* _v2) \
{ @@ -193,7 +196,7 @@ _CRTALIAS int __cdecl __MINGW_NOTHROW _fstat32 (int _v1, struct \
_stat32* _v2) {  _CRTIMP int __cdecl __MINGW_NOTHROW _fstat64 (int, struct _stat64*);
 int __cdecl __MINGW_NOTHROW _fstat32i64 (int, struct _stat32i64*);
 int __cdecl __MINGW_NOTHROW _fstat64i32 (int, struct _stat64i32*);
-#include <string.h> /* Need memset declaration */
+
 __CRT_MAYBE_INLINE int __cdecl _fstat64i32(int desc, struct _stat64i32 *_stat) {
   struct _stat64 st;
   int ret = _fstat64(desc, &st);
@@ -214,8 +217,7 @@ __CRT_MAYBE_INLINE int __cdecl _fstat64i32(int desc, struct \
_stat64i32 *_stat) {  _stat->st_ctime = st.st_ctime;
   return ret;
 }
-__CRT_MAYBE_INLINE int __cdecl _fstat32i64(int desc, struct _stat32i64 *_stat)
-{
+__CRT_MAYBE_INLINE int __cdecl _fstat32i64(int desc, struct _stat32i64 *_stat) {
   struct _stat32 st;
   int ret = _fstat32(desc, &st);
   if (ret == -1) {
@@ -235,8 +237,7 @@ __CRT_MAYBE_INLINE int __cdecl _fstat32i64(int desc, struct \
_stat32i64 *_stat)  _stat->st_ctime = st.st_ctime;
   return ret;
 }
-__CRT_MAYBE_INLINE int __cdecl _stat64i32(const char *fname, struct _stat64i32 \
                *_stat)
-{
+__CRT_MAYBE_INLINE int __cdecl _stat64i32(const char *fname, struct _stat64i32 \
*_stat) {  struct _stat64 st;
   int ret = _stat64(fname, &st);
   if (ret == -1) {
@@ -256,8 +257,7 @@ __CRT_MAYBE_INLINE int __cdecl _stat64i32(const char *fname, \
struct _stat64i32 *  _stat->st_ctime = st.st_ctime;
   return ret;
 }
-__CRT_MAYBE_INLINE int __cdecl _stat32i64(const char *fname, struct _stat32i64 \
                *_stat)
-{
+__CRT_MAYBE_INLINE int __cdecl _stat32i64(const char *fname, struct _stat32i64 \
*_stat) {  struct _stat32 st;
   int ret = _stat32(fname, &st);
   if (ret == -1) {
@@ -303,17 +303,15 @@ __CRT_MAYBE_INLINE int __cdecl _stat32i64(const char *fname, \
struct _stat32i64 *  
 #if !defined ( _WSTAT_DEFINED) /* also declared in wchar.h */
 /* _wstat32 does not exist in MSVCRT.DLL */
+_CRTIMP int __cdecl __MINGW_NOTHROW _wstat (const wchar_t*, struct _stat32*);
 _CRTALIAS int __cdecl __MINGW_NOTHROW _wstat32 (const wchar_t* _v1, struct _stat32* \
                _v2) {
-    _CRTIMP int __cdecl __MINGW_NOTHROW _wstat (const wchar_t*, struct _stat32*);
     return _wstat(_v1, _v2);
 }
 
 _CRTIMP int __cdecl __MINGW_NOTHROW _wstat64 (const wchar_t*, struct _stat64*);
 _CRTIMP int __cdecl __MINGW_NOTHROW _wstat32i64 (const wchar_t*, struct \
_stat32i64*);  int __cdecl __MINGW_NOTHROW _wstat64i32 (const wchar_t*, struct \
                _stat64i32*);
-#include <string.h> /* Need memset declaration */
-__CRT_MAYBE_INLINE int __cdecl _wstat64i32(const wchar_t *fname, struct _stat64i32 \
                *_stat)
-{
+__CRT_MAYBE_INLINE int __cdecl _wstat64i32(const wchar_t *fname, struct _stat64i32 \
*_stat) {  struct _stat64 st;
   int ret = _wstat64(fname, &st);
   if (ret == -1) {
@@ -333,8 +331,7 @@ __CRT_MAYBE_INLINE int __cdecl _wstat64i32(const wchar_t *fname, \
struct _stat64i  _stat->st_ctime = st.st_ctime;
   return ret;
 }
-__CRT_MAYBE_INLINE int __cdecl _wstat32i64(const wchar_t *fname, struct _stat32i64 \
                *_stat)
-{
+__CRT_MAYBE_INLINE int __cdecl _wstat32i64(const wchar_t *fname, struct _stat32i64 \
*_stat) {  struct _stat32 st;
   int ret = _wstat32(fname, &st);
   if (ret == -1) {
@@ -359,14 +356,15 @@ __CRT_MAYBE_INLINE int __cdecl _wstat32i64(const wchar_t \
*fname, struct _stat32i  #define _wstat      _wstat32
 #define _wstati64   _wstat32i64
 
-#else /* !_USE_32BIT_TIME_T */
+#else /* ! _USE_32BIT_TIME_T */
 #define _wstat      _wstat64i32
 #define _wstati64   _wstat64
 
 #endif /* _USE_32BIT_TIME_T */
 
 #define _WSTAT_DEFINED
-#endif /* _WSTAT_DEFIND */
+#endif /* ! _WSTAT_DEFIND */
+
 
 #ifdef	__cplusplus
 }
diff --git a/include/sys/utime.h b/include/sys/utime.h
index 9d5db74..afcb7e3 100644
--- a/include/sys/utime.h
+++ b/include/sys/utime.h
@@ -74,14 +74,6 @@ struct utimbuf32
 extern "C" {
 #endif
 
-#ifndef	_NO_OLDNAMES
-#ifdef _USE_32BIT_TIME_T
-_CRTIMP int __cdecl __MINGW_NOTHROW	utime (const char*, struct utimbuf*);
-#else
-#define utime _utime
-#endif
-#endif	/* Not _NO_OLDNAMES */
-
 _CRTIMP int __cdecl __MINGW_NOTHROW	_utime64 (const char*, struct __utimbuf64*);
 _CRTIMP int __cdecl __MINGW_NOTHROW	_futime64 (int, struct __utimbuf64*);
 
@@ -92,16 +84,27 @@ _CRTIMP int __cdecl __MINGW_NOTHROW	_futime32 (int, struct \
__utimbuf32*);  #else
 _CRTIMP int __cdecl __MINGW_NOTHROW	_utime (const char*, struct _utimbuf*);
 _CRTALIAS int __cdecl __MINGW_NOTHROW _utime32 (const char* _v1, struct __utimbuf32* \
                _v2) {
-    return _utime(_v1, _v2);
+    return _utime(_v1, (struct _utimbuf*)_v2);
 }
 
 _CRTIMP int __cdecl __MINGW_NOTHROW	_futime (int, struct _utimbuf*);
 _CRTALIAS int __cdecl __MINGW_NOTHROW _futime32 (int _v1, struct __utimbuf32* _v2) {
-    return _futime(_v1, _v2);
+    return _futime(_v1, (struct _utimbuf*)_v2);
 }
 
 #endif
 
+#ifndef	_NO_OLDNAMES
+#ifdef _USE_32BIT_TIME_T
+_CRTIMP int __cdecl __MINGW_NOTHROW	utime (const char*, struct utimbuf*);
+#else
+int __cdecl __MINGW_NOTHROW utime (const char*, struct utimbuf*);
+_CRTALIAS int __cdecl __MINGW_NOTHROW	utime (const char* _v1, struct utimbuf* _v2) {
+  return _utime64(_v1, (struct __utimbuf64*)_v2);
+}
+#endif
+#endif	/* Not _NO_OLDNAMES */
+
 #ifndef _USE_32BIT_TIME_T
 _CRTALIAS int __cdecl __MINGW_NOTHROW	_utime (const char* _v1, struct _utimbuf* _v2) \
{  return(_utime64  (_v1,(struct __utimbuf64*)_v2));
@@ -130,7 +133,7 @@ _CRTIMP int __cdecl __MINGW_NOTHROW	_wutime32 (const wchar_t*, \
struct __utimbuf3  #else /* MSVCRT_VERSION < 800 */
 _CRTIMP int __cdecl __MINGW_NOTHROW	_wutime (const wchar_t*, struct _utimbuf*);
 _CRTALIAS int __cdecl __MINGW_NOTHROW _wutime32 (const wchar_t* _v1, struct \
                __utimbuf32* _v2) {
-    return _wutime(_v1, _v2);
+    return _wutime(_v1, (struct _utimbuf*)_v2);
 }
 
 #endif /* MSVCRT_VERSION >= 800 */
diff --git a/include/wchar.h b/include/wchar.h
index 7066839..0efaedc 100644
--- a/include/wchar.h
+++ b/include/wchar.h
@@ -23,7 +23,9 @@
  */
 #ifndef	_WCHAR_H_
 #define	_WCHAR_H_
+#ifndef __CRT_TESTING__
 #pragma GCC system_header
+#endif
 #include <_mingw.h>
 
 #ifndef RC_INVOKED
@@ -38,7 +40,7 @@
 #define __need___va_list
 #include <stdarg.h>
 #define __VALIST __builtin_va_list
-#endif
+#endif /* ndef __VALIST */
 
 #endif /* Not RC_INVOKED */
 
@@ -57,6 +59,10 @@
 #define	WEOF	(wchar_t)(0xFFFF)
 #endif
 
+#ifndef FILENAME_MAX
+#define FILENAME_MAX 260
+#endif
+
 #ifndef RC_INVOKED
 
 #ifdef __cplusplus
@@ -243,13 +249,12 @@ _CRTALIAS wchar_t* __cdecl __MINGW_NOTHROW  _wctime32 (const \
__time32_t* _v1) {  #endif /* MSVCRT_VERSION >= 800 */
 
 #if MSVCRT_VERSION >= 800
-#if defined(_USE_32BIT_TIME_T)
+#ifdef _USE_32BIT_TIME_T
 _CRTALIAS wchar_t* __cdecl __MINGW_NOTHROW	_wctime (const time_t* _v)	{ \
return(_wctime32 (_v)); }  
-#else /* MSVCRT_VERSION < 800 */
+#else /* ! _USE_32BIT_TIME_T */
 _CRTALIAS wchar_t* __cdecl __MINGW_NOTHROW	_wctime (const time_t* _v)	{ \
                return(_wctime64 (_v)); }
-#endif /* defined(_USE_32BIT_TIME_T) */
-#endif /* MSVCRT_VERSION >= 800 */
+#endif /* _USE_32BIT_TIME_T */
 
 #else /* MSVCRT_VERSION < 800 */
 #ifdef _USE_32BIT_TIME_T
@@ -272,7 +277,7 @@ _CRTIMP int __cdecl __MINGW_NOTHROW	_wutime32 (const wchar_t*, \
struct __utimbuf3  #else /* MSVCRT_VERSION < 800 */
 _CRTIMP int __cdecl __MINGW_NOTHROW	_wutime (const wchar_t*, struct _utimbuf*);
 _CRTALIAS int __cdecl __MINGW_NOTHROW _wutime32 (const wchar_t* _v1, struct \
                __utimbuf32* _v2) {
-    return _wutime(_v1, _v2);
+    return _wutime(_v1, (struct _utimbuf *)_v2);
 }
 
 #endif /* MSVCRT_VERSION >= 800 */
@@ -341,11 +346,9 @@ _CRTIMP  wchar_t* __cdecl __MINGW_NOTHROW __wcserror(const \
wchar_t*);  #ifndef	_NO_OLDNAMES
 /* NOTE: There is no _wcscmpi, but this is for compatibility. */
 int __cdecl __MINGW_NOTHROW wcscmpi (const wchar_t *, const wchar_t *);
-#ifndef __NO_INLINE__
-__CRT_INLINE int __cdecl __MINGW_NOTHROW
+_CRTALIAS int __cdecl __MINGW_NOTHROW
 wcscmpi (const wchar_t * __ws1, const wchar_t * __ws2)
   {return _wcsicmp (__ws1, __ws2);}
-#endif
 _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW wcsdup (const wchar_t*);
 _CRTIMP int __cdecl __MINGW_NOTHROW	wcsicmp (const wchar_t*, const wchar_t*);
 _CRTIMP int __cdecl __MINGW_NOTHROW	wcsicoll (const wchar_t*, const wchar_t*);
@@ -427,7 +430,7 @@ struct _wfinddata_t {
 	time_t		time_access;	/* -1 for FAT file systems */
 	time_t		time_write;
 	_fsize_t	size;
-	wchar_t		name[260];	/* may include spaces. */
+	wchar_t		name[FILENAME_MAX];	/* may include spaces. */
 };
 struct _wfinddatai64_t {
 	unsigned    attrib;
@@ -435,7 +438,7 @@ struct _wfinddatai64_t {
 	time_t      time_access;
 	time_t      time_write;
 	__int64     size;
-	wchar_t     name[260];
+	wchar_t     name[FILENAME_MAX];
 };
 struct _wfinddata64_t {
         unsigned    attrib;
@@ -444,9 +447,8 @@ struct _wfinddata64_t {
         __time64_t  time_write;
 /* 8 bytes are returned so it can't be _fsize_t */
         __int64    size;
-        wchar_t     name[260];
+        wchar_t     name[FILENAME_MAX];
 };
-#include <stdio.h>
 struct _wfinddata32_t {
 	unsigned	attrib;
 	__time32_t	time_create;
@@ -514,7 +516,7 @@ _CRTALIAS int  __cdecl __MINGW_NOTHROW	_wfindnext32 (intptr_t \
_v1, struct _wfind  #define _wfindfirsti64 _wfindfirst32i64
 #define _wfindnexti64 _wfindnext32i64
 
-#else /* !defined(_USE_32BIT_TIME_T)
+#else /* !defined(_USE_32BIT_TIME_T) */
 #define _wfinddata_t _wfinddata64i32_t
 #define _wfinddatai64_t _wfinddata64_t
 #define _wfindfirst _wfindfirst64i32
@@ -621,28 +623,32 @@ struct _stat64i32 {
 };
 
 #define __stat64 _stat64
-#if defined(_USE_32BIT_TIME_T) && MSVCRT_VERSION >= 800
+#if defined(_USE_32BIT_TIME_T)
 #define _fstat      _fstat32
 #define _fstati64   _fstat32i64
 #define _stat       _stat32
 #define _stati64    _stat32i64
-#else  /* !_USE_32BIT_TIME_T */
+#else  /* ! _USE_32BIT_TIME_T */
 #define _fstat      _fstat64i32
 #define _fstati64   _fstat64
 #define _stat       _stat64i32
 #define _stati64    _stat64
 #endif /* _USE_32BIT_TIME_T */
 #define _STAT_DEFINED
-#endif /* _STAT_DEFINED */
+#endif /* ! _STAT_DEFINED */
 
 #if !defined ( _WSTAT_DEFINED) /* also declared in sys/stat.h */
-_CRTIMP int __cdecl __MINGW_NOTHROW _wstat32 (const wchar_t*, struct _stat32*);
+/* _wstat32 does not exist in MSVCRT.DLL */
+_CRTIMP int __cdecl __MINGW_NOTHROW _wstat (const wchar_t*, struct _stat32*);
+_CRTALIAS int __cdecl __MINGW_NOTHROW _wstat32 (const wchar_t* _v1, struct _stat32* \
_v2) { +    return _wstat(_v1, _v2);
+}
+
 _CRTIMP int __cdecl __MINGW_NOTHROW _wstat64 (const wchar_t*, struct _stat64*);
 _CRTIMP int __cdecl __MINGW_NOTHROW _wstat32i64 (const wchar_t*, struct \
_stat32i64*);  int __cdecl __MINGW_NOTHROW _wstat64i32 (const wchar_t*, struct \
                _stat64i32*);
-#ifndef __NO_INLINE__
 #include <string.h> /* Need memset declaration. */
-  __CRT_INLINE int __cdecl _wstat64i32(const wchar_t *fname, struct _stat64i32 \
*_stat) +__CRT_MAYBE_INLINE int __cdecl _wstat64i32(const wchar_t *fname, struct \
_stat64i32 *_stat)  {
     struct _stat64 st;
     int ret = _wstat64(fname, &st);
@@ -662,16 +668,33 @@ int __cdecl __MINGW_NOTHROW _wstat64i32 (const wchar_t*, struct \
_stat64i32*);  _stat->st_mtime = st.st_mtime;
     _stat->st_ctime = st.st_ctime;
     return ret;
+}
+__CRT_MAYBE_INLINE int __cdecl _wstat32i64(const wchar_t *fname, struct _stat32i64 \
*_stat) { +  struct _stat32 st;
+  int ret = _wstat32(fname, &st);
+  if (ret == -1) {
+    memset(_stat, 0, sizeof(struct _stat32i64));
+    return -1;
   }
-#else
-#define _wstat64i32 _wstat64
-#endif
+  _stat->st_dev = st.st_dev;
+  _stat->st_ino = st.st_ino;
+  _stat->st_mode = st.st_mode;
+  _stat->st_nlink = st.st_nlink;
+  _stat->st_uid = st.st_uid;
+  _stat->st_gid = st.st_gid;
+  _stat->st_rdev = st.st_rdev;
+  _stat->st_size = (_off_t) st.st_size;
+  _stat->st_atime = st.st_atime;
+  _stat->st_mtime = st.st_mtime;
+  _stat->st_ctime = st.st_ctime;
+  return ret;
+}
 
-#if defined(_USE_32BIT_TIME_T) && MSVCRT_VERSION >= 800
+#if defined(_USE_32BIT_TIME_T)
 #define _wstat      _wstat32
 #define _wstati64   _wstat32i64
-#else
 
+#else /* ! _USE_32BIT_TIME_T */
 #define _wstat      _wstat64i32
 #define _wstati64   _wstat64
 #endif /* _USE_32BIT_TIME_T */

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

Summary of changes:
 ChangeLog           |   25 +++++++++++++++++
 include/_mingw.h    |    2 +
 include/string.h    |    6 +++-
 include/sys/stat.h  |   36 ++++++++++++-------------
 include/sys/utime.h |   25 ++++++++++-------
 include/wchar.h     |   73 +++++++++++++++++++++++++++++++++-----------------
 6 files changed, 110 insertions(+), 57 deletions(-)


hooks/post-receive
-- 
Repository: mingw-org-wsl



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

Message: 2
Date: Sun, 16 Jun 2013 19:08:20 +0000
From: "Earnie Boyd" <noreply@sourceforge.net>
Subject: [MinGW-cvs] [git push mingw-org-wsl]Repository: mingw-org-wsl
	branch, 4.0-dev, updated. 8614d1f4afc8f7e8d15abbf71ebc0243253c014a
To: mingw-cvs@lists.sourceforge.net
Message-ID:
	<mailman.54532.1371490498.12996.mingw-cvs@lists.sourceforge.net>

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Repository: mingw-org-wsl".

The branch, 4.0-dev has been updated
       via  8614d1f4afc8f7e8d15abbf71ebc0243253c014a (commit)
      from  d4a74a9c3f2752d7cf6c35180f3672501f6b91a2 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sf.net/p/mingw/mingw-org-wsl/ci/8614d1f4afc8f7e8d15abbf71ebc0243253c014a/

commit 8614d1f4afc8f7e8d15abbf71ebc0243253c014a
Author: Earnie Boyd <earnie@users.sourceforge.net>
Date:   Sun Jun 16 15:07:56 2013 -0400

    Update NEWS for MSVCRT_VERSION and _CRTALIAS of time functions.

diff --git a/ChangeLog b/ChangeLog
index 91c6818..2b7abc9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,7 @@
 2013-06-16  Earnie Boyd  <earnie@users.sourceforge.net>
 
+	* NEWS: Add text for MSVCRT_VERSION and for the _CRTALIAS 32bit time_t
+	definitions.
 	* include/_mingw.h (GCC system_header): Add a __CRT_TESTING__ filter.
 	* include/string.h (GCC system_header): Ditto.
 	* include/sys/stat.h (GCC system_header): Ditto.
diff --git a/NEWS b/NEWS
index f9aab6c..410f633 100644
--- a/NEWS
+++ b/NEWS
@@ -49,6 +49,15 @@ during the link step or during runtime.  However, this also \
removes the  inconsistency between a Microsoft build and the MinGW build in that you \
do not  need to define __MSVCRT_VERSION__ correctly.
 
+We now have a MSVCRT_VERSION which is aimed to contain a value which represents
+the version of the MSVCRT.DLL on a Windows OS.  For instance XP has a version
+of 710, Vista has a value of 800 and Win7 has a value of 910.  These values are
+based on the (MajorLinkerVersion * 100) + MinorLinkerVersion as returned from
+objdump -x MSVCRT.DLL.  The default value will be determined by the value of
+_WIN32_WINNT within the _mingw.h file unless the user has defined it already.
+This allows the code builder to not need to worry with the value of
+MSVCRT_VERSION since it should have the correct value for the targeted OS.
+
 We now assume that GCC is the only compiler used with the MinGW.org WSL
 (Windows System Libraries) and that the minimum supported version of GCC is
 3.5.4.  This allowed for futher code refactoring reducing the number of lines
@@ -69,7 +78,12 @@ use 32bit time_t with msvcrt.dll but it would be slightly slower.  \
Note, I  have discovered that the SysWOW64/msvcrt.dll contains the 32bit time_t \
functions  but we do not deliver libmsvcrt.a with these imports as this is not \
available on  all systems.  However, you could possibly (needs testing) use the \
                msvcrt.dll
-directly to link against and define _HAVE_32BIT_TIME_T during the compile. 
+directly to link against and define _HAVE_32BIT_TIME_T during the compile.  In
+many cases we create a _CRTALIAS for the functions in the header files.  This
+allows an application to use 32bit time_t structures and 32bit time functions
+regardless of the MSVCRT.DLL on the system.  If the MSVCRT.DLL contains the
+function for the targeted MSVCRT_VERSION value then the function is imported
+instead of an alias being defined.
 
 We have an ABI incompatibility due to a reworking of the dirent.c which provides
 opendir() and friends.  You will need to rebuild all libraries to that use

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

Summary of changes:
 ChangeLog |    2 ++
 NEWS      |   16 +++++++++++++++-
 2 files changed, 17 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
Repository: mingw-org-wsl



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

Message: 3
Date: Mon, 17 Jun 2013 17:34:54 +0000
From: "Earnie Boyd" <noreply@sourceforge.net>
Subject: [MinGW-cvs] [git push mingw-org-wsl]Repository: mingw-org-wsl
	branch, 4.0-dev, updated. 16281c42c1f0351fb4cdd2c14307894d1e106fa1
To: mingw-cvs@lists.sourceforge.net
Message-ID:
	<mailman.54533.1371490498.12996.mingw-cvs@lists.sourceforge.net>

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Repository: mingw-org-wsl".

The branch, 4.0-dev has been updated
       via  16281c42c1f0351fb4cdd2c14307894d1e106fa1 (commit)
      from  8614d1f4afc8f7e8d15abbf71ebc0243253c014a (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sf.net/p/mingw/mingw-org-wsl/ci/16281c42c1f0351fb4cdd2c14307894d1e106fa1/

commit 16281c42c1f0351fb4cdd2c14307894d1e106fa1
Author: Earnie Boyd <earnie@users.sourceforge.net>
Date:   Mon Jun 17 13:33:54 2013 -0400

    Further corrections for _wfindfirst* and _wfindnext*.  Work around issue for \
__CRT_MAYBE_INLINE when __NO_INLINE__ defined.

diff --git a/ChangeLog b/ChangeLog
index 2b7abc9..265696e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2013-06-17  Earnie Boyd  <earnie@users.sourceforge.net>
+
+	* include/_mingw.h (__CRT_MAYBE_INLINE): When __NO_INLINE__ defined we
+	need to make it _CRTALIAS to avoid auto export issues.
+	* include/io.h (_wfindfirst*, _wfindnext*): Remove the __NO_INLINE__
+	filter and use __CRT_MAYBE_INLINE definitions.
+	* include/wchar.h (_wfindfirst*, _wfindnext*): Correct the declarations.
+	(_wfindfirst32i64, _wfindfirst64i32, _wfindnext32i64, _wfindnext64i32):
+	Define as __CRT_MAYBE_INLINE.
+
 2013-06-16  Earnie Boyd  <earnie@users.sourceforge.net>
 
 	* NEWS: Add text for MSVCRT_VERSION and for the _CRTALIAS 32bit time_t
diff --git a/include/_mingw.h b/include/_mingw.h
index eb7c41f..765c60e 100644
--- a/include/_mingw.h
+++ b/include/_mingw.h
@@ -210,7 +210,7 @@
 #ifndef __NO_INLINE__
 #define __CRT_MAYBE_INLINE __CRT_INLINE
 #else /* def __NO_INLINE__ */
-#define __CRT_MAYBE_INLINE
+#define __CRT_MAYBE_INLINE _CRTALIAS /* We need to inline to stop auto-export */
 #endif /* ndef __NO_INLINE__ */
 
 #ifdef __cplusplus
diff --git a/include/io.h b/include/io.h
index 6581094..3f32528 100644
--- a/include/io.h
+++ b/include/io.h
@@ -428,9 +428,8 @@ _CRTIMP int __cdecl __MINGW_NOTHROW _wfindnext64(intptr_t, struct \
_wfinddata64_t  int  __cdecl __MINGW_NOTHROW	_wfindnext32i64 (intptr_t, struct \
_wfinddata32i64_t*);  int  __cdecl __MINGW_NOTHROW	_wfindnext64i32 (intptr_t, struct \
_wfinddata64i32_t*);  
-#ifndef __NO_INLINE__
 #include <string.h>
-__CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _wfindfirst32i64(const wchar_t* \
_filename, struct _wfinddata32i64_t* _fdata) { +__CRT_MAYBE_INLINE __cdecl \
__MINGW_NOTHROW intptr_t _wfindfirst32i64(const wchar_t* _filename, struct \
_wfinddata32i64_t* _fdata) {  struct _wfinddata64_t fd;
     intptr_t ret = _wfindfirst64(_filename, &fd);
     if (ret == -1) {
@@ -446,7 +445,7 @@ __CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t \
_wfindfirst32i64(const wchar_t* _f  return ret;
 }
 
-__CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _wfindfirst64i32(const wchar_t* \
_filename, struct _wfinddata64i32_t* _fdata) { +__CRT_MAYBE_INLINE __cdecl \
__MINGW_NOTHROW intptr_t _wfindfirst64i32(const wchar_t* _filename, struct \
_wfinddata64i32_t* _fdata) {  struct _wfinddata32_t fd;
     intptr_t ret = _wfindfirst32(_filename, &fd);
     if (ret == -1) {
@@ -462,7 +461,7 @@ __CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t \
_wfindfirst64i32(const wchar_t* _f  return ret;
 }
 
-__CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _wfindnext32i64(intptr_t _fp, struct \
_wfinddata32i64_t* _fdata) { +__CRT_MAYBE_INLINE __cdecl __MINGW_NOTHROW intptr_t \
_wfindnext32i64(intptr_t _fp, struct _wfinddata32i64_t* _fdata) {  struct \
_wfinddata64_t fd;  int ret = _wfindnext64(_fp,&fd);
     if (ret == -1) {
@@ -478,7 +477,7 @@ __CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t \
_wfindnext32i64(intptr_t _fp, stru  return ret;
 }
 
-__CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _wfindnext64i32(intptr_t _fp, struct \
_wfinddata64i32_t* _fdata) { +__CRT_MAYBE_INLINE __cdecl __MINGW_NOTHROW intptr_t \
_wfindnext64i32(intptr_t _fp, struct _wfinddata64i32_t* _fdata) {  struct \
_wfinddata32_t fd;  int ret = _wfindnext32(_fp, &fd);
     if (ret == -1) {
@@ -494,22 +493,6 @@ __CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t \
_wfindnext64i32(intptr_t _fp, stru  return ret;
 }
 
-#else /* def __NO_INLINE__ */
-#define _findfirst64i32 _findfirst64
-#define _finddata64i32_t __finddata64_t
-#define _findfirst32i64 _findfirst32
-#define _finddata32i64_t _finddata32_t
-#define _findnext64i32 _findnext64
-#define _findnext32i64 _findnext32
-
-#define _wfindfirst64i32 _wfindfirst64
-#define _wfindnext64i32 _wfindnext64
-#define _wfinddata64i32_t _wfinddata64_t
-#define _wfindfirst32i64 _wfindfirst32
-#define _wfindnext32i64 _wfindnext32
-#define _wfinddata32i64_t _wfinddata32_t
-#endif /* ndef __NO_INLINE__ */
-
 #endif /* _WIO_DEFINED */
 
 #ifndef	_NO_OLDNAMES
diff --git a/include/wchar.h b/include/wchar.h
index 0efaedc..233941c 100644
--- a/include/wchar.h
+++ b/include/wchar.h
@@ -489,25 +489,90 @@ _CRTIMP int __cdecl __MINGW_NOTHROW	_wunlink (const wchar_t*);
 _CRTIMP int __cdecl __MINGW_NOTHROW	_wopen (const wchar_t*, int, ...);
 _CRTIMP int __cdecl __MINGW_NOTHROW	_wsopen (const wchar_t*, int, int, ...);
 _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wmktemp (wchar_t*);
-_CRTIMP long __cdecl __MINGW_NOTHROW	_wfindfirsti64 (const wchar_t*, struct \
_wfinddatai64_t*); +_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wfindfirst (const \
wchar_t*, struct _wfinddata32_t*); +_CRTIMP intptr_t __cdecl \
__MINGW_NOTHROW	_wfindfirsti64 (const wchar_t*, struct _wfinddatai64_t*);  _CRTIMP \
                int __cdecl __MINGW_NOTHROW 	_wfindnexti64 (long, struct \
                _wfinddatai64_t*);
-_CRTIMP long __cdecl __MINGW_NOTHROW	_wfindfirst32i64 (const wchar_t*, struct \
                _wfinddata32i64_t*);
-_CRTIMP long __cdecl __MINGW_NOTHROW	_wfindfirst64i32 (const wchar_t*, struct \
                _wfinddata64i32_t*);
-_CRTIMP int  __cdecl __MINGW_NOTHROW	_wfindnext32i64 (long, struct \
                _wfinddata32i64_t*);
-_CRTIMP int  __cdecl __MINGW_NOTHROW	_wfindnext64i32 (long, struct \
_wfinddata64i32_t*); +intptr_t __cdecl __MINGW_NOTHROW	_wfindfirst32i64 (const \
wchar_t*, struct _wfinddata32i64_t*); +intptr_t __cdecl \
__MINGW_NOTHROW	_wfindfirst64i32 (const wchar_t*, struct _wfinddata64i32_t*); \
+_CRTIMP int  __cdecl __MINGW_NOTHROW _wfindnext (intptr_t, struct _wfinddata32_t*); \
+int  __cdecl __MINGW_NOTHROW	_wfindnext32i64 (intptr_t, struct _wfinddata32i64_t*); \
+int  __cdecl __MINGW_NOTHROW	_wfindnext64i32 (intptr_t, struct _wfinddata64i32_t*);  \
_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wfindfirst64(const wchar_t*, struct \
_wfinddata64_t*);  _CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wfindnext64(intptr_t, \
struct _wfinddata64_t*);  
 /* _wfindfirst32 and _wfindnext32 do not exist in MSVCRT.DLL */
 _CRTALIAS intptr_t __cdecl __MINGW_NOTHROW _wfindfirst32 (const wchar_t* _v1, struct \
                _wfinddata32_t* _v2) {
-    _CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wfindfirst (const wchar_t*, struct \
_wfinddata32_t*);  return _wfindfirst(_v1, _v2);
 }
 _CRTALIAS int  __cdecl __MINGW_NOTHROW	_wfindnext32 (intptr_t _v1, struct \
                _wfinddata32_t* _v2) {
-    _CRTIMP int  __cdecl __MINGW_NOTHROW _wfindnext (intptr_t, struct \
_wfinddata32_t*);  return _wfindnext(_v1, _v2);
 }
 
+#include <string.h>
+__CRT_MAYBE_INLINE __cdecl __MINGW_NOTHROW intptr_t _wfindfirst32i64(const wchar_t* \
_filename, struct _wfinddata32i64_t* _fdata) { +    struct _wfinddata64_t fd;
+    intptr_t ret = _wfindfirst64(_filename, &fd);
+    if (ret == -1) {
+        memset(_fdata, 0, sizeof(struct _wfinddata64_t));
+        return ret;
+    }
+    _fdata->attrib = fd.attrib;
+    _fdata->time_create = (__time32_t)fd.time_create;
+    _fdata->time_access = (__time32_t)fd.time_access;
+    _fdata->time_write  = (__time32_t)fd.time_write;
+    _fdata->size        = fd.size;
+    wcsncpy(_fdata->name, fd.name, FILENAME_MAX);
+    return ret;
+}
+
+__CRT_MAYBE_INLINE __cdecl __MINGW_NOTHROW intptr_t _wfindfirst64i32(const wchar_t* \
_filename, struct _wfinddata64i32_t* _fdata) { +    struct _wfinddata32_t fd;
+    intptr_t ret = _wfindfirst32(_filename, &fd);
+    if (ret == -1) {
+        memset(_fdata, 0, sizeof(struct _wfinddata32_t));
+        return ret;
+    }
+    _fdata->attrib = fd.attrib;
+    _fdata->time_create = (__time64_t)fd.time_create;
+    _fdata->time_access = (__time64_t)fd.time_access;
+    _fdata->time_write  = (__time64_t)fd.time_write;
+    _fdata->size        = fd.size;
+    wcsncpy(_fdata->name, fd.name, FILENAME_MAX);
+    return ret;
+}
+
+__CRT_MAYBE_INLINE __cdecl __MINGW_NOTHROW intptr_t _wfindnext32i64(intptr_t _fp, \
struct _wfinddata32i64_t* _fdata) { +    struct _wfinddata64_t fd;
+    int ret = _wfindnext64(_fp,&fd);
+    if (ret == -1) {
+      memset(_fdata, 0, sizeof(struct _wfinddata32i64_t));
+      return ret;
+    }
+    _fdata->attrib = fd.attrib;
+    _fdata->time_create = (__time32_t)fd.time_create;
+    _fdata->time_access = (__time32_t)fd.time_access;
+    _fdata->time_write  = (__time32_t)fd.time_write;
+    _fdata->size        = fd.size;
+    wcsncpy(_fdata->name, fd.name, FILENAME_MAX);
+    return ret;
+}
+
+__CRT_MAYBE_INLINE __cdecl __MINGW_NOTHROW intptr_t _wfindnext64i32(intptr_t _fp, \
struct _wfinddata64i32_t* _fdata) { +    struct _wfinddata32_t fd;
+    int ret = _wfindnext32(_fp, &fd);
+    if (ret == -1) {
+      memset(_fdata, 0, sizeof(struct _wfinddata64i32_t));
+      return ret;
+    }
+    _fdata->attrib = fd.attrib;
+    _fdata->time_create = (__time64_t)fd.time_create;
+    _fdata->time_access = (__time64_t)fd.time_access;
+    _fdata->time_write  = (__time64_t)fd.time_write;
+    _fdata->size        = fd.size;
+    wcsncpy(_fdata->name, fd.name, FILENAME_MAX);
+    return ret;
+}
+
 #if defined(_USE_32BIT_TIME_T)
 #define _wfinddata_t _wfinddata32_t
 #define _wfinddatai64_t _wfinddata32i64_t

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

Summary of changes:
 ChangeLog        |   10 +++++++
 include/_mingw.h |    2 +-
 include/io.h     |   25 +++--------------
 include/wchar.h  |   79 +++++++++++++++++++++++++++++++++++++++++++++++++-----
 4 files changed, 87 insertions(+), 29 deletions(-)


hooks/post-receive
-- 
Repository: mingw-org-wsl



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

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev

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

_______________________________________________
MinGW-cvs mailing list
MinGW-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-cvs


End of MinGW-cvs Digest, Vol 62, Issue 4
****************************************


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic