[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

KDrive



Dear Branden, dear all,

The very latest versions of XFree86 include the KDrive X servers
written by Keith Packard.  The KDrive servers are designed to be
particularly small (they were written for the needs of Linux on
handhelds), and self-contained: a KDrive server includes built-in
versions of the fixed and cursor fonts, and will happily run on a
machine on which nothing beyond the server's binary has been
installed.  (Actually, you might need a kernel and libc.)

There are two KDrive servers that are of interest for general-purpose
machines.  The Xfbdev server will run on any machine that has a useful
/dev/fb.  The Xvesa server uses VM86 to speak to the system BIOS, and
should run on any system that has useful VBE 2.0, VBE 1.2 or even a
plain old VGA BIOS.  It is believed that it should work on EGA, but we
haven't found a machine to test it on.  (I'll write support for CGA if
there is enough demand.)

Neither of the servers require any configuration at all; you only need
to pass the desired screen size and depth on the command line.  Both
support screen rotation, and if you build with Xinerama they even
support runtime switching of the screen orientation.

Both are Linux-specific; Xvesa is also specific to x86 and to gcc.
Xfbdev is of course dependent on /dev/fb, but there should be no major
difficulty in porting Xvesa to any system that gives userspace access
to VM86 and to any compiler that supports inline assembler.

The default build yields servers of the following size (after stripping):

  -rwxr-xr-x    1 jch      jch        921208 Dec  4 00:30 Xfbdev
  -rwxr-xr-x    1 jch      jch        940936 Dec  4 00:30 Xvesa

     text    data     bss     dec     hex filename
   751240  153476   43404  948120   e7798 Xfbdev
   770603  153448   43404  967455   ec31f Xvesa

You could make them somewhat slimmer yet by removing support for
certain extensions.

In the latest CVS versions of XFree86, building the KDrive servers is
very simple.  It is best to start with a CVS version from December 1st
or later (the full manual pages have only been committed on Friday).
You need a clean source tree (not one in which you have built XFree86),
and add the following lines to the BeforeVendorCF section of your
site.def file:

  #define KDriveXServer YES
  #define BuildServersOnly YES
  #define XfbdevServer YES
  #define XvesaServer YES

By default, this will build a server with no support for scalable
fonts (but support for built-in ``fixed'' and ``cursor'' fonts, and
normal support for bitmap fonts and font-server provided fonts).  You
may therefore also want to add the following lines:

  #define BuildType1 YES
  #define BuildFreeType YES

Then, do the usual ``nice make World &> world.log'', but do *not* make
install, as this would overwrite your copies of xinit, Imake, some
headers and some configuration files; instead, cd to
xc/programs/Xserver, and install the Xvesa and Xfbdev binaries by
hand.  Also install the Xkdrive, Xfbdev and Xvesa manual pages (which
are under hw/kdrive).

If you make the servers suid root, you should be able to say

  xinit -- Xfbdev

or

  xinit -- Xvesa -screen 800x600x24


I would like to argue that these two X servers deserve being packaged.
If someone is willing to package them, he may count on my help with
any upstream issue.  I believe that the packages should not list
anything as required.  They should *suggest* a package containing
xinit, and suggest a package containing bitmap fonts.  I think it is
better to compile-out the scalable rasterisers: the Type 1 rasteriser
is rather fat.

There are of course no licensing issues.

Sincere regards,

                                        Juliusz



Reply to: