public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* kbuild news
@ 2002-10-06  2:10 Kai Germaschewski
  2002-10-07  8:08 ` David S. Miller
  0 siblings, 1 reply; 9+ messages in thread
From: Kai Germaschewski @ 2002-10-06  2:10 UTC (permalink / raw)
  To: linux-kernel


Hi arch maintainers,

I submitted a kbuild update to Linus which has the potential to break 
archs other than i386.

Two changes could affect you:
o the build process, while remaining recursive, does not cd into the 
  subdirs anymore. If you're just using the standard kbuild 
  infrastructure, you should be fine - however, things like
  custom include paths may have to be adapted
  (-I../../drivers/scsi -> -Idrivers/scsi).
  This change should not affect arch/$(ARCH)/boot and other custom stuff.
  However, I converted i386/boot as well, to give an example of how it can
  be done ;)

  If something goes wrong here, you'll most likely get a build failure,
  so you'll notice. The other point is a bit more subtle.

o The final link of vmlinux is now always done as a two step process:
  link a temporary .tmp_vmlinux out of $(HEAD) init/ kernel/ mm/ drivers/
  ... exactly as before. Then, potentially objects which need the
  vmlinux image to exist already are built (currently that would be
  .tmp_kallsyms.o, and possibly sparc's btfix stuff in the future).
  As a last step, the final vmlinux is linked from the .tmp_vmlinux +
  the additional objects that have just been built.

  Even when no kallsyms or other additional objects are built, the final
  vmlinux is now built with

  	ld <usual flags> -T arch/$(ARCH)/vmlinux.lds.s .tmp_vmlinux \
		-o vmlinux

  So you need to be sure that your arch's vmlinux.lds.S does not
  reorder sections in this final step.

  i386 needed the following patch:

--- ../linux-2.5.isdn/arch/i386/vmlinux.lds.S	Fri Oct  4 12:09:10 2002
+++ arch/i386/vmlinux.lds.S	Sat Oct  5 17:21:30 2002
@@ -49,6 +49,7 @@
   __setup_end = .;
   __initcall_start = .;
   .initcall.init : {
+	*(.initcall.init)
 	*(.initcall1.init) 
 	*(.initcall2.init) 
 	*(.initcall3.init) 
@@ -72,7 +73,7 @@
   __nosave_end = .;
 
   . = ALIGN(4096);
-  .data.page_aligned : { *(.data.idt) }
+  .data.page_aligned : {  *(.data.page_aligned) *(.data.idt) }
 
   . = ALIGN(32);
   .data.cacheline_aligned : { *(.data.cacheline_aligned) }
 
since after the first link, all the initcalls are in .initcall.init, and
they're supposed to just remain there during the second one, same thing 
for data.page_aligned.

You've been warned, take a look at your vmlinux.lds.S, or just compare
objdump -h .tmp_vmlinux vs objdump -h vmlinux. You don't want to see 
differences there ;)

--Kai





^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2002-10-08 20:21 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <mailman.1034070360.25457.linux-kernel2news@redhat.com>
2002-10-08 14:42 ` kbuild news Pete Zaitcev
2002-10-08 20:11   ` David S. Miller
2002-10-08 20:25     ` Pete Zaitcev
2002-10-06  2:10 Kai Germaschewski
2002-10-07  8:08 ` David S. Miller
2002-10-07 14:22   ` Kai Germaschewski
2002-10-07 14:24     ` David S. Miller
2002-10-07 14:35       ` Kai Germaschewski
2002-10-08  9:39       ` Keith Owens

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox