Home  |  Map  |  Index  |  Search

News | Archives | Links | About LF  
This document is available in: English  Castellano  Deutsch  Francais  Italiano  Nederlands  Russian  Turkce  

convert to palmConvert to GutenPalm
or to PalmDoc

[Photo of the Author]
by Georges Tarbouriech

About the author:

Georges is a long time Unix user (commercial and free). As an old NeXT lover, he is very fond of free projects using the look and feel of this great OS.



GNUstep, the open source OpenStep


More than 10 years ago, an incredible machine with an even more incredible OS was released. It was called NeXT and NeXTStep was the name of the OS. We had never seen something like that before : it was a very nicely designed machine, with a breathtaking display. The OS was based on BSD 4.2 at the beginning and 4.3 a bit later, with a very compact mach kernel. With it, appeared the first graphical and object oriented development tool : Interface Builder (Thanks to Jean-Marie Hullot and Bertrand Serlet for such an unbelievable tool). Commercially speaking, this machine didn't really succeed. Then, NeXT decided to port the framework to different OSes such as Sun, for instance. This API was called OpenStep. From there, GNU started a big project, GNUstep, http://www.gnustep.org, to build a free OpenStep implementation. This article tries to present this great work, even if it is not yet finished.


To start with...

For GNUstep, you need another great free product : Window Maker. It's a window manager a la NeXT. If you don't know it yet, you can take a look at it. At the time of this writing, the latest version is 0.64.0.
This window manager is part of the GNUstep project and you can get it from http://www.windowmaker.org.
Let's add, Window Maker runs on almost every Unix platform, either commercial or free. It's a bit different as far as GNUstep is concerned. It will run on most Linux flavors, NetBSD, FreeBSD, OpenBSD, it is more or less stable dependent on the OS you run it on. Regarding commercial Unixes, it will run on Solaris, Irix... with more or less stability.
Once your screen looks like NeXTStep, you can go to GNUstep web-site to get everything you need.
And what do you need ? Obviously, an objective C compiler (remember, it's an object oriented framework). gcc 2.8 and up will do the trick. Recommended is the libobjc. Apart from the tools needed to compile, you need GNUstep stuff : that is the base library, at least, the gui library, the X11 backend (xgps or xdps)... and so on. There is a lot you can download, it's up to you : check the list to make your choice. For instance, you can get Gorm which is the Interface Builder implementation (only as CVS), and of course, the examples or the users apps.


To install...

You just have to compile what you downloaded ! Seriously, you should read the READMEs, the INSTALLs. You also have a GNUstep HOWTO, recommended reading.
After compiling, most of your work will concern environment variables and programs to launch at startup time (the engine for instance, called gdnc).
As mentioned earlier, you can have two different backends : the X one and the dps one which is the Display PostScript free implementation. This last will provide much better results but it's much less evolved than the X backend.
According to your OS, check the paths, when defining the environment variables. At least, you must define the GNUSTEP_SYSTEM_ROOT variable and the path to the different scripts or programs.
Once you have finished with this part, you can "play" with GNUstep.



There are a lot of examples available from the GNUstep website, either going to the User apps section or to the download section. They are the best way to get familiar with GNUstep if you don't know NeXTStep or OpenStep. Most of them are working examples and allow to understand the philosophy behind the framework. Looking at the code will teach you a lot about Objective C. For someone knowing C, Objective C is quite easy to learn, and in any case much easier than C++ (well, this is only my opinion).
Among these examples, a very nice one is the font panel. It really looks like the original one. By the way, along this article we'll show screen shots both from GNUstep and NeXTStep, thus you'll be able to compare. Here is the first example : the font panel from the GNUstep and the one from NeXTStep.

fontp.jpg fontpn.jpg

Another interesting example is the Edit app. It isn't fully working but it's a nice work rather close to the original.
One of the most teaching example is called GSTest. Running GSTest allows you to understand everything about windows, buttons, scroll bars... It's an all in one work ! A look at the source code is better than a book.
Of course, it doesn't mean the other examples have no interest : they do have !
Simply, the author of many apps, Nicola Pero, has done a very great job.
Another great app from the same Nicola, is called Finger. It's a gui for finger (would you have guessed?), ping, traceroute. Here it is :


We could mention many more apps but let's leave the pleasure of discovery to the reader.


The big guns

A major revolution brought to us by NeXTStep was Interface Builder. As its name says, it was a tool to create a gui for your application. But, what a tool ! Remember, that was at the end of the 80's : just incredible !
Why was it a revolution : because you were able to build a window with all its stuff in less than 5 minutes ! That is, a window with its menu, its buttons, its sliders, etc, was created by dragging objects from a palette to this window. Then it was possible to link these objects to other windows or menus or whatever. A minimal code was generated and you just had to complete it. Obviously, these objects, once created could be reused somewhere else.
Unbelievable at that time !
Since then, many big software editors tried to do the same : in my humble opinion, they never reached the level of the original.
And now, you can have such a tool for free ! It's called Gorm (GNUstep Graphics Object Relationship Modeler) and the author is Richard Frith-Macdonald.
Gorm is only available as CVS from the GNUstep website. Version is only 0.1 at the time of this writing, nevertheless it works even if a lot of functions are missing. To discover Interface Builder look and feel, Gorm is the right tool.
Here is a very simple (and stupid) example, once again with the equivalent from NeXTStep.

gorm.jpg ib.jpg

As we said before, this tool and its model Interface Builder are used to create the graphical part of an application. Of course, it isn't enough to make this application work. You'll have to complete the generated code and manage the different sources as for any application project. Last, you'll have to compile your work.
Here comes the second big tool, called Project Builder under NeXTStep and ProjectCenter under GNUstep. ProjectCenter is the work of Philippe C.D Robert and version number is 0.2. Once again, this tool is a working one despite the version number. You can manage your project as you would with Project Builder under NeXTStep. Obviously, there's a lot of work to be done but this one too, is worth downloading.
Here is how it looks like compared to its "father".

prcent.jpg pb.jpg

Using those two tools is rather simple if you know NeXTStep or OpenStep. If you never used them before, you'll have to find the philosophy behind them. A lot of documentation is available and it is recommended reading (not to say compulsory reading). But once you understood how it works... you can't live without ! You've been warned.
We must mention other great things such as GWorkspace or GSBench. The GNU 3DKit is another wonderful piece of software. It's an API designed to work on top of OpenGL. You'll find it at http://www.nice.ch/~phip/softcorner.html with many other applications.



The tools we'll mention here are designed to port apps from OpenStep to GNUstep. But, as a matter of fact, they go much further since they will allow you to port Mac OS X apps as well. That's the important point : more on this later !
First, there's a tool called OpenStep2GNUConverter, allowing you to convert a PBProject (Project Builder) to a GNUstep Makefile. That is, you'll be able to compile an OpenStep project on your Linux box (for instance) .
To compile this project, you'll need another tool called nfmake.
A tool called nib2gmodel allows to convert a nib file (produced with Interface Builder) to its equivalent under GNUstep, named gmodel.
Last but not least, you can get gstep-db, a database library and even more, an Oracle adaptor.
NeXTStep and OpenStep used to provide you with adaptors for Sybase and Oracle, that is an interface to query databases from these editors. GNUstep offers you the same for free (under NeXTStep or OpenStep, you needed the developer kit which was quite expensive, but you had the Enterprise Object Foundation for free - a lot of examples).
Of course, these tools can be downloaded from the GNUstep website.
Unfortunately I was unable to test all this stuff, since I "only" got an old NeXT station and I'm (impatiently) waiting to get Mac OS X at work. But I've been trusting GNU for about 15 years and I won't change today ! I feel like saying : all this should work for sure. Anyway, within a few months I will test all this...



If you are interested in developing under this great framework, there's a lot of documentation you can get, as already mentioned. The ease of use is not a legend, but you need some knowledge about the way it works.
From the GNUstep website, you can find many useful links. However, some of them deserve special attention.
Going to http://www.gnustep.org/resources/documentation.html will provide you with the general GNUstep documentation. You'll find there an Objective C book, installation instructions, FAQ...
There's also a documentation about the GNUstep library.
And even more, you'll find tutorials. Nicola's one is recommended reading. You can then visit http://www.gnustep.it/nicola/Tutorials
Another place to visit is the resources section : there are tons of links to articles, development sites...
The http://www.gnustep.net/ website is as well of interest.
That is, you can find everything you need to start with GNUstep.


What's NeXT ?

The strange story of NeXT carries on, let's hope with success that time, under the name of Mac OS X. What a great thing ! What do you think about an OS born more than 10 years ago starting a new career ? It was quite ahead, don't you think ?
But what does that mean for us ? Well, probably a lot of great apps since all the existing ones can be easily recompiled, and don't forget, Mac OS X and so NeXTStep are Unix systems. That means tons of applications potentially available, as well for free Unixes. Accordingly, GNUstep is the framework you need...
Let's say it's a dream (sort of) : at least, we would be able to choose the software we want. Unfortunately, there is a bright side and a dark side.

The bright side

Let's take an example : today, according to the OS you use, you don't have much choice concerning web browsers. It's either Netscrape (and its derivatives) or Exploder, that is two gas factories and a match box, security holes, and so on. Mac OS X will provide you with OmniWeb : this is a really great web browser. Using it under NeXTStep is a pleasure, even if it's a rather old version.
It's that sort of browser you can dream of today, when you use Unix or M$ things. The only "thin" web browsers today can be found under so called alternative OSes : such as NetPositive under BeOS or AWeb, for instance, under AmigaOS. Of course, Opera seems attractive, but till now, I'm not quite convinced (but this is only my opinion). What I mean here, is Mac OS X and so GNUstep will provide us with "new" tools, often better than the ones we can use today. We did benefit from such tools about ten years ago... with NeXTStep !
Of course, this is true for many other types of software and not only for web browsers.
Going to http://www.omnigroup.com/ will show you a bunch of available tools.
The main difference between GNUstep and Mac OS X comes from the fact that X-Window is used for GNUstep but not under Mac OS X. That was already a complaint about NeXTStep. That's where GNUstep becomes so important : it allows you to use these apps under X. This is probably one of the main strong points of this project : those people really did a great job.

The dark side

We can fear the arrival of Exploder and some others pieces of s...oftware from the same editor under Mac OS X. This is a bit frightening ! If these "apps" are Mac OS X native ones, we can expect the worst. That is, the insidious entry of the Redmond army into the free Unix world. Of course, here free doesn't mean gratis since we are talking about M$ thieves, but... If you want to know the applications under development for Mac OS X, just have a look at http://www.apple.com/macosx/applications/
Let's say, it's the pessimistic way of thinking : wait and see !

However, lets not forget that GNUstep is particularly designed for development. Once it will become a bit more achieved, you'll be able to develop applications the easy way, like it was under NeXTStep. GNUstep is much more than a single framework, we could say it's a big IDE (Integrated Development Environment). The most important point seems that these apps will be easily portable, to Mac OS X, for instance.
By the way, let's not forget the Apple's open source, Darwin. More on the subject at http://www.opensource.apple.com//
Obviously, there's much more to say about GNUstep but it's beyond the scope of this article. The goal was to make you feel like trying this great product, and why not, participating in this big project.


And the band plays on

One of my greatest pleasure concerning free software comes from these projects trying to "repair" the big commercial mistakes. NeXTStep was for me a true revolution. I'm the very happy owner of a 10 years old workstation, and don't believe it's covered with dust : I use it almost everyday despite its 68040/25 Mhz CPU. Fortunately (or unfortunately), many people seem to think the same. Thanks to the GNUstep team, to the Window Maker team to provide us with such a great work.
The incredible thing about NeXTStep comes from the fact that many editors tried to "clone" it... and they did succeed where the model failed. Once again, we must mention the Redmond Kingdom : have you ever noticed the W95 windows and their gadgets ? Well, have a look at the NeXTStep screen shots above. NeXTStep first appeared in 1987 in USA and around 1990 in Europe. As its name says, the thing from M$ appeared more than five years later. The leaflets flying between two folders, invented in the surrounds of Seattle, were present under NeXTStep 2.1, that is around 1991...
Nevertheless, for once, they didn't copy in Redmond ! No, they did much better : they "bought" people from NeXT... I suppose for many, many bucks. Never mind, but that's not fair, is it ?
This to say NeXTStep never left people indifferent, what is an understatement.
GNU is the absolute reference concerning free software and it deserves to be. The whole world owes GNU a lot : every OS has been able to benefit from their work. Their compilers are probably the best ones ever seen, whatever the OS. That's true for many other tools. Even more, their projects are often (if not always) as great as their tools. GNUstep is one of them. By the way, NeXTStep had a GNU directory...
If you are like me, not very fond of the well known (free or commercial) Unix desktop environments, try GNUstep, you'll love it ! Even more, you won't be able to work without.
Enjoy !
What a great time we're living in!  

Talkback form for this article

Every article has its own talkback page. On this page you can submit a comment or look at comments from other readers:
 talkback page 

Webpages maintained by the LinuxFocus Editor team
© Georges Tarbouriech, FDL

Click here to report a fault or send a comment to LinuxFocus

2001-04-27, generated by lfparser version 2.13