Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Java on SPARC Linux
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on Sparc
View previous topic :: View next topic  
Author Message
likwid
n00b
n00b


Joined: 07 Mar 2007
Posts: 40

PostPosted: Fri Mar 16, 2007 1:19 am    Post subject: Java on SPARC Linux Reply with quote

Are there any updates on this situation? Kind of insane that there isn't java for sparc linux...
Back to top
View user's profile Send private message
Ferris
Retired Dev
Retired Dev


Joined: 13 Jan 2003
Posts: 426
Location: N. Virginia (USA)

PostPosted: Fri Mar 16, 2007 11:40 am    Post subject: Reply with quote

Sigh. No. You are right, it is insane that sun won't support java on their own systems. (Sun supports sparc, sun supports linux, but sun does not support sparc/linux.) :(
Back to top
View user's profile Send private message
likwid
n00b
n00b


Joined: 07 Mar 2007
Posts: 40

PostPosted: Fri Mar 16, 2007 6:45 pm    Post subject: Reply with quote

Man that sucks heavy balls. Has this always been the case? Like back when RedHat used to have a sparc distro (6.2 and under) wasn't there java?
Back to top
View user's profile Send private message
Ferris
Retired Dev
Retired Dev


Joined: 13 Jan 2003
Posts: 426
Location: N. Virginia (USA)

PostPosted: Sat Mar 17, 2007 5:55 pm    Post subject: Reply with quote

There was one from blackdown, but it has security issues. If you have time and like to code at a fairly low level, I can help with a possible light-weight substitute, but I haven't had the time to make it work (endian issues and pointer misalignment and just what assembly level semaphores it wants). It's a disgrace that sun won't support their language on their architecture on a system they support, but I can't fix that. :(

Yours in frustration,
Back to top
View user's profile Send private message
likwid
n00b
n00b


Joined: 07 Mar 2007
Posts: 40

PostPosted: Mon Mar 19, 2007 4:41 am    Post subject: Reply with quote

I am a junior level sysadmin/engineer... I've forgotten most of my C due to lack of use lol so I couldn't help you with what I assume is assembly level coding. I'd be all for it if I could code well. Hopefully someone out there will take on this task...
Back to top
View user's profile Send private message
recupero
n00b
n00b


Joined: 25 Jun 2006
Posts: 26

PostPosted: Mon Mar 19, 2007 2:21 pm    Post subject: Reply with quote

i've just spent little time on the problem:
i've downloaded the new GPL'd Java.

And figured :lol: it could be compiled with a make :lol:

Yea, but isn't it theoretically possible to use Sun/Sparc binary compatibility in order to run a javac for the compilation of the GPL'd version?

Post some links if you have some idea.

Thank you.
Back to top
View user's profile Send private message
henniez-swisswater
n00b
n00b


Joined: 07 Sep 2005
Posts: 16

PostPosted: Thu Jun 28, 2007 3:41 pm    Post subject: Reply with quote

i tried to compile the x86 source code for my sparc. most of it went well, except sun-jdk. now i have java config etc, but no java:(
Back to top
View user's profile Send private message
blu3bird
Retired Dev
Retired Dev


Joined: 04 Oct 2003
Posts: 593
Location: Munich, Germany

PostPosted: Thu Jun 28, 2007 9:14 pm    Post subject: Reply with quote

probably because sun-jdk is binary and you just can't run x86 binaries on a sparc ;)

However if you have a program written in java and you want to run it on linux/sparc you can try your luck with gcj/gij(compile gcc with gcj useflag, http://gcc.gnu.org/java/faq.html).
_________________
Black Holes are created when God divides by zero!
Back to top
View user's profile Send private message
Galahad
Tux's lil' helper
Tux's lil' helper


Joined: 12 Feb 2003
Posts: 126

PostPosted: Mon Jul 09, 2007 3:27 pm    Post subject: Reply with quote

gcj-jdk depends on eclipse-ecj depends on virtual/jdk. So have fun.
Back to top
View user's profile Send private message
guidebee
n00b
n00b


Joined: 30 Sep 2007
Posts: 2

PostPosted: Sun Sep 30, 2007 3:34 am    Post subject: JDK1.4.1 works on Gentoo/Sparc Reply with quote

I recently installed the gentoo linux on Sun ultra 10 (Sparc) ,and met the same problem, there's no avaible Java for Linux/Sparc.

I tried to download
http://ftp.cvut.cz/java-linux/JDK-1.4.1/sparc/01/

and tried to install j2sdk-1.4.1-beta-linux-sparc.bin, it gave some checksum error.

there's a way to manually install the JDK1.4.1. use any editor (like vi) to open the .bin file.

delete all the shell scipts in the .bin file.

"
....
END_OF_STUB
BZh91AY&SY¹...

"

keep all the data below END_OF_STUB ,save it, and change the file name to .bz2

then use tar xvf [jdk].bz2 , it unzips all the JDK1.4.1

it actually works :) :) :)
Back to top
View user's profile Send private message
Ferris
Retired Dev
Retired Dev


Joined: 13 Jan 2003
Posts: 426
Location: N. Virginia (USA)

PostPosted: Mon Oct 01, 2007 12:06 pm    Post subject: Reply with quote

Interesting, thanks. We'll look at it. What version of gcc are you using on your system?

Regards,
Back to top
View user's profile Send private message
guidebee
n00b
n00b


Joined: 30 Sep 2007
Posts: 2

PostPosted: Wed Oct 10, 2007 1:32 pm    Post subject: Reply with quote

gcc version 4.1.1 (Gentoo 4.1.1-r3)
Back to top
View user's profile Send private message
psychicist
n00b
n00b


Joined: 27 Oct 2007
Posts: 2

PostPosted: Sat Oct 27, 2007 9:05 am    Post subject: Reply with quote

I'm neither a Gentoo nor a Debian/Ubuntu user but why would we settle for some older, unsupported SPARC JVM when we could just as well get the OpenJDK working on SPARC. The code is there for Linux and for SPARC, we only have to get the combination working.

I've already asked for assistance on the Hotspot-dev mailing list, so with your help we could get this thing working pretty soon. You can find more information at http://mail.openjdk.java.net/pipermail/hotspot-dev/2007-September/thread.html.
Back to top
View user's profile Send private message
Ferris
Retired Dev
Retired Dev


Joined: 13 Jan 2003
Posts: 426
Location: N. Virginia (USA)

PostPosted: Mon Oct 29, 2007 12:23 pm    Post subject: Reply with quote

Thanks for the information. I think that there are two difficulties: (1) Assembly language will likely need some conversion; (2) More difficult: I am sure sparc/solaris java assumes 64-but user mode. Sparc/linux is 32-bit user mode. This can cause problems unless the sun developers took care to use conditional compilation options.

That said, good look and ask for assistance if you wish.
Back to top
View user's profile Send private message
donpine
n00b
n00b


Joined: 02 Nov 2007
Posts: 2

PostPosted: Sun Nov 25, 2007 11:48 pm    Post subject: Reply with quote

Thank You guidbee! :!: Your instructions worked great for me. I'm running 2.6.22 with gcc 4.1.1 on an Ultra 5. Some web applets don't load, but I'm able to run MoneyDance (keep the old box productive).

Thanks for the tip!
Back to top
View user's profile Send private message
CrazyApe
n00b
n00b


Joined: 26 Apr 2003
Posts: 13
Location: Australia

PostPosted: Thu Jun 05, 2008 8:09 am    Post subject: Iced Tea - Sparc - Almost Reply with quote

I picked up an Ultra 5 a few weeks ago as I like to mess about with Gentoo on alternate architectures, it wasn't long before I found myself looking into the current java situation we have.

I've managed to get very close with iced tea.

Hotspot is compiled with the propper sparc patches for the atomic ops, etc.

I have java, javac, and all the other binaries, I'm just having issues getting some class stuff built.
All the .class files are built, but the section of code that builds the .jar has a problem.

I'm getting:

error: bad class file: sun/rmi/registry/RegistryImpl_Skel.class(sun/rmi/registry:RegistryImpl_Skel.class)
bad signature: java/lang/
Please remove or make sure it appears in the correct subdirectory of the classpath.


I really don't know much about java, what can I do here, even a quick fix to get past this point.


For now I'll just keep messing with it, I may discover something. Anyway, this shows promise.

sparc / # /var/tmp/portage/dev-java/icedtea-6.1.1/work/icedtea6-1.1/openjdk/control/build/linux-sparc/j2re-image/bin/java -version
java version "1.6.0"
IcedTea Runtime Environment (build 1.6.0-b09)
OpenJDK Client VM (build 1.6.0-b09, mixed mode)
_________________
Neither logic nor reason can mandate adherence to convention.
Back to top
View user's profile Send private message
Ferris
Retired Dev
Retired Dev


Joined: 13 Jan 2003
Posts: 426
Location: N. Virginia (USA)

