linux-um archives
 help / color / mirror / Atom feed
From: Rob Landley <rob@landley.net>
To: user-mode-linux-devel@lists.sourceforge.net
Cc: Blaisorblade <blaisorblade@yahoo.it>
Subject: Re: [uml-devel] [PATCH] Ok, I build x86-64 -skas0, and it still segfaults.
Date: Sun, 13 Nov 2005 17:26:21 -0600	[thread overview]
Message-ID: <200511131726.22036.rob@landley.net> (raw)
In-Reply-To: <200511131854.12656.blaisorblade@yahoo.it>

On Sunday 13 November 2005 11:54, Blaisorblade wrote:
> On Sunday 13 November 2005 02:36, Rob Landley wrote:
> > I needed to patch two things to get 2.6.15-rc1 to build on an x86-64
> > system running PLD linux:
> >
> > diff -ru linux-2.6.15-rc1/arch/um/Kconfig.x86_64
> > linux-2.6.15-rc1-new/arch/um/Kconfig.x86_64 ---
> > linux-2.6.15-rc1/arch/um/Kconfig.x86_64 2005-11-13 02:08:34.318108152
> > +0100 +++ linux-2.6.15-rc1-new/arch/um/Kconfig.x86_64 2005-11-13
> > 01:55:47.761861224 +0100 @@ -9,7 +9,7 @@
> >  #XXX: this is so in the underlying arch, but it's wrong!!!
> >  config RWSEM_GENERIC_SPINLOCK
> >   bool
> > - default y
> > + default n
>
> The patch for this (which fixes a couple of other things, too) is attached
> in this thread and has been sent to -mm (cc'ing uml-devel):
>
> [uml-user] 2.6.14.git: user-mode-linux/x86_64 does not build
> [uml-devel] [PATCH 4/9] uml - fixups for "reuse i386 cpu-specific tuning"

The second one doesn't seem related, and I couldn't find the first one in 
2.6.14-mm2 (which is the most recent kernel.org lists)...

> > diff -ru linux-2.6.15-rc1/arch/um/Makefile
> > linux-2.6.15-rc1-new/arch/um/Makefile ---
> > linux-2.6.15-rc1/arch/um/Makefile 2005-11-13 02:08:34.318108152 +0100 +++
> > linux-2.6.15-rc1-new/arch/um/Makefile 2005-11-13 02:01:11.364014056 +0100
> > @@ -107,7 +107,7 @@
> >  prepare: $(ARCH_DIR)/include/kern_constants.h
> >
> >  LINK-$(CONFIG_LD_SCRIPT_STATIC) += -static
> > -LINK-$(CONFIG_LD_SCRIPT_DYN) += -Wl,-rpath,/lib
> > +LINK-$(CONFIG_LD_SCRIPT_DYN) += -Wl,-rpath,/lib64
> >
> >  CPP_MODE-$(CONFIG_MODE_TT) := -DMODE_TT
> >  CONFIG_KERNEL_STACK_ORDER ?= 2
>
> Is that _needed_ on your system? I ask because it always worked and it's
> highly host distro-dependant, I guess.

Yes it's needed.  Otherwise:

  CC      init/version.o
  LD      init/built-in.o
  LD      .tmp_vmlinux1
/usr/bin/ld: warning: ld-linux-x86-64.so.2, needed by /lib64/libc.so.6, not 
found (try using -rpath or -rpath-link)
/lib64/libc.so.6: undefined reference to `_rtld_global@GLIBC_PRIVATE'
/lib64/libc.so.6: undefined reference to `__libc_enable_secure@GLIBC_PRIVATE'
/lib64/libc.so.6: undefined reference to `_rtld_global_ro@GLIBC_PRIVATE'
/lib64/libc.so.6: undefined reference to `_dl_out_of_memory@GLIBC_PRIVATE'
/lib64/libc.so.6: undefined reference to `_r_debug@GLIBC_2.2.5'
/lib64/libc.so.6: undefined reference to `__tls_get_addr@GLIBC_2.3'
/lib64/libc.so.6: undefined reference to `_dl_argv@GLIBC_PRIVATE'
collect2: ld returned 1 exit status
  KSYM    .tmp_kallsyms1.S
nm: '.tmp_vmlinux1': No such file
No valid symbol.
make: *** [.tmp_kallsyms1.S] Bd 1

All that's in /lib on pld is:

[rob@rg4 linux-2.6.14]$ ls -l /lib
razem 0
lrwxrwxrwx  1 root root 12 2005-09-06 12:21 cpp -> /usr/bin/cpp
drwxr-xr-x  2 root root  1 2005-11-05 18:53 firmware
drwxr-xr-x  3 root root 16 2005-11-05 18:53 modules

As opposed to:

[rob@rg4 linux-2.6.14]$ ls -l /lib64 | wc
    103     910    7541

> > Then I ran it with my standard ./linux rootfstype=hostfs rw init=/bin/sh
> > and got the following:
> >
> >
> > Console initialized on /dev/tty0
> > Failed to open 'root_fs', errno = 2
> > VFS: Mounted root (hostfs filesystem).
> > Stub registers -
> >         0 - 9090909090909090
>
> 0x90 is the pad used to fill holes in binaries..., and it's strange it's
> there.

I just applied Jeff's patch.  I dunno what the output means.

Rob


-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel

  reply	other threads:[~2005-11-13 23:26 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-13  1:36 [uml-devel] [PATCH] Ok, I build x86-64 -skas0, and it still segfaults Rob Landley
2005-11-13 17:54 ` Blaisorblade
2005-11-13 23:26   ` Rob Landley [this message]
2005-11-14 19:40     ` Blaisorblade
2005-11-16  3:09       ` Rob Landley
2005-11-18  7:43         ` Blaisorblade
2005-11-18  7:36           ` Rob Landley
2005-11-18  7:58             ` Blaisorblade
2005-11-18  8:58               ` Rob Landley
2005-11-19  0:11               ` [uml-devel] [PATCH] UML x86-64 build fix Rob Landley
2005-11-13 19:32 ` [uml-devel] [PATCH] Ok, I build x86-64 -skas0, and it still segfaults Jeff Dike
2005-11-13 19:20   ` Blaisorblade
2005-11-13 23:32     ` Rob Landley
2005-11-14 15:33       ` Jeff Dike
2005-11-14 21:55       ` Jeff Dike
2005-11-14 23:24         ` Rob Landley
2005-11-14 23:45           ` Rob Landley
2005-11-15  1:38             ` Jeff Dike
2005-11-15  2:18               ` Rob Landley
2005-11-15 22:09         ` Paolo Giarrusso
2005-11-16  0:57           ` Jeff Dike

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200511131726.22036.rob@landley.net \
    --to=rob@landley.net \
    --cc=blaisorblade@yahoo.it \
    --cc=user-mode-linux-devel@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox