*BSD News Article 67601


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.anu.edu.au!harbinger.cc.monash.edu.au!news.mira.net.au!inquo!vyzynz!news.dacom.co.kr!usenet.seri.re.kr!news.kaist.ac.kr!usenet.kornet.nm.kr!agate!benco
From: benco@ucsee.EECS.Berkeley.EDU (Ben Cottrell)
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: Will FreeBSD adopt Java like everybody else?
Date: 3 May 1996 22:47:27 GMT
Organization: UC Berkeley Society of Electrical Engineers
Lines: 17
Message-ID: <4me2dv$1aq@agate.berkeley.edu>
References: <4m6gdj$8h8@sidhe.memra.com> <4m8abh$7tf@samba.rahul.net> <4makql$1ab@zip0.zipnet.net>
NNTP-Posting-Host: ucsee.eecs.berkeley.edu

In article <4makql$1ab@zip0.zipnet.net>,
Andras Radics <radics@zipnet.net> wrote:
>The more obvious interpretation of "embed" here is that of recognizing
>yet another script-like executable that needs a 'shell' to run it.  Not
>much more difficult than handling "#!", though magic number checking may
>have to be beefed up (depending on how Java binaries are identified).

The magic number for Java files is 0xCAFEBABE. The only other thing that
would need paying attention to is the two sets of two bytes after the
four bytes of magic number--the minor and major version, respectively,
of the JVM spec that the file was compiled to run on. These would need
to be processed somehow as well.
-- 
____  -Ben Cottrell           (home page http://www.csua.berkeley.edu/~benco/)
\  / GCS(M) dpu s:+ a16 C++++ UB++++ P++(--) L- @E- W++(-) N++ K+ w-- !O++ @M+
 \/ PS++ ?PE Y PGP-- @t+ 5? X? R--(+) tv-- b+++ DI-- D- G+ e h!(*) r%(++) y+**
   Tamino on FurryMUCK and YiffNet IRC             Pendor!             NetBSD!