xref: /jbit/
NameDateSize

..16-Mar-201612 KiB

.gitignore07-Aug-2014152

core/07-Aug-20144 KiB

dists/26-Mar-20144 KiB

doc/26-Mar-20144 KiB

embd/07-Aug-20144 KiB

Env.defs07-Aug-201485

js/07-Aug-20144 KiB

LICENSE.md26-Mar-20142.6 KiB

midp/26-Mar-20144 KiB

native/07-Aug-20144 KiB

README.md07-Aug-20144.2 KiB

samples/07-Aug-20144 KiB

tools/07-Aug-20144 KiB

Version.defs07-Aug-201419

README.md

1JBit
2====
3
4There is usually no need for you to build JBit from source.
5
6If you are looking for the J2ME version of JBit (for feature phones),
7[pre-built midlets](http://jbit.sourceforge.net/download.html)
8are available.
9
10If you just want get an idea of what JBit is about and have
11a modern browser (IE8+), a (limited)
12[webapp](http://jbit.sourceforge.net/webapp/index.html)
13is also available.
14
15If you have Windows, you can find a precompiled EXE following the
16instructions on this
17[wiki page](https://github.com/efornara/jbit/wiki/Windows).
18
19However, for Linux(-like) operating systems, building the Native version
20of JBit is recommended. Unlike the Javascript and the J2ME versions,
21the Native version has few dependencies and should be fairly easy
22to build.
23
24## Native Version
25
26The following should work (tested mostly on debian, but occasionally on
27NetBSD):
28
29	cd native
30	make
31
32If you are missing ncurses (or have curses), comment out the offending
33lines in the Makefile (or edit them), or install the relevant package
34(*libncurses5-dev* on debian and ubuntu).
35
36The resulting binary (jbit) is self-contained, so you should be able to
37run it from anywhere.  From now on, I will assume that you have it in
38your path.
39
40Switch to the sample directory and type:
41
42	jbit hello.asm
43
44You should get back the usual message:
45
46	Hello, World!
47
48JBit supports a binary format, if you really need it:
49
50	jbit -c jb hello.asm >hello.jb
51	jbit hello.jb
52
53More information is available in the included jbit(1).
54You can find a copy online here:
55[jbit(1)](http://efornara.github.io/jbit/jbit.1.html).
56
57## JavaScript Version
58
59The current JavaScript version is being refactored, so it might be
60broken at any give time.
61
62To check the progress, see:
63<http://jbit.sourceforge.net/webapp/test/index.html> and
64<http://jbit.sourceforge.net/webapp/test/mobile.html>.
65
66The old version is still available:
67<http://jbit.sourceforge.net/webapp/1.2/>.
68
69## JBit Embedded
70
71This is a new version of the VM that is going to be used in future
72Native and JavaScript versions of JBit. It is written in C and includes
73a modified version of the [Fake6502 CPU
74emulator](http://rubbermallet.org/fake6502.c).
75
76The same code base is used to generate three targets:
77
78An image for [Arduino Uno](http://arduino.cc/en/Main/arduinoBoardUno).
79See [jbit(1) - PRIMO](http://efornara.github.io/jbit/jbit.1.html#PRIMO)
80for more information.
81
82A test native program. Just typing make should work, but you need the
83development package of SDL 1.2. Note that this target might disappear
84entirely, once the consolidated bits of embd are integrated into the
85main Native version.
86
87A new JavaScript emulator. Just like the old JavaScript version, you
88need [emscripten](https://github.com/kripken/emscripten) installed. If
89you have a working installation of emscripten, that is, if:
90
91    emcc
92
93produces something like:
94
95    emcc: no input files
96
97you should be able to type:
98
99    make jbit-embd-c.js
100
101and point your browser to the included index.html. Beware that I recently
102updated emscripten and the suggested script (emsdk-portable) took about
1039GB of disk space. This:
104
105    wget -c http://jbit.sourceforge.net/webapp/test/jbit-embd-c.js
106
107is probably a good enough alternative for most.
108
109## J2ME Version
110
111To compile the J2ME Version from source you need:
112
113* [Java SE Development Kit](http://www.oracle.com/technetwork/java/javase/downlo
114ads/index.html).
115  I use version 1.6.0; any version should be fine.
116* [Sun Java Wireless Toolkit](http://www.oracle.com/technetwork/java/download-13
1175801.html).
118  I use versions 1.0.4 and 2.5; again, any version should be fine.
119* [Ant](http://ant.apache.org/).
120  I use versions 1.6.5 and 1.7.0; I have no idea if you can use other versions.
121* [Antenna](http://antenna.sourceforge.net/).
122  I use version 1.2.1beta; older versions should work.
123* [ProGuard](http://proguard.sourceforge.net/).
124  I use version 4.4; older versions should work.
125
126If your environment is setup correctly, you should be able to
127compile JBit by editing Env.defs, entering midp/jbit and running ant.
128
129## Links
130
131* [JBit XHTML Site](http://jbit.sourceforge.net/)
132  (optimized for feature phones).
133* [JBit WAP Site](http://jbit.sourceforge.net/m)
134  (for old phones / very low bandwidth).
135* [JBit Wiki](https://github.com/efornara/jbit/wiki)
136  (too heavy for most feature phones).
137