Port-i386 archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: gcc48, drmkms issues with i386

My previous attempt at "-O0" was masked because subsequent nested Makefile
inclusions reset "COPTS" and "CFLAGS" seems not to be used.  The following
change allowed compiling the relevant bits of pxeboot with "-O0":

+Index: sys/arch/i386/stand/pxeboot/Makefile
+RCS file: /cvsroot/src/sys/arch/i386/stand/pxeboot/Makefile,v
+retrieving revision 1.22
+diff -u -p -r1.22 Makefile
+--- sys/arch/i386/stand/pxeboot/Makefile       15 Jan 2014 22:25:22 -0000      
++++ sys/arch/i386/stand/pxeboot/Makefile       9 Apr 2014 02:22:06 -0000
+@@ -85,6 +85,9 @@ VERSIONFILE= ${.CURDIR}/../pxeboot/versi
+ .include "../Makefile.booters"
++# JDB 201404090220Z - override -Os to find breakage
++COPTS+= -O0
+ release: check_RELEASEDIR
+       ${HOST_INSTALL_FILE} -m ${BINMODE} ${PROG} \
+               ${RELEASEDIR}/${MACHINE}/installation/misc

The resulting binary was about 92KB in size, rather than 64KB, which was
a promising sign.  Its behavior was different, although not successful:

[logged from serial console]
>> NetBSD/x86 PXE boot, Revision 5.1 (from NetBSD 6.99.40)
>> Memory: 574/521904 k
Press return to boot now, any other key for boot menu
booting netbsd - starting in 0 seconds.
PXE BIOS Version 2.1
Using PCI device at bus 1 device 12 function 0
Ethernet address c0:ff:ee:c0:ff:ee

[transcribed from video display]
prot_to_real: can't return to 0001296D

At this point, rather than resetting, the machine instead continued
on to boot from local disk.  Since it has "mbr_bootsel" installed on
disk, the last part of the display actually looked like:

prot_to_real: can't return to 0001296DFn: Diskn
1: Foo
2: Bar

This "pxeboot_ia32.bin" was built with the native (cross) i386 tool-
chain (on netbsd-5/i386 host).  Building some stuff from pkgsrc has
shown me that the i386 gcc48 gets hung up on things that the amd64
gcc48 doesn't.  I'll try the PXE booter built via the amd64 toolchain
next and see if its behavior is different.

|/"\ John D. Baker, KN5UKS               NetBSD     Darwin/MacOS X
|\ / jdbaker[snail]mylinuxisp[flyspeck]com    OpenBSD            FreeBSD
| X  No HTML/proprietary data in email.   BSD just sits there and works!
|/ \ GPGkeyID:  D703 4A7E 479F 63F8 D3F4  BD99 9572 8F23 E4AD 1645

Home | Main Index | Thread Index | Old Index