Recently in Java Category

OpenBSD: Building Java — how did it end?

| | Comments (1) |

I came back to the OpenBSD laptop this morning after what was supposed to be an all-night build of Java, which comes from OpenBSD's ports system and requires quite a bit of compiling and other voodoo.

So how did it end?

I don't have Java.

Sometime during the build, my /usr filesystem filled up. I set aside 6 gigabytes for /usr when I installed OpenBSD 4.4 on this laptop, and while I have a fair amount of software on the drive, I did have a fair amount of space left. Right now I'm doing a make clean and make clean=depends on the port, which is freeing up all that space, and I have 2.7 GB and counting.

That's not enough.

The OpenBSD FAQ does warn you to leave extra space in /usr if you're going to be building applications from ports instead of using packages (which I prefer in all instances where the package I need is available):

Compiling some ports from source can take huge amounts of space on your /usr and /tmp partitions. This is another reason we suggest using pre-compiled packages instead.

I've heard that building Java requires a lot of space. I just didn't know how much. And I don't have it in this installation.

How do I feel about compiling applications from source? I've never been a big fan of it. But with proper coding, documentation and guidance, it can work.

OpenBSD: Against all odds, I'm building Java

| | Comments (3) |

If you want Java in OpenBSD, it's not easy to get it. Not impossible, but definitely not easy.

First of all, it's a port, not a package, and due to Sun's licensing restrictions for Java, when you run the build on the port, you are instructed to, on your own, fetch nine files (some source, some binary) from a variety of locations and place those files in /usr/ports/distfiles.

Once I jumped through these hoops, I got a persistent checksum error with one of the files I grabbed, xalan-j_2_7_0-bin.tar.gz. In fact, the exact problem I had is described in this Daemon Forums thread.

Curiously enough, three additional downloads of xalan from two separate sites didn't solve the checksum issue.

What did cause the error to stop and the build to proceed was grabbing this line from one of the examples in the Daemon Forums thread:

SHA256 (xalan-j_2_7_0-bin.tar.gz) = h4yOtu7hVRrkMMLboFQmMphW/8BBOyAX3S1O5kjFxfc=

and replacing that same line in /usr/ports/devel/jdk/1.5/distinfo

The original line looked no different, but this swap (done as root) seemed to make everything OK, and I'm well into the build of Java (or, more specifically, jdk).

I hope to be able to run Java apps via both the Firefox and Opera Web browsers. It's one of the final missing pieces in my use of OpenBSD as my main working OS.

Right now the build continues. I'll update when it either finishes or otherwise errors out. (You can see how optimistic I am about ports in OpenBSD at this moment; not so much, that is).

Adding Java to Debian Etch

| | Comments (4) |

I've already repeated myself enough about the Flashplugin-nonfree being taken out of Debian Etch and relegated to Debian Backports. and I've decided NOT to install it for the time being mostly because a) I don't really need it and b) Flash runs like crap on this rig (blame the ECS EVEm motherboard).

But I do need Java. Since Java is not a totally free program, you must agree to the licensing terms before the plugin for Iceweasel/Firefox will install. And with that in mind, it's not in Debian's default "free" repositories.

To get Java, first edit /etc/apt/sources.list. Use su to root or sudo (and if you don't have sudo set up, now is a good time to do it).

Here's how to do it using sudo with the Gedit text editor (substitute your favorite editor for Gedit, and ignore the word sudo if you used su to root):

$ sudo gedit /etc/apt/sources.list &

Once you're in /etc/apt/sources.list, change these lines to include the contrib and non-free repositories:

deb http://ftp.us.debian.org/debian/ etch main contrib non-free
deb-src http://ftp.us.debian.org/debian/ etch main contrib non-free
deb http://security.debian.org/ etch/updates main contrib non-free
deb-src http://security.debian.org/ etch/updates main contrib non-free

Then save and close /etc/apt/sources.list.

While you still have the terminal window open, update your package lists:

$ sudo aptitude update

If you want to stay in the terminal, do this to add Java:

$ sudo aptitude install sun-java5-plugin

Or use the Synaptic Package Manager. Instead of using aptitude to update your package lists, after making your changes in /etc/apt/sources.list, start with Synaptic and click Reload. Then search for the Sun-java5-plugin package and add it that way. Even though I'm a big fan of using aptitude instead of apt at the command line, if I'm in a graphical environment I use Synaptic more often than not.

Then close and restart the Iceweasel browser. You should have Java. To check it, I learned from TomCort.com that you can try to play the Java game Jpong. If it works, you have Java.

I needed Java for a variety of things, but the one that prompted me to actually get it was LogMeIn. Without ActiveX (in IE) or Java (in everything not IE), you can control a Windows or Mac OS X computer remotely via "any" Web browser (and do it free with LogMeIn Free), but you can't actually type directly in an application window without ActiveX or Java installed. And instead of LogMeIn actually prompting me about this omission, I was reduced to typing into a little "Send Keys" window to get actual screen input.

I can't imagine that LogMeIn cares at all about the non-Windows and -Mac market. I get that, since a product to remotely control a Unix-like desktop would be a bit redundant with X over SSH and other technologies that are easy to use in a GNU/Linux or BSD environment.

But in my case, in which I'm using the browsers in Linux and OpenBSD to control a remote Windows XP desktop, they need to make it clear to users that unless you have a Java-equipped browser, your experience is going to be very frustrating until you add the required software.

Later: After adding the contrib and non-free repositories, installing the sun-java5-plugin, restarting Iceweasel and navigating to http://logmein.com, I signed in to my account.

After the wait for Java to get going, I indeed was able to start a remote session from my Debian Etch box to my Windows XP box and actually use my keyboard to type into application windows on the remote host (is that what you call it?).

Now I have to add Java to the rest of my GNU/Linux installations.

Java is even available for OpenBSD, at least for i386 and AMD64. I believe you have to add the entire developers kit to get the runtime. I've seen more than a few messages on the OpenBSD mailing lists from Java developers, so it's not an unknown platform for that sort of programming.


There used to be a huge rant here about how Flash only runs on PowerPC chips if you are using Mac's OS 9 or OS X and not in any Linux or BSD. I'm not quite sure what the status is regarding Java on Linux/PowerPC. It seems a bit murky, and I'm looking into it. A cursory Google search indicates that it is available, although not as an actively developed technology.

Tech Talk column

Steven Rosenberg's weekly Tech Talk column, which appeared Saturdays in the Los Angeles Daily News through about October 2009, is available on the Daily News Technology page.

About this blog






Steven Rosenberg aims to learn what he does not know. He writes about it here.



About this Archive

This page is a archive of recent entries in the Java category.

OpenSolaris is the next category.

Find recent content on the main index or look in the archives to find all content.

Recent Comments

Steven Rosenberg on Oracle gives OpenOffice to the Apache Foundation -- should we care?: I really hope LibreOffice starts to get some major uptake. LO has alr ...

Steven Rosenberg on OpenBSD: Against all odds, I'm building Java: I haven't installed Java in OpenBSD in quite some time. Back when I wr ...

M on OpenBSD: Against all odds, I'm building Java: I've been thinking of using OpenBSD for an embedded application that r ...

candtalan on Oracle gives OpenOffice to the Apache Foundation -- should we care?: I think Libre Office is a really good name. Libre means more to me tha ...

Glenn Thigpen on Oracle gives OpenOffice to the Apache Foundation -- should we care?: I like the Libre Office name better anyway. Glenn ...

Cliff Evans on Oracle gives OpenOffice to the Apache Foundation -- should we care?: "all the major (and likely most of the minor) Linux distributions bega ...

Steven Rosenberg on Slackware tips — quick and easy things to make the box work better: I haven't used Slackware in a while, and I never did get the hang of S ...

luddite on Slackware tips — quick and easy things to make the box work better: thanks Steven thats the sort of page I have been looking for; and does ...

homebrew on Why I dumped Debian Squeeze's Chromium for the Chrome browser from Google's repository: chromium stable channel for ubuntu: https://launchpad.net/~chromium-d ...

Charlie on Iceweasel/Firefox 4 in Debian Squeeze -- I make the leap: I did the same thing the other day cos I wanted to try out Fabrice Bel ...

Powered by Movable Type 4.25

Search this blog

Loading

LXer

Links

Life, the Universe and Debian
Simplify
Daily News technology
LXer
Distrowatch
Linus' Blog
David Pogue
BoingBoing
Linux Today
TuxRadar
Linux.com
Linux Planet
The Open Road
Linux Outlaws podcast
Dan Lynch
Fabian Scherschel
The VAR Guy
Larry the Free Software Guy
Chess Griffin
Linux Reality podcast
Desktop Linux
Practical Technology
Linux Devices
ZDNet
ZDNet's Storage Bits
ZDNet U.K.
iTWire
CNet News
Webware
Beyond Binary
TechCrunch
The Register
Ars Technica
Reg Developer
Computerworld
Computerworld blogs
Steven J. Vaughan-Nichols at Computerworld
Debian
Planet Debian
Debian Forums
Debian News
debianHELP
debiantutorials.org
The Debian User
Wolfgang Lonien
Debian-News.net
Debian Administration
Debian Admin
Debian Weather
Aaron Toponce
Ubuntu
Xubuntu
Kubuntu
Edubuntu
Planet Ubuntu
Ubuntu Forums
Ubuntu Geek
Works With U
OMG! Ubuntu!
I' Been to Ubuntu
Tanner Helland
Dustin Kirkland
Ubuntu UK Podcast
Ubuntu Linux Help
Popey
Linux Mint
CrunchBang Linux
OpenBSD
OpenBSD Journal
OpenBSD Ports
OpenBSD 101
Planet.OpenBSD.nu
jggimi's OpenBSD live CD
DaemonForums
BSDanywhere
Marc Balmer
Denny's OpenBSD blog
Polarwave's OpenBSD Tips and Tricks
Binary Updates for OpenBSD
Puppy Linux
Damn Small Linux
Tiny Core Linux
Lucky 13's Linux blog (lots of Tiny Core)
Lucky 13's BSD blog
PCLinuxOS
Mandriva
Red Hat
Red Hat News
Red Hat Blogs
Red Hat: Truth Happens
Red Hat Magazine
CentOS
Planet CentOS
Fedora
Planet Fedora
Fedora Forums
Fedora Docs
Join Fedora
Paul Frields
Slackware
Slackbuilds
Robby's Slackware Packages
Slackblogs
dropline GNOME for Slackware
GNOME Slackbuild
GWARE - GNOME for Slackware
Wolvix
Zenwalk Linux
Vector Linux
Slax
Splack Linux — Slackware for Sparc
Nonux
How to Forge
marc.info BSD and Linux mailing list archive
FreeBSD
FreeBSD, the Unknown Giant
A Year in the Life of a BSD Guru
NetBSD
hubertf's NetBSD Blog
PC-BSD
Daemon Forums
FreeBSD Forums
Planet FreeBSD
Evilcoder.org
miwi's Privat Blog
DragonFlyBSD
DragonFlyBSD Digest
DesktopBSD
BSD Talk podcast
BSD Magazine
Rhyous
OpenSolaris
MilaX
BeleniX
DeLi Linux
Linux Loop
Electronista
The Tech Report
Engadget
Gizmodo
Phoronix
xkcd – A webcomic of romance, sarcasm, math and language
Nixie Pixel
Technology for Mortals
Thoughts on Technology
ZaReason
System 76
Tiger Direct
NewEgg
DealExtreme

Advertisement