Mail Archives: djgpp-workers/2009/08/01/02:32:07
This is a multi-part message in MIME format.
--------------060408010800020401060207
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
At first fighting with strict aliasing violation warnings from emu387.cc
could be rather big work. Perhaps it is easier to tell GCC not to
complain. The option -fno-strict-aliasing is available beginning from
gcc-2.8.0 if I remember correctly. So unless somebody terribly
wants to build DJGPP v2.04pre with really ancient gcc-2.7.2.1, I guess
it should be OK to apply the patch. Am I right?
There also was type punning related warning from src/compat/mntent/mntent.c.
Does the related patch seem OK?
I already applied some other small patches.
After that (+ telling gcc to stay silent about conflicting parameters
for some builtin functions in libm and using command line option -m32
for building host tools) all seems to build OK using gcc-4.4.1 under
Fedora 11 x86_64.
Andris
--------------060408010800020401060207
Content-Type: text/plain;
name="djgpp-mntent.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
filename="djgpp-mntent.patch"
Index: src/libc/compat/mntent/mntent.c
===================================================================
RCS file: /cvs/djgpp/djgpp/src/libc/compat/mntent/mntent.c,v
retrieving revision 1.10
diff -p -r1.10 mntent.c
*** src/libc/compat/mntent/mntent.c 11 Dec 2007 07:27:39 -0000 1.10
--- src/libc/compat/mntent/mntent.c 1 Aug 2009 06:08:59 -0000
*************** get_netredir_entry(int drive_num)
*** 322,328 ****
{
__dpmi_regs r;
unsigned long tb = __tb;
! unsigned char devname[2];
int i = -1;
r.x.ds = r.x.es = (tb >> 4);
--- 322,334 ----
{
__dpmi_regs r;
unsigned long tb = __tb;
!
! union
! {
! unsigned char ch[2];
! unsigned short s;
! } devname;
!
int i = -1;
r.x.ds = r.x.es = (tb >> 4);
*************** get_netredir_entry(int drive_num)
*** 356,367 ****
/* We have a valid device which is a disk drive (BL = 4).
Pull in the local device name and if that fits our
drive number, get its network name. */
! *(unsigned short *)devname = _farpeekw(dos_mem_base, tb);
/* The local device name may or may not include the
colon (Ralf Brown's Interrupt List). */
! if (devname[0] == '@' + drive_num &&
! (devname[1] == ':' || devname[1] == '\0'))
{
movedata(dos_mem_base, tb + 16,
our_mem_base, (unsigned)mnt_fsname, 128);
--- 362,373 ----
/* We have a valid device which is a disk drive (BL = 4).
Pull in the local device name and if that fits our
drive number, get its network name. */
! devname.s = _farpeekw(dos_mem_base, tb);
/* The local device name may or may not include the
colon (Ralf Brown's Interrupt List). */
! if (devname.ch[0] == '@' + drive_num &&
! (devname.ch[1] == ':' || devname.ch[1] == '\0'))
{
movedata(dos_mem_base, tb + 16,
our_mem_base, (unsigned)mnt_fsname, 128);
--------------060408010800020401060207
Content-Type: text/plain;
name="djgpp-libemu-no-strict-aliasing.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
filename="djgpp-libemu-no-strict-aliasing.patch"
Index: src/libemu/src/makefile
===================================================================
RCS file: /cvs/djgpp/djgpp/src/libemu/src/makefile,v
retrieving revision 1.6
diff -p -r1.6 makefile
*** src/libemu/src/makefile 28 Jul 2003 20:11:45 -0000 1.6
--- src/libemu/src/makefile 1 Aug 2009 06:09:00 -0000
*************** EXTRA_OBJS += emudummy.o
*** 12,18 ****
include $(TOP)/../makefile.inc
%.o : %.cc
! $(XNOPGGPP) -c -fno-exceptions $<
%.o : %.c
$(XNOPGGCC) -c $<
--- 12,18 ----
include $(TOP)/../makefile.inc
%.o : %.cc
! $(XNOPGGPP) -c -fno-exceptions -fno-strict-aliasing $<
%.o : %.c
$(XNOPGGCC) -c $<
--------------060408010800020401060207--
- Raw text -