Subject: JDK for Netwinder + glibc 2.1.2?

From: Chris Price <[email-masked]>
Date: Tue, 13 Jun 2000 16:38:52 -0600

Hi;

	I am looking for a jdk/jre 1.1.8 or newer that will run on my
netwinder. I am running the dm-3.1-15 disk image, which has gcc2.95 and
glibc-2.1.2.

	The jdk-1.1.8 from blackdown is seemingly compiled against glibc2.0 ->
the binaries will not even run on my system.

	Any help you can provide will be appreciated.

	Cheers

	Chris Price

---

From: Chris Price <[email-masked]>
Date: Wed, 14 Jun 2000 08:14:18 -0600

Ralph Siemsen wrote:
> Chris Price wrote:
> You can trick the old one into running by making symlinks for the old
> dynamic loader, ld.so.1 ->ld-linux.so.

	So in /lib I created the softlink that you instructed:

lrwxrwxrwx   1 root     root   13 Jun 14 07:52 ld.so.1 -> ld-linux.so.2

	And I ran ldconfig after I created the softlink.

	But I still get the same result when I try to run the java binary:

[root@kewl green_threads]# ls -l java
-rwxr-xr-x   1 cprice   cprice      11355 Aug 20  1999 java
[root@kewl green_threads]# ./java
bash: ./java: No such file or directory
[root@kewl green_threads]# pwd
/usr/local/jdk118_v1/bin/armv4l/green_threads

	Any ideas?

	Cheers

	Chris

---

From: Dan Malek <[email-masked]>
Date: Wed, 14 Jun 2000 16:16:58 -0400

> /usr/local/jdk118_v1/bin/armv4l/green_threads

This is a little strange.  Is 'java' a script of some kind that is
requesting to load some interpreter (#!/bin/sh, or #!/usr/bin/perl)
that doesn't exist?

	-- Dan

unsubscribe: body of `unsubscribe linux-arm' to [email-masked]
++        Please use [email-masked] for           ++
++                        kernel-related discussions.                      ++

---

From: <[email-masked]>
Date: Wed, 14 Jun 2000 14:30:07 -0600 (MDT)

> requesting to load some interpreter (#!/bin/sh, or #!/usr/bin/perl)

	The java file I am trying to run above seems to be a binary:

[root@kewl green_threads]# file java
java: ELF 32-bit LSB executable, Advanced RISC Machines ARM, version 1,
dynamically linked (uses shared libs), not stripped

	But when I try to run it:

[root@kewl green_threads]# ls -l java
-rwxrwxrwx   1 cprice   cprice      11355 Aug 20  1999 java
[root@kewl green_threads]# ./java
bash: ./java: No such file or directory

	I am really lost on this one. ld and ls say its there, and that it
is proper format, but it simply will not run.

---

From: Ralph Siemsen <[email-masked]>
Date: Wed, 14 Jun 2000 16:30:38 -0400

> lrwxrwxrwx   1 root     root   13 Jun 14 07:52 ld.so.1 -> ld-linux.so.2

The path changed as well - the linker used to be in /usr/lib/ld.so.1
(which of course meant that /usr could not be on a different partition),
and old binaries go looking for it there.  So you need to make the link
like so:

	ln -s ../../lib/ld-linux.so.2 /usr/lib/ld.so.1
 
>         And I ran ldconfig after I created the softlink.

That isn't necessary actually - no libraries were added, so the
ld.so.cache is correct.

-- 
Ralph Siemsen -- [email-masked]

---

From: Jon Olson <[email-masked]>
Date: Wed, 14 Jun 2000 13:37:43 -0700

>bash: ./java: No such file or directory

This is caused because it was dynamically linked with a `ld.so' that's
no longer there.  Type `ldd java' and see what dynamic linker it wants.
If you create a symlink to the dynamic linker you have it MAY work.
Otherwise, you'll need to get the old ld.so.

-- 
Jon Olson, Modular Mining Systems
	   3289 E. Hemisphere Loop
	   Tucson, AZ 85706
INTERNET:  [email-masked]
PHONE:     (520)746-9127
FAX:       (520)889-5790

---

From: "Hanske;Stefan" <[email-masked]>
Date: Wed, 14 Jun 2000 22:55:55 +0200 (METDST)

> /usr/local/jdk118_v1/bin/armv4l/green_threads

Try ldd on that binary, it will show you what dynamic objects are missing
or try strace (the output is more complicated but more usable, it shows
all the search paths, too).

---

From: <[email-masked]>
Date: Wed, 14 Jun 2000 15:14:22 -0600 (MDT)

> all the search paths, too).

	OK, so I tried strace and ldd on the actual java binary (not the
softlink to .java_wrapper)

[root@kewl green_threads]# ldd java
/usr/bin/ldd: ./java: No such file or directory

[root@kewl green_threads]# strace java
strace: java: command not found

[root@kewl green_threads]# strace ./java
execve("./java", ["./java"], [/* 23 vars */]) = 0
strace: exec: No such file or directory

[root@kewl green_threads]# ldd ./java
/usr/bin/ldd: ./java: No such file or directory
[root@kewl green_threads]# 

	Still confused, but VERY appreciative of everyone's help :)

	Chris

---

From: Scott Bambrough <[email-masked]>
Date: Wed, 14 Jun 2000 17:24:35 -0400

Try the following on the java binary:

LD_DEBUG=files ./java

This will force the dynamic linker to output debug information on the libraries
it is attempting to load.  Other options are available.  Use LD_DEBUG=help
./java for a screen full of info.  Setting LD_DEBUG_OUTPUT=<filename> sends the
output to a file, rather than the console.

Scott

-- 
Scott Bambrough - Software Engineer
REBEL.COM    http://www.rebel.com
NetWinder    http://www.netwinder.org

---

From: Philip Blundell <[email-masked]>
Date: Wed, 14 Jun 2000 22:34:05 +0100

>softlink to .java_wrapper)

As you've discovered, neither strace nor ldd will work if the binary can't be 
exec'd (which happens if the interpreter is missing).  You can find the 
interpreter's name with `readelf -l' or, usually, at a pinch with 
`strings | head -1'.

p.

---

From: Ralph Siemsen <[email-masked]>
Date: Wed, 14 Jun 2000 09:11:07 -0400

---

From: Stephen Crocker <[email-masked]>
Date: Sat, 17 Jun 2000 11:08:25 +0100

Before being shot for writing message <[email-masked]>

> /usr/local/jdk118_v1/bin/armv4l/green_threads

This always seems to happen when I use binaries compiled for armv4l.  I a
lways assumed that it was because the binary was for a different ARM version 
(mine registers as armv3l).

-- 
 x^      ( )      _________         //    Email: mailto:[email-masked]
<       U O      |_|_|_|_|_|    O  ||      WWW:  http://www.crok.demon.co.uk
 \,     |/|\      _________       [  ]             
     .  |/^\  .       2       .   /__\
.. Only in your dreams, Commander.  Troi