From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <199711061407.JAA04950@cti2.cog-tech.com> Date: Thu, 6 Nov 1997 09:07:23 -0500 From: Bryan B. Thompson Subject: Re: compiling problem Well, The message is serious and will cause problem (the code will not compile correctly). I have not tried a from-scratch kernel, so I can't speak to the particular problems. Attached is a recent message from this list that covers the options for compiling a new kernel. I would make sure that I was on one of the covered paths. -- bryan Return-Path: Resent-Cc: recipient list not shown: ; MBOX-Line: From axp-list-request@redhat.com Thu Oct 30 05:15:51 1997 Date: Thu, 30 Oct 1997 12:15:36 +0200 From: "Harvey J. Stein" MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: axp-list@redhat.com Subject: Basic Alpha Patch & Kernel Notes & Info (someone please add this to a FAQ!!!) Resent-From: axp-list@redhat.com Reply-To: axp-list@redhat.com X-Mailing-List: archive/latest/9840 X-Loop: axp-list@redhat.com Precedence: list Resent-Sender: axp-list-request@redhat.com X-URL: http://www.redhat.com Basic Alpha Patch & Kernel Notes & Info Someone please add this to a FAQ!!! Someone in the know please check this for ACCURACY!!! Thanks to Richard Henderson for explaining it all in the first place. I'm just wanted to put all the pieces together into one msg which is easy to find in the axp-list archives. Facts: 1. Stock kernel headers are *not* compatible with the glibc headers that comes with Redhat alpha 4.2 (which is glibc 1.9). 2. Stock kernel headers are compatible with the glibc2 headers. 3. glibc2 is not compatible with the binaries that come with Redhat alpha 4.2. 4. The kernel RPM from Redhat 4.2 patches the kernel headers to make it compatible with glibc 1.9. 5. The other available kernel patches (except as noted below) also make the kernel compatible with glibc 1.9. Patch descriptions: Note - All patches are to be applied to a pristine 2.0.30, except as noted. ftp://ftp.azstarnet.com/pub/linux/axp/sys/axp-diffs-2.0.30.gz -Various fixes for 2.0.30. -Modifies the kernel headers to make them compatible with glibc 1.9. ftp://ftp.digital.com/pub/DEC/Linux-Alpha/em86/v0.2/kernel-patches/alpha-patches-2.0.30-0.2a.gz -Includes the above, plus additional bug fixes, plus enhancements needed for em86. -Breaks trap handling - running programs with lots of unaligned access could crash the machine. Kernel which comes with Redhat 4.2: -A patched version of 2.0.30. Kernel headers are patched to be compatible with glibc 1.9 headers. Includes some, but not all of alpha-patches-2.0.30-0.2a.gz, but *does* include the trap handling bug. ftp://genie.ucd.ie/pub/alpha/kernel/alpha-patchset.tar.gz -Includes several patches: alpha-patches-0.2-glibc2.diff -This is alpha-patches-2.0.30-0.2 (*not* 0.2a), but modified to apply to 2.0.30-pre.10, except that it *doesn't* modify kernel headers for glibc 1.9. ap-0.2-fixes-1.diff -Fixes to alpha-patches-0.2-glibc2.diff. In particular, fixes the trap handling. Kernel compilation possibilities: 1. Using stock kernels on RH 4.2 systems: The stock kernel headers are incompatible with the supplied glibc. However, you can work around this by leaving the symlink in /usr/src/linux pointing to the kernel source tree that comes with RH 4.2. 2. Using patches from ftp.azatartnet.com or ftp.digital.com: Apply one or the other, but *not* both to a pristine 2.0.30, *not* the 2.0.30 that comes with Redhat 4.2. 3. Using patches from genie.ucd.ie: Get the original 2.0.30 and apply 2.0.30-pre.10 first. Then you can apply alpha-patches-0.2-glibc2.diff, and if you desire, you can also apply ap-0.2-fixes-1.diff, or components of it which are available on the ftp server. See the ftp server for details. If you do this, you either need to be using glibc2 or you need to leave the /usr/src/linux symlink pointing at the old kernel source tree. 4. 2+3 combo: You can apply alpha-patches-2.0.30-0.2a.gz from ftp.digital.com to a pristine 2.0.30, and then apply ap-0.2-fixes-1.diff. This seems to work fine, and the kernel header files should be compatible with redhat 4.2 (although I've left /usr/src/linux pointing to the old tree anyway). If you do this, then you'll get one reject from the ap-0.2-fixes-1.diff patch. I think applying it by hand should be ok. Just added result = -EIO; to the NOT_READY & ILLEGAL_REQUEST cases in drivers/scsi/sr_ioctl.c. WARNING - Remember that kernel sources unpack into /usr/src/linux, so if you have a /usr/src/linux symlink, you'll need to remove it, unpack the kernel, and put back the symlink. Kernel compilation details: It seems that with the Redhat glibc one can use both unpatched and patched kernels, as long as one keeps a /usr/src/linux symlink to the Redhat kernel source tree. So, we get the following procedure for those using Redhat's glibc (glibc 1.9). Those brave enough to use glibc2 can probably figure out what they need to do on their own or via the glibc2 HowTos. Step by step notes: 0. cd to the /usr/src directory. 1. If you have a linux symlink, remove it. If you have a linux subdirectory, rename it to something like linux-redhat. If you have something else there, I'll call it linux-redhat for the rest of these instructions. 2. Untar linux-2.0.30.tar.gz. 3. Rename linux to linux-2.0.30. 4. Make a symlink from linux back to linux-redhat. 5. cd /usr/src/linux-2.0.30 (for the rest of these instructions). 5. If you're *not* going to patch the kernel, then edit the Makefile, changing ARCH=i386 to ARCH=alpha. 6. Apply patches as noted above. 7. make mrproper 8. make xconfig This seems to work for me, except that tkparse complains about not recognizing the "unset" commands in arch/alpha/config.in. I don't know how serious this is. 9. Save to a file if you so desire. 10. Save & exit. 11. make dep clean 12. make boot 13. cp arch/alpha/boot vmlinux.gz /vmlinux-2.0.30-my-very-own.gz 14. reboot with /vmlinux-2.0.30-my-very-own.gz. I hope this helps clarify things, and I hope I got it right. Good luck, -- Harvey J. Stein Berger Financial Research hjstein@bfr.co.il -- To unsubscribe: send e-mail to axp-list-request@redhat.com with 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com -- To unsubscribe: send e-mail to axp-list-request@redhat.com with 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com