PostPosted: Wed Jun 10, 2009 12:18 pm    Post subject: Reply with quote

Please see Bug #159780 from comment 41 (https://bugs.gentoo.org/show_bug.cgi?id=159780#41 ) on. It looks as if IcedTea can work as a java engine on sparc, thanks to Dylan Wakefield. Please test it if you are interested in java and post results here. I am aiming to get this into the Gentoo mainstream, and would just like to have a bit of feedback first.

Thanks,
Back to top
View user's profile Send private message
CrazyApe
n00b
n00b


Joined: 26 Apr 2003
Posts: 13
Location: Australia

PostPosted: Sat Jun 13, 2009 4:47 am    Post subject: Most stuff just builds. Reply with quote

I've been having a bit of a play with icedtea6-bin and the vast majority of apps that require java now build, simply by keywording them for sparc/~sparc.

The following is a list of things that have built successfully, this is by no means an exhaustive list. Just because it built doesn't mean it works, although in general that is the case.

Anything with native code may need a tweak to the build, things that come to mind are swt and eclipse.

The swt ebuild needs a bit of a tweak, I'll post an ebuild for it later. I have tested swt somewhat with vuze :)

Eclipse (not listed bellow) needs another strand of spaghetti wound through it's build system, I'll take a look at it and see what I come up with.

Anyway, the list so far:

app-editors/jedit-4.3_pre16
app-editors/jext-5.0
dev-java/ant-1.7.1
dev-java/ant-antlr-1.7.1-r1
dev-java/ant-apache-bcel-1.7.1
dev-java/ant-apache-bsf-1.7.1-r1
dev-java/ant-apache-log4j-1.7.1
dev-java/ant-apache-oro-1.7.1
dev-java/ant-apache-regexp-1.7.1
dev-java/ant-apache-resolver-1.7.1
dev-java/ant-commons-logging-1.7.1
dev-java/ant-commons-net-1.7.1
dev-java/ant-core-1.7.1-r4
dev-java/ant-eclipse-ecj-3.4
dev-java/ant-javamail-1.7.1
dev-java/ant-jdepend-1.7.1
dev-java/ant-jmf-1.7.1
dev-java/ant-jsch-1.7.1
dev-java/ant-junit-1.7.1
dev-java/ant-nodeps-1.7.1
dev-java/ant-owanttask-1.1-r12
dev-java/ant-swing-1.7.1
dev-java/ant-trax-1.7.1
dev-java/antlr-3.1.3-r2
dev-java/asm-2.0-r1
dev-java/bcmail-1.38-r1
dev-java/bsf-2.4.0-r1
dev-java/cldc-api-1.1
dev-java/commons-daemon-1.0.1-r2
dev-java/commons-dbcp-1.2.2
dev-java/commons-el-1.0-r2
dev-java/commons-pool-1.4
dev-java/dom4j-1.6.1-r3
dev-java/eclipse-ecj-3.4-r4
dev-java/fop-0.94-r1
dev-java/gnu-classpath-0.97.2
dev-java/gnu-regexp-1.1.4-r2
dev-java/hamcrest-core-1.1
dev-java/icu4j-3.8.1-r1
dev-java/iso-relax-20050331-r2
dev-java/itext-2.1.5
dev-java/jarjar-0.9
dev-java/java-config-2.1.8
dev-java/java-config-wrapper-0.16
dev-java/java-getopt-1.0.13
dev-java/javacc-4.2
dev-java/javacup-0.11a_beta20060608
dev-java/jaxen-1.1.1
dev-java/jaxp-1.4-r1
dev-java/jcommon-1.0.16
dev-java/jfreechart-1.0.13
dev-java/jgoodies-looks-2.1.4
dev-java/jsch-0.1.41
dev-java/junit-4.6
dev-java/jython-2.2.1-r1
dev-java/jzlib-1.0.7-r1
dev-java/log4j-1.2.15-r1
dev-java/lucene-1.9.1
dev-java/lucene-analyzers-2.3.2
dev-java/qdox-1.6.3
dev-java/rhino-1.6.5
dev-java/servletapi-2.4-r5
dev-java/stringtemplate-3.2
dev-java/sun-jaf-1.1.1
dev-java/sun-javamail-1.4.2
dev-java/swing-layout-1.0.3
dev-java/swt-3.4-r3
dev-java/tomcat-servlet-api-6.0.18
dev-java/xerces-2.9.1
dev-java/xml-xmlbeans-1.0.4_pre20041217
java-virtuals/jaf-1.1-r1
java-virtuals/javamail-1.0-r1
java-virtuals/servlet-api-2.3
media-video/projectx-0.90.4.00_p26
net-irc/jircii-41
net-p2p/vuze-4.2.0.2
net-p2p/vuze-coreplugins-4.2.0.2
sci-biology/readseq-20080420
virtual/jdk-1.6.0-r2
www-servers/tomcat-6.0.18-r3

