Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by audiocolla » Sat, 22 Oct 2005 21:20:43


Hello,

I've been all over the web trying to find help on installing JDK15 on a FreeBSD 5.4 AMD64 machine. This is my last stop before I give up.

Fresh install of FreeBSD w/ports updated.
LINUX_COMPAT enabled in kernel with linprocfs set in fstab.
Dowloaded all source, binary, and patches into /usr/ports/distfiles

I need to know the exact steps to take. When I go /usr/ports/java/jdk15 and type "make" this is what I get:



fi
execv(): Bad address
Error trying to exec /usr/local/linux-sun-jdk1.4.2/bin/javac.
Check if file exists and permissions are set correctly.
gmake[3]: *** [.compile.classlist] Error 1
gmake[3]: Leaving directory `/usr/ports/java/jdk15/work/j2se/make/java/java'
gmake[2]: *** [all] Error 1
gmake[2]: Leaving directory `/usr/ports/java/jdk15/work/j2se/make/java'
gmake[1]: *** [all] Error 1
gmake[1]: Leaving directory `/usr/ports/java/jdk15/work/j2se/make'
gmake: *** [j2se-build] Error 2
*** Error code 2



I was told by someone that I need to install linux-sun-jdk14, so I went to do that. It said it was already installed. I've been searching on the web and everyone says this error is cause csh can not support such a long javac command. Someone told me that I need the linux-java-bootstrap, but I don't know what that is. I also tried to build JDK14 and got the same error above. Can someone please tell me the exact steps to take when installing Native JDK15 on a fresh install of FreeBSD 5.4 AMD64.



Please help a fellow BSD'er in distress,



Tom
_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by audiocolla » Sat, 22 Oct 2005 22:59:18

I tried to install linux-sun-jdk14, it said it's already installed. I go to make jdk15 and I get the error seen below.



This has been already discussed in the list.

Install first the linux-sun-jdk1.4.2 as this will be the bootstrapper
jdk1.5 will be compiled with.

Victor Vacaretu

Hello Tanya,





















--
Best regards,
Victor mailto: XXXX@XXXXX.COM

_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "

 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by hwh » Tue, 25 Oct 2005 10:15:14


try to use native jdk1.4.2 as bootstrapper. Of cause you need
COMPAT_IA32 and lib32 options. I succeeded to install jdk1.5.0-p1 on 5.4R.

--hwh

_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by yuri » Tue, 25 Oct 2005 18:03:07


As far as I remember, jdk14/i386 will not work on amd64. One should use lin=
ux=20
jdk.

Is linprocfs mounted?

[root@hq][/home/yuri]# mount|grep linux
linprocfs on /usr/compat/linux/proc (linprocfs, local)

Can you run /usr/local/linux-sun-jdk1.4.2/bin/java -version ?

=2D-=20
Yuri Khotyaintsev
Institutet f=F6r rymdfysik (IRF), Uppsala
_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by hwh » Tue, 25 Oct 2005 21:29:19


forgot this: you need to replace /usr/lib32/libpthread by
/usr/lib32/libc_r.

_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by audiocolla » Wed, 26 Oct 2005 22:00:23

I've tried just about everything. The linux-sun-jdk14 works. I can javac -version. Linprocfs mounts. I have all the right options in the kernel. I added WITH_LIB32=YES to make.conf. What I'm wondering is, do I have to have current ports (bleeding edge) or is stable ports o.k.? For those who got native jdk15 to work on amd64, are you using stable or current ports? I just saw a post about disabling security in the rc.conf file. I'm going to look into that also... If someone has time maybe could they create a quick and dirty how to on installing native jdk15 on a fresh install of freebsd 5.4 for amd64. I know if ever get this working I'm definitely going to host a how to on this.





forgot this: you need to replace /usr/lib32/libpthread by
/usr/lib32/libc_r.

_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "

_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by audiocolla » Wed, 26 Oct 2005 23:57:08

Yeah, I tried to execute the command by hand in a script. I just get some other different errors. The thing is, I shouldn't have the first error. If other people can install it, why can't I? In theory this is what I'm trying to do on a fresh install. Of course I'm having some problems with installing the new world, but once I get passed that maybe it will work? If someone sees something that I'm missing, please point it out.



Install FreeBSD 5.4 on AMD64.
Create /root/current-supfile


*default host=cvsup7.freebsd.org
*default base=/usr
*default prefix=/usr
*default release=cvs tag=.
*default delete use-rel-suffix
ports-all tag=.

src-all


















Update ports and source files.


# cvsup /root/current-supfile








Create package database.


# pkgdb -F






Upgrade installed ports.


# portupgrade -arR






Rebuild world and kernel, boot in single user mode. GENERIC kernel will have all correct options for Linux binary support.


boot

# fsck

# mount /

# mount ufs

# swapon

# adjkerntz

# cd /usr/src

# make buildworld

# make buildkernel

# make installkernel

Reboot into single user mode (boot )

# fsck

# mount /

# mount ufs

# swapon

# cd /etc

# mergemaster

# make installworld

# mergemaster

# reboot










































Add to /etc/fstab:


linprocfs /usr/compat/linux/proc linprocfs rw 0 0






Add to /etc/make.conf:


WITH_LIB32=YES






Acquire all related Java source, binaries, and patch files. Make sure they are all executable by user and group, then copy to /usr/ports/distfiles.
Navigate to /usr/ports/java/linux-sun-jdk14.


# make

# make install

# make clean

# make distclean














Test java:


# java -version






Navigate to /usr/ports/java/jdk15.


# make

# make install

# make clean

# make distclean

















Have you tried jdk15 on FreeBSD 6.x??

Also if i were you, i'd ask some "popular" person from java@freebsd
to login to your machine and have a close look.

Also, what about the actual shell command that caused the execve() error??

--
-Achilleus




_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by audiocolla » Thu, 27 Oct 2005 00:20:32

Sorry about that, email got jacked up.

Yeah, I tried to execute the command by hand in a script. I just get
some other different errors. The thing is, I shouldn't have the first
error. If other people can install it, why can't I? In theory this is
what I'm trying to do on a fresh install. Of course I'm having some
problems with installing the new world, but once I get passed that maybe
it will work? If someone sees something that I'm missing, please point
it out.

Install FreeBSD 5.4 on AMD64.
1.Create /root/current-supfile
*default host=cvsup7.freebsd.org
*default base=/usr
*default prefix=/usr
*default release=cvs tag=.
*default delete use-rel-suffix
ports-all tag=.
src-all
2. Update ports and source files.

# cvsup /root/current-supfile

3. Create package database.
# pkgdb -F

4. Upgrade installed ports.
# portupgrade -arR

5. Rebuild world and kernel, boot in single user mode. GENERIC kernel will have all correct options for Linux binary support.

# boot
# fsck
# mount /
# mount ufs
# swapon
# adjkerntz
# cd /usr/src
# make buildworld
# make buildkernel
# make installkernel
6. Reboot into single user mode (boot )
# fsck
# mount /
# mount ufs
# swapon
# cd /etc
# mergemaster
# make installworld
# mergemaster
# reboot

7. Add to /etc/fstab:

linprocfs /usr/compat/linux/proc linprocfs rw 0 0

8. Add to /etc/make.conf:

WITH_LIB32=YES

9. Acquire all related Java source, binaries, and patch files. Make sure they are all executable by user and group, then copy to /usr/ports/distfiles.
10. Navigate to /usr/ports/java/linux-sun-jdk14.

# make
# make install
# make clean
# make distclean
11. Test java:

# java -version
12. Navigate to /usr/ports/java/jdk15.

# make
# make install


Have you tried jdk15 on FreeBSD 6.x??

Also if i were you, i'd ask some "popular" person from java@freebsd
to login to your machine and have a close look.

Also, what about the actual shell command that caused the execve()
error??

--
-Achilleus

_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by achil » Thu, 27 Oct 2005 15:46:33

Tanya N kessler Oct 25, 2005 :


^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Dope!!!!!!!!!!
Do you realize that you are not longer on FreeBSD 5.4 ????
Can you do a "uname -a" right now?
For 5.4 you would need smth like:
*default release=cvs tag=RELENG_5
(for stable development branch), or
*default release=cvs tag=RELENG_5_4
(for the "errata" branch, or merely just
*default release=cvs tag=RELENG_5_4_0_RELEASE
(for the release itself).


--
-Achilleus

_______________________________________________
XXXX@XXXXX.COM mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-java
To unsubscribe, send any mail to " XXXX@XXXXX.COM "
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by audiocolla » Thu, 27 Oct 2005 20:48:55

thought maybe I had to run current ports for jdk to work. I did a fresh install last night and cvsup'd with:

*default host=cvsup7.freebsd.org
*default base=/var/db
*default prefix=/usr
*default release=cvs tag=RELENG_5
*default delete use-rel-suffix compress
ports-all tag=.
src-all

I reliezed last night that I have been installing linux_base instead of linux_base-8. I also didn't have: linux_enable="YES" in rc.conf. I tried to build native jdk15 last night, it seemed to stop and hang where it said:

Old database:
computing closures

New database:
reading database: includeDB
computing closures

I think I'm getting closer now, I added: WITH_LIB32=YES to /etc/make.conf and started it before I left for work. I'll see what happens when I get home. Does anyone know if I'm close to getting it installed now?

Achilleus Mantzios < XXXX@XXXXX.COM > wrote:
Yeah, I tried to execute the command by hand in a script. I just get
some other different errors. The thing is, I shouldn't have the first
error. If other people can install it, why can't I? In theory this is
what I'm trying to do on a fresh install. Of course I'm having some
problems with installing the new world, but once I get passed that
maybe
it will work? If someone sees something that I'm missing, please point
it out.

Install FreeBSD 5.4 on AMD64.
1.Create /root/current-supfile
*default host=cvsup7.freebsd.org
*default base=/usr
*default prefix=/usr
*default release=cvs tag=.
*default delete use-rel-suffix
ports-all tag=.
src-all
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Dope!!!!!!!!!!
Do you realize that you are not longer on FreeBSD 5.4 ????
Can you do a "uname -a" right now?
For 5.4 you would need smth like:
*default release=cvs tag=RELENG_5
(for stable development branch), or
*default release=cvs tag=RELENG_5_4
(for the "errata" branch, or merely just
*default release=cvs tag=RELENG_5_4_0_RELEASE
(for the release itself).

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

2. Update ports and source files.

# cvsup /root/current-supfile

3. Create package database.
# pkgdb -F

4. Upgrade installed ports.
# portupgrade -arR

5. Rebuild world and kernel, boot in single user mode. GENERIC kernel
will have all correct options for Linux binary support.

# boot
# fsck
# mount /
# mount ufs
# swapon
# adjkerntz
# cd /usr/src
# make buildworld
# make buildkernel
# make installkernel
6. Reboot into single user mode (boot )
# fsck
# mount /
# mount ufs
# swapon
# cd /etc
# mergemaster
# make installworld
# mergemaster
# reboot

7. Add to /etc/fstab:

linprocfs /usr/compat/linux/proc linprocfs rw 0 0

8. Add to /etc/make.conf:

WITH_LIB32=YES

9. Acquire all related Java source, binaries, and patch files. Make
sure they are all executable by user and group, then copy to
/usr/ports/distfiles.
10. Navigate to /usr/ports/java/linux-sun-jdk14.

# make
# make install
# make clean
# make distclean
11. Test java:

# java -version
12. Navigate to /usr/ports/java/jdk15.

# make
# make install

Achilleus Mantzios < XXXX@XXXXX.COM > wrote:
Have you tried jdk15 on FreeBSD 6.x??

Also if i were you, i'd ask some "popular" person from java@freebsd
to login to your machine and have a close look.

Also, what about the actual shell command that caused the execve()
error??

--
-Achilleus
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by audiocolla » Fri, 28 Oct 2005 10:42:08

.K., I am back to square one. I have:

COMPAT_IA32
COMPAT_LINUX32
LINPROCFS

all in kernel. I have:

linprocfs /usr/compat/linux/proc linprocfs rw 0 0 in
fstab. I have:

linux_enable="YES" in rc.conf. I have:

WITH_LIB32 in /etc/make.conf I have:

linux-sun-jdk14 installed and javac works so does java
-version. I have:

necessary files needed to build native jdk15 in
/usr/ports/distfiles.

When I try to build native jdk15, I get this:

execv(): Bad address
Error trying to exec
/usr/local/linux-sun-jdk1.4.2/bin/javac.
Check if file exists and permissions are set
correctly.
gmake[3]: *** [.compile.classlist] Error 1
gmake[3]: Leaving directory
`/usr/ports/java/jdk15/work/j2se/make/java/java'
gmake[2]: *** [all] Error 1
gmake[2]: Leaving directory
`/usr/ports/java/jdk15/work/j2se/make/java'
gmake[1]: *** [all] Error 1
gmake[1]: Leaving directory
`/usr/ports/java/jdk15/work/j2se/make'
gmake: *** [j2se-build] Error 2
*** Error code 2

When I try to run the failed command by hand in
/usr/ports/java/jdk15/work/j2se/make/java/java I get
this:

../../../src/share/classes/java/io/ObjectStreamClass.java:869:
warning: non-varargs call of varargs method with
inexact argument type for last parameter;
cast to java.lang.Object for a varargs call
cast to java.lang.Object[] for a non-varargs call and
to suppress this warning
return cons.newInstance(null);
^
../../../src/share/classes/java/io/ObjectStreamClass.java:949:
warning: non-varargs call of varargs method with
inexact argument type for last parameter;
cast to java.lang.Object for a varargs call
cast to java.lang.Object[] for a non-varargs call and
to suppress this warning
readObjectNoDataMethod.invoke(obj,
null);
^
../../../src/share/classes/java/io/ObjectStreamClass.java:977:
warning: non-varargs call of varargs method with
inexact argument type for last parameter;
cast to java.lang.Object for a varargs call
cast to java.lang.Object[] for a non-varargs call and
to suppress this warning
return writeReplaceMethod.invoke(obj,
null);

^
../../../src/share/classes/java/io/ObjectStreamClass.java:1006:
warning: non-varargs call of varargs method with
inexact argument type for last parameter;
cast to java.lang.Object for a varargs call
cast to java.lang.Object[] for a non-varargs call and
to suppress this warning
return readResolveMethod.invoke(obj,
null);
^
../../../src/share/classes/sun/misc/ProxyGenerator.java:335:
warning: non-varargs call of varargs method with
inexact argument type for last parameter;
cast to java.lang.Class for a varargs call
cast to java.lang.Class[] for a non-varargs call and
to suppress this warning
hashCodeMethod =
Object.class.getMethod("hashCode", null);

