1

I want to download and try an Open-Source OS (Emulation) written in Java. So, I searched and download the, arguably, most famous one I found, which was NACHOS 5.0j.

I have just installed a fresh Ubuntu 10.04 LTS and installed the open-JDK 1.6 through apt-get and then installed eclipse in a similar manner.

After following the readme in NACHOS, I fired terminal, and used gmake (make), and got a bunch of errors and warnings. The one that's bothering me the most is:

as of release 1.4, 'assert' is a keyword, and may not be used as an identifier 
(use -source 1.3 or lower to use 'assert' as an identifier)
Debug.assert(isReadyForApply);

Problem is, I tried downloading another open-source OS called JX, and had a similar problem.

Any help in this issue is appreciated! Any other ideas on where to start learning about operating systems and Java is even more appreciated! (But something practical.)

Mazyod
  • 22,319
  • 10
  • 92
  • 157
  • 1
    Did you even try running it with `-source 1.3`? Both Nachos and JX are really old, so you'll need an old or old-compatible JVM. – Emyr Jun 20 '11 at 16:55
  • all what the readme says is to cd to the directory, then run make command. (makefile will take care of the rest.. it should(?)) – Mazyod Jun 20 '11 at 16:58
  • Any new ones you would suggest? It is for educational purposes.. something clean and simple will do – Mazyod Jun 20 '11 at 16:58
  • 1
    Depends what you want to learn about Operating Systems, many people find Linux From Scratch teaches many of the concepts and principles in a practical environment: http://en.wikipedia.org/wiki/Linux_From_Scratch – Emyr Jun 20 '11 at 17:06

2 Answers2

1

I think you need to add a argument -source 1.3 while compiling or running that OS

Zhao Xiang
  • 1,625
  • 2
  • 23
  • 40
  • I couldn't find that option. I tried 'man make', no such option exists – Mazyod Jun 20 '11 at 16:54
  • 1
    It's not a `make` option, it's a `java` option. Modify the makefile to add `-source 1.3` wherever it sets the java command line options, or where it defines what it means by "java". I can't be more specific without seeing the makefile. – Stephen P Jun 20 '11 at 17:01
  • thanks for clearing that out.. problem is, the make file is really big. – Mazyod Jun 20 '11 at 17:20
0

I found following information from web, basically, you should use java 1.3.1. it is open source, and you can modify the source code to make it run under JDK1.6 if you like.

The Java version of Nachos only supports Java 1.3.1, as the security manager and set of reserved keywords has changed in later versions. Instructional machines already have 1.3.1 installed. For remote users, you can download 1.3.1 here: http://java.sun.com/j2se/1.3/download.html . If you are curious to see what version of java you are using you can run the following command "java -version". We cannot stress strongly enough that you should not use java 1.4 or java 1.5. You might run into transient errors that will not show up as warnings or errors during compile time.

Russel Yang
  • 2,633
  • 3
  • 21
  • 18