X-Authentication-Warning: delorie.com: mail set sender to djgpp-workers-bounces using -f X-Recipient: djgpp-workers AT delorie DOT com Message-ID: <47FC3D57.7090505@iki.fi> Date: Wed, 09 Apr 2008 06:51:51 +0300 From: Andris Pavenis User-Agent: Thunderbird 2.0.0.12 (X11/20080226) MIME-Version: 1.0 To: djgpp-workers AT delorie DOT com Subject: Re: gcc-4.3.0 References: <47FBCF0E DOT 8090208 AT iki DOT fi> <200804090126 DOT m391QTgA009970 AT envy DOT delorie DOT com> In-Reply-To: <200804090126.m391QTgA009970@envy.delorie.com> Content-Type: multipart/mixed; boundary="------------080604020101090001020807" Reply-To: djgpp-workers AT delorie DOT com This is a multi-part message in MIME format. --------------080604020101090001020807 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit DJ Delorie wrote: >> One could try to build current CVS version of djdev with it. Attached 2 completely >> untested patches to fix some strict-aliasing warning related problems. > > Well, one attached. The other isn't a patch. The patch one is OK though. > >> --------------070407090706030207040607 >> Content-Type: text/x-patch; >> name="libc_dos_dir.diff" >> Content-Transfer-Encoding: 7bit >> Content-Disposition: inline; >> filename="libc_dos_dir.diff" >> >> Repository : :pserver:andris AT cvs DOT delorie DOT com:/cvs/djgpp >> Module : djgpp/src/libc/dos/dir >> Working dir: ~/Build/rpm-root/BUILD/djgpp/src/libc/dos/dir/ >> >> >> >> In directory .: >> Up-To-Date 1.1 .cvsignore >> Modified 1.5 findfirs.c Sorry. Saved wrong buffer from Emacs... Attached correct content now. Andris --------------080604020101090001020807 Content-Type: text/x-patch; name="libc_dos_dir.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="libc_dos_dir.diff" Index: findfirs.c =================================================================== RCS file: /cvs/djgpp/djgpp/src/libc/dos/dir/findfirs.c,v retrieving revision 1.5 diff -u -r1.5 findfirs.c --- findfirs.c 11 Dec 2007 07:27:39 -0000 1.5 +++ findfirs.c 9 Apr 2008 03:49:41 -0000 @@ -54,11 +54,16 @@ __dpmi_int(0x21, &r); if(!(r.x.flags & 1)) { struct ffblklfn ffblk32; + unsigned long t1; /* Recover results */ dosmemget(__tb+pathlen, sizeof(struct ffblklfn), &ffblk32); ffblk->ff_attrib = (char)ffblk32.fd_attrib; - *(long *)(void *)(&ffblk->ff_ftime) = _Win32_to_DOS(ffblk32.fd_mtime); + + t1 = _Win32_to_DOS(ffblk32.fd_mtime); + ffblk->ff_ftime = t1; + ffblk->ff_fdate = t1 >> 16; + ffblk->ff_fsize = ffblk32.fd_size; strcpy(ffblk->ff_name, ffblk32.fd_longname); strcpy(ffblk->lfn_magic, "LFN32"); @@ -72,8 +77,13 @@ } ffblk->lfn_handle = r.x.ax; - *(long *)(void *)(&ffblk->lfn_ctime) = _Win32_to_DOS(ffblk32.fd_ctime); - *(long *)(void *)(&ffblk->lfn_atime) = _Win32_to_DOS(ffblk32.fd_atime); + t1 = _Win32_to_DOS(ffblk32.fd_ctime); + ffblk->lfn_ctime = t1; + ffblk->lfn_cdate = t1 >> 16; + + t1 = _Win32_to_DOS(ffblk32.fd_atime); + ffblk->lfn_atime = t1; + ffblk->lfn_adate = t1 >> 16; return 0; } Index: findnext.c =================================================================== RCS file: /cvs/djgpp/djgpp/src/libc/dos/dir/findnext.c,v retrieving revision 1.4 diff -u -r1.4 findnext.c --- findnext.c 11 Dec 2007 07:27:39 -0000 1.4 +++ findnext.c 9 Apr 2008 03:49:42 -0000 @@ -47,16 +47,23 @@ __dpmi_int(0x21, &r); if (!(r.x.flags & 1)) { + unsigned long t1; struct ffblklfn ffblk32; /* Recover results */ dosmemget(__tb, sizeof(struct ffblklfn), &ffblk32); ffblk->ff_attrib = (char)ffblk32.fd_attrib; - *(long *)(void *)&ffblk->ff_ftime = _Win32_to_DOS(ffblk32.fd_mtime); + t1 = _Win32_to_DOS(ffblk32.fd_mtime); + ffblk->ff_ftime = t1; + ffblk->ff_fdate = t1 >> 16; ffblk->ff_fsize = ffblk32.fd_size; strcpy(ffblk->ff_name, ffblk32.fd_longname); - *(long *)(void *)&ffblk->lfn_ctime = _Win32_to_DOS(ffblk32.fd_ctime); - *(long *)(void *)&ffblk->lfn_atime = _Win32_to_DOS(ffblk32.fd_atime); + t1 = _Win32_to_DOS(ffblk32.fd_ctime); + ffblk->lfn_ctime = t1; + ffblk->lfn_cdate = t1 >> 16; + t1 = _Win32_to_DOS(ffblk32.fd_atime); + ffblk->lfn_atime = t1; + ffblk->lfn_adate = t1 >> 16; return 0; } --------------080604020101090001020807--