^
../../../src/share/classes/sun/misc/ProxyGenerator.java:338:
warning: non-varargs call of varargs method with
inexact argument type for last parameter;
cast to java.lang.Class for a varargs call
cast to java.lang.Class[] for a non-varargs call and
to suppress this warning
toStringMethod =
Object.class.getMethod("toString", null);
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by xelah-free » Fri, 28 Oct 2005 20:04:45


[snip compiler warnings]

That command completed - but with some warnings. You should be able to go
back to the port and run make again now. IIRC I got something similar when
I compiled the JDK, though I don't remember having to run a command by
hand in that particular directory.

Oh, and I had to turn SMP off to get it to compile. The Linux javac went
in to an infinite loop part way through otherwise. I had to reboot to do
it, too - doing it with the writable sysctl (rather than the tunable one -
I can't remember which is which now) caused the machine to crash a little
while later.
_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "
 
 
 

Help: Install JDK 1.5 on FreeBSD 5.4 AMD64

Post by audiocolla » Sat, 29 Oct 2005 04:21:16


http://www.yqcomputer.com/
Holy cup of coffee Batman, Java installed! You know I
ran that failed command all long time ago, but I saw
those warnings and figured it failed, so I never tried
to build it. I just would start over. Thanks for all
the help everyone, now time to have some fun!
_______________________________________________
XXXX@XXXXX.COM mailing list
http://www.yqcomputer.com/
To unsubscribe, send any mail to " XXXX@XXXXX.COM "