Cheers,
Dylan
_________________
Neither logic nor reason can mandate adherence to convention.
Back to top
View user's profile Send private message
alexbuell
Guru
Guru


Joined: 18 Jul 2002
Posts: 420
Location: "Hemp"shire, UK

PostPosted: Mon Nov 08, 2010 9:50 am    Post subject: Reply with quote

Good news, I have used 1.4.1 to bootstrap to icedtea-6.1.9.1, I'm testing the JVM at the moment. There will be a binpkg up for testing soon.
_________________
Cheers,
Alex.

Linux - the best text adventure game ever.
Back to top
View user's profile Send private message
lariano
n00b
n00b


Joined: 14 Aug 2011
Posts: 8

PostPosted: Sun Oct 09, 2011 8:04 am    Post subject: jdk 1.6.0_22 on gentoo/sparc Reply with quote

As there is currently no jdk via portage availabel for sparc I have tried to build it manually on my SB-1500 (UltraSparc IIIi). After several attempts finally I've got it running and could ask

$ java -version
java version "1.6.0_22"
OpenJDK Runtime Environment (IcedTea6 1.10.3) (linux-gnu build 1.6.0_22-b22)
OpenJDK Client VM (build 19.0-b09, mixed mode)

I had to emerge dev-java/ecj-gcj and sys-devel/gcc-4.5.3-r1 for bootstrapping and to fulfill all requirements of the `configure' script of icedtea6-1.10.3 (several java apis can be downloaded in binary form). Then I encounterd two problems:

I had a ClassNotFoundException at the beginning of the build process and found a solution with help of

http://www.linuxfromscratch.org/blfs/view/svn/general/icedtea6.html

The xml-apis-jar from the xerces archive must be provided additionally due to some bug. The patch provided on the linuxfromscratch-site (http://www.linuxfromscratch.org/patches/blfs/svn/icedtea6-1.9.7-xerces2_10-1.patch) can not be applied automatically because it is written for icedTea-1.9.7. But the few changes can be done manually.

The second problem was a compiler error because the newer gcc-versions produce new warnings for some old-style-code in the jdk-sources which are converted into compiler errors if -Werror is set as option. The sources of the jdk are not ready for these warnings. The solution is therefore to get rid of the -Werror option. I have found a patch for this issue in an older version of icedTea (http://osdir.com/ml/attachments/txtMUBogtElg3.txt) which is however not included in icedtea6-1.10.3. As with the issue before I applied the ideas of this patch manually to the file targets which are found under a slightly different location however. Then finally everything worked.

The new jdk makes a quite good impression. My favorite java application are running stable, e.g. intelliJ-IDEA. I have copied a jboss-5.1.0 from an opensolaris installation of another hard drive of the same machine to the gentoo-installation and found to my complete surprise that the startup time of this empty jboss takes ~2:05min on opensolaris (2009.06, sun-jdk-1.6.0_13) whereas only ~1:35min on gentoo (2.6.39-gentoo-r3) :roll: .
Back to top
View user's profile Send private message
lariano
n00b
n00b


Joined: 14 Aug 2011
Posts: 8

PostPosted: Sat Oct 15, 2011 6:18 am    Post subject: Comments on gcc for icedtea6-jdk Reply with quote

My gentoo installation was compiled with gcc-4.4.5 but in order to compile the icedtea6-jdk I had to emerge gcc-4.5.3. Later I tried to upgrade the whole system with the new compiler but had no success (got an ugly compiler error late in `emerge -ev world'). Therfore I switched back to stable gcc-4.4.5 and rebuilt the icedtea6-jdk two times based on the output of the previous build cycle using
Code:
./configure --disable-bootstrap --with-jdk-home=$JDK_OF_PREVIOUS_BUILD (...)

Now I have consistent binaries and all packages emerged for the first build cycle, compiled with gcc-4.5.3, should be eligible for unmerge. The testsuite of the jdk gives for me now the following results in good agreement with the results reported on linuxfromscratch:
Code:
hotspot test results: passed: 97; failed: 1; error: 1
langtools test results: passed: 1,409
jdk test results: passed: 3,351; failed: 25; error: 5
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on Sparc All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum