/*
 * INSTALL
 */

       This is the environment for installation of Canna.  You need
imake on X11R6 to compile Canna.

-1. Quick Install

       If you have no time to read this document and you use the
  default environment for installation, then you run as follows.
  Canna will be installed in /usr/local/canna.

  (1)  When your machine is SONY NEWS, HP-UX, 386BSD, BSD/386,
     EWS-UX/V(CISC), FT-UX or SunOS without JLE, see Appendix A.

  (2)  When you define X_WCHAR in X11/Xosdefs.h or when you compile
     with the option -DNOTSTDHDRS, see Appendix A.9.

  (3)  Run as follows:

	 % xmkmf
	 % make Makefile
	 % make canna
	   (It may take some minutes)
	 % su
	 # make install
	 # make install.man

	When there will be some errors, see the following.  If you
  cannot become super user, then see 5 for Compilation and
  Installation of Canna when you cannot become super user.

0. Overview

       Show configuration of environment for Canna as follows:

  1. Preparations
  2. Compile Canna
  3. Install Canna
  4. How to Use Canna
  5. Compilation and Installation of Canna when you cannot become
     super user
     
       Canna version 3.2 is compiled on the following machine.

     Machine             OS                                   Compiler
    Sparc Station 2     SunOS 4.1.2 + JLE 1.1.2              gcc 2.4.5
    Sparc Station 2	Solaris 2.2 (SVR4)                   cc
    Sparc Station 10    SunOS 4.1.3 - JLE 1.1.3              gcc-2.5.8
    Sparc IPX           SunOS 4.1.1 - JLE 1.1.1
    Sparc 1             SunOS 4.1.1 - JLE 1.1.1
    SS2                 SunOS 4.1.2 - JLE 1.1.2              gcc-2.5.8
    HP A 9000/720,730   HP-UX A.08.07                        /bin/cc
    HP 9000/720         HP-UX8.05                            /bin/cc
    HP 9000/425         HP-UX9.00                            gcc2.5.8
    COMPAQ DESKPRO 4/33i UNIX System V Release 4.2           /usr/ccs/bin/cc
    SONY NWS-1750       NEWS-OS Release 4.2.1C #0            gcc-2.5.8
    NWS-3860            NEWS-OS 4.2R                         /bin/cc
    EWS 4800/35		EWS-UX/V 10.1 (SYSV)                 /bin/cc
    EWS 4800/220	EWS-UX/V(Rel 4.2) R9.1 (SVR4.2)	     /usr/abiccs/bin/cc
    IBM-PC clone        FreeBSD 1.1R                         gcc 2.4.5
    IBM-PC clone        FreeBSD 1.1.5(RELEASE)
    IBM-PC clone        BSD/386 v1.1                         gcc 1.42

       The previous versions are compiled on the following machine.
  When you compile or run Canna on other machines than the list below,
  mail them to Canna@astec.co.jp.

     Machine             OS                               Compiler
    Sparc Station 2     SunOS 4.1.2 + JLE 1.1.2              gcc 2.4.5
    Sparc Station 2	Solaris 2.2 (SVR4)                   cc
    SS 2/10/IPX/IPC     SunOS 4.1.3(GENERIC)                 gcc 2.5.8
    Sun SS2             Solaris 2.3                          gcc-2.5.8
    Sparc Station 10/41 SunOS 4.1.3+JLE1.1.3
    SUN 630MP           SunOS Release 4.1.3-JLE1.1.3
    Toshiba SPARC-LT    SunOS Release 4.1.1-JLE1.1.1 OS/AS=V4.11
    PC                  NEXTSTEP 3.1J for Intel Processors   gcc 2.5.8
    PC-486GR+ODP        386bsd-pc98c2                        gcc-2.5.8
    PC-9801FA(+DX2-64MHz) 386bsd-0.9-pc98-c2                 gcc-2.5.8
    PC-9801BX           PANIX Ver.3.0                        gcc
    PC-9801             PANIX for98 Ver3.0
    486DX33MHz          Linux Slackware 1.1.1                gcc 2.5.8
    Macintosh LC475 KT7 MachTen R2.1.1VM                     gcc 2.5.8
    HP A 9000/720,730   HP-UX A.08.07                        /bin/cc
    HP9000 715/50       HP-UX 9.03, 9.05                     /bin/cc
    SONY NWS-1750       NEWS-OS Release 4.2.1C #0            gcc-2.5.8
    SONY NWS-1460       NEWS-OS Release 4.2.1C
    NWS-3720            NEWS-OS Release 6.0.1 (SVR4.2)       /usr/ccs/bin/cc
    DECsystem 5240      ULTRIX 4.3 Japanese Version          /bin/cc
    IBM Sys./6000 M220  AIX Version 3                        /usr/bin/cc
    IBM RS/6000 570     AIX Ver3.2.5
    EWS 4800/350,210	EWS-UX/V(Rel 4.2) R8.1 (SVR4.2)	     /usr/bin/cc
    EWS 4800/350,210	EWS-UX/V(Rel 4.0) R5.3 (SVR4.0)	     /usr/bin/cc
    EWS 4800/20		EWS-UX/V R9.1/10.1 (SYSV)            /usr/bin/cc

       If you have any problem to compile Canna, mail to
  Canna@astec.co.jp, too.  Canna@astec.co.jp is a mailing list.  If
  you want to join the member, mail to Canna-request@astec.co.jp.

       Canna which contributed on X11R5 is Version 1.2.

       For changes from previous versions, see CHANGES.jp. (Sorry, but
  CHANGES.jp is in Japanese.)
           
1. Preparations

1.1 Configure the Environment in Canna.conf

       For compilation and installation of Canna, configure the
  following environment in Canna.conf.

    cannaBinDir        Directory to install commands.

    cannaSrvDir        Directory to install cannaserver and cannakill.

    cannaLibDir        Directory to install files for Canna.

    cannaManDir        Directory to install documents.

    cannaIncDir        Directory to install include file.

    libCannaDir        Directory to install libraries such as
                       libcanna etc.

    ErrDir             Directory to install log file.

    LockDir            Directory to install lock file.

    wcharDefinition    Use the system definition of wchar_t, or not.

    Wlib               Libraries which include the functions related
                       wchar_t.  If the functions is in libc, then
                       here is a blank.  On System V, generally,
                       here is -lw.

    JapaneseLocale     Set the environment variable LANG to use
                       Japanese.

    cannaOwner         Owner of dictionaries and kana-to-kanji
                       server.  See 4.1.

    cannaGroup         Group of dictionaries and kana-to-kanji
                       server.  See 4.1.

    pointerIntegerDef  Define -DBIGPOINTER here when pointer size is
                       bigger than long size and there is a type long
                       long. (For example, case on SX3 with
                       SUPER-UX.)

    cannaDsoRev        Revision of shared library.  Here is 1 when
                       *.so.1.

    sharedLibExtension Extension of shared library.  Generally, here
                       is so.1.  On HP-UX, here is s1.

    DicDir             Directory to install dictionaries.

    LockFile           File name of lock file.

    JAPNESEMAN         Which document install, Japanese or English.
                       According to definition of this parameter,
                       result of make is different.  Sorry, but
                       English documents are not complete.

       You need to configure the following parameter if you want to use
  the function for changing engine.  In this case, see document in
  doc/misc as engine.tx.

    engineSwitch       Use the function for changing engine, or not.
                       If use, then define this parameter.

    kinput2SrcDir      Directory for kinput2's sources.

    wnn4SrcDir         Directory for wnn4's sources.

    sj3SrcDir          Directory for sj3's sources.

       For example, the default setting is:

                cannaBinDir = /usr/local/canna/bin
                cannaSrvDir = /usr/local/canna/bin
                cannaLibDir = /usr/local/canna/lib
                cannaManDir = /usr/local/canna/man
                cannaIncDir = /usr/local/canna/include/canna
                libCannaDir = /usr/lib
                ErrDir = /usr/spool/canna
                LockDir = /usr/spool/canna/lock
                wcharDefinition = -DCANNA_WCHAR
                Wlib =
                JapaneseLocale = japan
                cannaOwner = bin
                cannaGroup = bin
                pointerIntegerDef =
                sharedLibExtension = so.1
                cannaDsoRev = 1
                DicDir = $(cannaLibDir)/dic
                LockFile = .CANNALOCK
                #define JAPANESEMAN
                /* #define engineSwitch */
                kinput2SrcDir = /work/X11R5/contrib/im/kinput2
                wnn4SrcDir = /work/X11R5/contrib/im/Xsi/Wnn

       The definition of wcharDefinition is a blank when you use the
  system definition of wchar_t and the functions as mbstowcs etc.  In
  following case, you define -DCANNA_WCHAR to wcharDefinition.  The
  cases are there is no system definition of them, or there are not
  Japanese environment (ex. /usr/lib/locale/ja_JP etc) although the
  function mbstowcs are.

       Without definition of wcharDefinition, you must configure the
  parameter JapaneseLocale.  Here is the locale name which defined on
  your OS and recognize the EUC.  The locale name is as follows:

      japanese	 SUN JLE
      japan	 NEC EWS4800
      ja_JP.EUC	 SONY NEWS

1.2 Configure Environment in widedef.h

       In this version, wcharDefinition is -DCANNA_WCHAR in default
  and wchar_t define 4 byte width and 32 bits.

       If you use the your system definition of wcahr_t, read
  following and specify a blank to wcharDefinition.

       Without -DCANNA_WCHAR, you should rewrite the file
  canna/widedef.h to use correctly the system definition.  Especially,
  when you compile with GCC, take care that which definition in which
  header file is used.

       Change the following line in widedef.h according to your OS.

    /* replace widec.h instead, if SunOS 4.0 */
    #include <stddef.h>

       On SunOS without JLE or EWS-UX/V etc, sometimes wchat_t type is
  defined twice, because _WCHAR_T macro isn't defined though wchar_t
  type is defined.  Confirm that _WCHAR_T is defined with wchar_t type
  definition.  For details, see the last of this file.  The typical
  definition of wchar_t type is as follows:

      #ifndef _WCHAR_T
      #define _WCHAR_T
      typedef unsigned long wchar_t;
      #endif

2. Compile Canna

       Canna is compiled and installed with Imakefile on X11.
  Imakefile is a Makefile which not depend on machine.  Imake, it is a
  program, creates Makefile for your machine from Imakefile.  You need
  imake (or xmkmf, it is a shell script to call imake) when compile a
  software based on X.  Because of this, we advice to install imake if
  you didn't install it.

       Here, we assume that you installed imake.

       When you have the environment for imake, enter the following.

    xmkmf; make Makefile
    make canna

       In first line, you have new Makefile which based on parameter
  of Canna.conf on top directory.

       In second line, it run as follows:

    (1) make Makefile

          Create new makefiles from Imakefile in all subdirectories.

    (2) make clean

          Clear all of the directories.

    (3) make includes

          Link each header files in the directory include.  And
          configure the class of directories.  This needs the program
          mkdirhier.  If you cannot find mkdirhier in /usr/bin/X11,
          then install it in $(BINDIR).  It is in mit/util on release
          tape of X windows.

    (4) make depend

          Reflect the relationship of files in each directories to
          Makefile.  Additionally, run yacc and lex, and make symbolic
          link files.  Here, you need the program makedepend.  If you
          don't have makedepend, then install it.  It is in mit/util,
          too.

    (5) make

          Compile programs.

3. Install Canna

3.1 Set up the Communication Environment

       Set up the port number to communicate between a kana-to-kanji
  conversion server and clients.  Add the following line in
  /etc/services.

    canna	5680/tcp

       (If you use NIS, add the line in database on master server.)

       If you have used Canna for a long time, you find the following
  line in /etc/services.  In this case, leave the line and add the
  above line in the file.

    iroha	5680/tcp

3.2 Installation

       For installation of Canna, run any one of following commands in
  top directory of Canna's sources.

    (1) make install

          Install from (3) to (5) below.

    (2) make install.man

          Install the documents of each command in $(cannaManDir).

    (3) make instserver

          Install the kana-to-kanji conversion server and its
          environment.

    (4) make instclient

          Install the clients of Canna and its environment.

    (5) make instsgs

          Install the libraries, the header files and so on to compile
          Canna.

          Install in each directories specified in Canna.conf.

3.3 Configuration of Directories

       Below, I would like to describe the configuration of Canna's
  sources.

    -+ lib ----+- RK       Library of kana-to-kanji conversion engine
     |         +- RKC      Library to communicate with kana-to-kanji 
     |         |           conversion server
     |         +- canna    Library for clients
     |         +- RKWnn    Library to communicate with jserver
     |         |           (*Note: Need the library of kinput2.)
     |         +- RKSj3    Library to communicate with sj3serv
     |         |
     |         +- RKC16  ¨¤
     |         +- canna16¨¢Libraries which wchar_t defined 16bits
     |         +- RKWnn16¨¢
     |         +- RKSj316¨¥
     |
     |                  These libraries is installed in $(libCannaDir).
     |                 
     + server           Directory of kana-to-kanji conversion server.
     |                  The server is installed in $(cannaSrvDir).
     |
     + canna            The header files
     |
     + cmd ----+*       The commands.
     |                  These are installed in $(cannaBinDir).
     |
     + ccustom          Editor for customization.  You can customize
     |                  without knowledge of lisp language.
     |
     + dic ----+ ideo   The kana-to-kanji conversion dictionaries
     |         + phono  The kana-to-kanji conversion rules
     |
     |                  These are installed in $(DicDir).
     |
     + canuum           A patch and files for uum of Canna version
     |
     + sample           A sample client
     |
     + misc             Other files
     |
     + doc              Documents

3.4 Other Files

  (1) Log file

      The kana-to-kanji conversion server writes error messages in log
      file.  You can find the log file in directory which specified as
      $(ErrDir), and it will be named "CANNA0msgs".  The default file
      is:

        /usr/spool/canna/CANNA0msgs

  (2) Lock file

      In Canna, you cannot run the servers more than twice with the
      same port number.  Because of this, the kana-to-kanji conversion
      server create a lock file.  The lock file is specified as
      $(LockDir)/$(LockFile).  The default file is:

        /usr/spool/canna/lock/.CANNALOCK

      If the conversion server cannot make the lock file, then server
      exit. 

      *Note: In default, the directory for the lock file and the log
             file is /usr/spool/canna.  But many of users specify it
             /tmp.  Therefore we don't run chown and chmod to these
             directories while compile.  If you use /usr/spool/canna
             or other as these directories, you should change the
             owner and the group of the directories as and when
             necessary.

3.5 Messaging

       In Canna, the messages of some commands to maintenance
  kana-to-kanji conversion dictionaries are internationalized.
  Therefore, on systems based on System V Release 4, such as Solaris
  2.1 or EWS-UX/V(Rel4.0), you specify the character which means
  Japanese (for example, japanese, japan, ja_JP.EUC, etc.) to
  environment variable LANG for using Japanese messages.

       Japanese messages file for respective command is
  cmd/catdic/cannacmd.jpn.  For example, on EWS-UX/V(Rel4.0), enter
  the following command to install the file in message directory of
  your system.

    # mkmsgs -i japan cannacmd.jpn cannacmd

       On each system, the command to install message file may be
  different.  For detail, see the part of messaging of the document
  for your system.

4. How to Use Canna

4.1 Owner or Group for Sever and Dictionaries

       You should restrict the access of others to keep your
  dictionaries safety.  It is advisable to create a user/group by the
  name of "canna" and set the ownership of your dictionaries to
  prevent unauthorized access.

       At this time, for the cannaserver can read, write the
  dictionaries, allow read, write by owner and group to the respective
  directories and files of dictionaries.  Next, take away others'
  permissions.  And, set owner and group of cannaserver to canna, then
  set user ID and group ID on execution.

       On System V, you may set owner and group of cannaserver to bin
  in place of canna.

       Set owner and group of your dictionaries or cannaserver to the
  parameter $(cannaOwner) and $(cannaGroup) in Canna.conf.

       Below, we assume you set owner and group to bin.

4.2 Start Kana-to-kanji Conversion Server

       Enter the following command to start kana-to-kanji conversion
  server.

    # cannaserver

       If you want to start it automatically each time the UNIX system
  is started, set to start cannaserver in the starting script(ex. 
  /etc/rc.local, etc.).  You should remove its lock file when start
  cannaserver since cannaserver cannot be started with its lock file.

       For example, add the following lines in /etc/rc.local.

     rm -f /tmp/.CANNALOCK*
     /usr/local/canna/bin/cannaserver
     echo 'cannaserver started.'

4.3 Stop Kana-to-kanji Conversion Server

       Enter the following command to stop kana-to-kanji conversion
  server.

    # cannakill

       The cannaserver save a part of information of dictionaries on
  memory.  So you should run cannakill when you stop kana-to-kanji
  conversion server.  If you kill cannaserver directly with SIGKILL,
  etc., you may lost the information on memory.

       If you want to stop it automatically each time the UNIX system
  is stopped, set to stop cannaserver in the shutdown script.

4.4 Dictionaries

  (1) Kana-to-kanji conversion dictionaries

       We call the directory "dic home directory" in which there are
       kana-to-kanji conversion dictionaries.  This directory is
       specified as $(DicDir) or specified in command line as follow:

         ex.) In case you specify "dic home directory" to
              /usr/lib/canna/dic

                # cannaserver /usr/lib/canna/dic

       Below, we show the configuration of "dic home directory".

              -+-- *.rdic
               |           Romaji-to-kana conversion rules
               +-- canna
               |           Directory of your own system's dictionaries
               +-- user/*
               |           Directory of user's dictionaries
               +-- group/*
                           Directory of group's dictionaries

       Allow cannaserver to read and write dic home directory, any
       subdirectories and any files in there.  (See 4.1.)

  (2) Romaji-to-kana conversion rules

       In default, cannaserver searches romaji-to-kana conversion
       rules in /usr/local/canna/lib/dic.  If you want to use another
       file as romaji-to-kana conversion rules, you should specify the
       file in your own customization file "$HOME/.canna", the full
       path must be given.

4.5 Initialize(Customization) File

       In Canna, each user can have a own initialize(customization)
  file.  You can set your own environment to input Japanese easily by
  editing the file.  You can specify key bindings, romaji-to-kana
  conversion rules, kana-to-kanji conversion dictionaries, etc.

5. Compilation and Installation of Canna when you cannot become super
   user

       You are able to compile and install as following when you
  cannot become super user.

5.1 Configure the Environment in Canna.conf

       Specify the directories in which installed commands and
  dictionaries to your own directories.  And, specify owner and group
  of cannaserver to your own.  For example, as follows:

                cannaBinDir = /home/kon/canna/bin
                cannaSrvDir = /home/kon/canna/bin
                cannaManDir = /home/kon/canna/man
                cannaLibDir = /home/kon/canna/lib
                cannaIncDir = /home/kon/canna/include/canna
                libCannaDir = /home/kon/canna/lib
                DicDir = $(cannaLibDir)/dic
                ErrDir = /home/kon/spool/canna
                LockDir = /home/kon/spool/canna/lock
                LockFile = .CANNALOCK
                wcharDefinition = -DCANNA_WCHAR
                Wlib =
                JapaneseLocale = japanese
                sharedLibExtension = so.1
                cannaOwner = kon
                cannaGroup = user

       Add a following line in Canna.conf

                INCROOT = /home/kon/canna/include

       Rewrite the commands, that is chown, chgrp, chmod, etc., in
  Canna.conf as below:

                CHOWN = echo
                CHGRP = echo
                CHMOD = echo

5.2 Compilation and Installation

       In case imake on X11R6 is installed on your machine, enter the
  following commands to compile and install Canna.

    xmkmf
    make Makefile
    make canna
    make install
    make install.man

       In case you are able to get the sources of X11R6, although
  X11R6 was not installed on your machine, you should get mit/config
  and mit/util of the sources, and run make in config and util in the
  order.

       For compilation in config and subdirectories, compile as
  following after rewriting BOOTSTRAPFLAG in config/Makefile.ini
  according to your machine.

    make -f Makefile.ini

       For compilation in util and subdirectories, enter the following
  line in util.

    ../config/imake -I../config -DTOPDIR=.. -DCURDIR=Canna32

       And, after creating Makefile from Imakefile, enter the following
  lines to compile util.

    make Makefile
    make

       When finish, move each command in util to any directory in your
  home directory, and add the directory to search paths.

       We use mkdirhier command to make canna.  But this command is
  specified $(BINDIR) of X.  To clear this problem, edit a suitable
  file in config, or specify in Canna.conf as follow:

    BINDIR=/home/kon/xutil

       When finish, run imake as following in the top directory which
  you compile Canna (there is Canna.conf in the directory).

    ex.) 
    % ../config/imake -I../config

       And run follows:

    % make Makefile
    % make canna
    % make install

5.3 Set up the Communication Environment

       You aren't able to rewrite /etc/services if you cannot become
  super user.  But you can run cannaserver and use libraries with port
  number 5680 without the description in /etc/services.  In this case,
  cannaserver output warning messages in log file each time
  cannaserver is started.

Appendix A. Notes on Each OS

A.1 EWS-UX/V

       Wchar_t type is defined in stdio.h, but, in some versions,
  WCHAR_T is not defined.  In this occasion, rewrite stdio.h as
  following:

    #ifndef _WCHAR_T
    #define _WCHAR_T
    typedef unsigned short  wchar;
    typedef unsigned short  wchar_t;        /* R31KNCK02 */
    #endif

       If you hesitate to rewrite /usr/include/stdio.h, first, run
  from 1. to 2. (3).  Next, copy the file in top directory of Canna,
  rewrite the file and continue compilation from 2. (4).

A.2 FT-UX/V

       There will be some warning messages to compile with -Xc.  It
  occur in stdio.h and sys/byteorder.h.  If you want to suppress the
  warning message, you may rewrite the header file.

A.3 SunOS

  * Without JLE

      Rewrite the definition of wchar_t in /usr/include/sys/stdtypes.h
      as following.

        #ifndef _WCHAR_T
        #define _WCHAR_T
        typedef	unsigned short	wchar_t; /* big enough for biggest char set */
        #endif

      It is a good idea that you define -DCANNA_WCHAR to
      wcharDefinition in Canna.conf.

      If you hesitate to rewrite /usr/include/stdtypes.h, first, run
      from 1. to 2. (3).  Next, copy the file in top directory of
      Canna, rewrite the file and continue compilation from 2. (4).

  * In case using shared object

      In this case, specify two revisions, major revision and minor
      revision, to $(cannaDsoRev) in Canna.conf as following.

        cannaDsoRev=1.1

A.4 SONY NEWS

       In locale of Japanese, you can change code from SJIS to EUC or
  the other way around.  Canna have some character of EUC in sources,
  so enter the following lines (that is in case of csh) when compile
  Canna on NEWS, and then compile Canna.

    % setenv LANG ja_JP.EUC
    % stty euc sys
 
A.5 HP-UX (This discription is originally written by Takashi Matsuzawa.)

       When you use shared libraries, the libraries are searched by
  the path name which specified at time linked objects.  For example,
  you want to search libcanna.sl as /usr/local/lib/libcanna.so, put
  libcanna.sl in /usr/local/lib and link it.  Because of this, we
  recommend to install Canna as follows:

    (1) Specify UseInstalledLibCanna NO in Canna.conf
    (2) % make canna
    (3) % make install
    (4) Specify UseInstalledLibCanna YES in Canna.conf
    (5) % make canna
    (6) % make install

       Now, imake is not installed on HP-UX.  The configuration file
  to make shared library for HP-UX is not included on X11R5 which
  distributed by MIT.  For these, see below ftp site.

    hpcvaaz.cv.hp.com [15.255.72.15] ~ftp/pub/MitX11R5

A.6 OS Based on NET/2, for example, 386BSD, BSD/386, etc.

       Now, wchar_t is defined as below in stddef.h on 4.4BSD.

     #ifdef	_WCHAR_T_
     typedef	_WCHAR_T_	wchar_t;
     #undef	_WCHAR_T_
     #endif

       But this definition contradicts its on other OS, so we have
  some errors when compile on 4.4BSD.  So this definition is expected
  to change as below on 4.4BSD.

     #ifdef	_BSD_WCHAR_T_
     typedef	_BSD_WCHAR_T_	wchar_t;
     #undef	_BSD_WCHAR_T_
     #endif

       Change _WCHAR_T to _BSD_WCHAR_T_ in machine/ansi.h and rewrite
  as following in stdlib.h and stddef.h.

     #ifdef	_BSD_WCHAR_T_
     #ifndef    _WCHAR_T
     #define    _WCHAR_T
     typedef	_BSD_WCHAR_T_	wchar_t;
     #endif
     #undef	_BSD_WCHAR_T_
     #endif

       On FreeBSD 1.1.5(RELEASE), wchar_t is defined as bellow.  In
  this case, we recommend you to delete upper 4 line and do above.

     #ifdef	_WCHAR_T_
      typedef	_WCHAR_T_	wchar_t;
      #undef	_WCHAR_T_
     #endif
     #ifdef  _BSD_WCHAR_T_
      #ifndef _ANSI_SOURCE
       typedef _BSD_WCHAR_T_   rune_t;
      #endif
      typedef _BSD_WCHAR_T_   wchar_t;
      #undef  _BSD_WCHAR_T_
     #endif

       If you hesitate to rewrite /usr/include/stddef.h, first, run
  from 1. to 2. (3).  Next, copy the file in top directory of Canna,
  rewrite the file and continue compilation from 2. (4).

       When you use ccustom on 386BSD, see ccustom/README.386. (Sorry,
  README.386 is in Japanese.)

A.7 OS Based on MACHTEN

       Do the same thing as above A.6 on machine/machtypes.h instead
  of machine/ansi.h.

A.8 AIX (This discription is originally written by Tomotake Furuhata.)

       Imake is included in X11dev.src of the installation tape for
  operation system.  You need which imake included this tape or MIT of
  R5 or R6.

A.9 In case you specify "#define X_WCHAR" in X11/Xosdf.h or run cc
  with -DNOSTDHDRS

       In these case, when you include Xlib.h, wchar_t type is defined
  in Xlib.h.  Wchar_t type is defined as following in the original
  Xlib.h on X11R6. 

    #ifndef X_WCHAR
    #include <stddef.h>
    #else
    /* replace this with #include or typedef appropriate for your system */
    typedef unsigned long wchar_t;
    #endif

       Replace typedef appropriate for your system according to above
  comment line, or rewrite as following in Xlib.h.

    #ifndef X_WCHAR
    #include <stddef.h>
    #else
    #ifndef _WCHAR_T
    #define _WCHAR_T
    typedef unsigned long wchar_t;
    #endif
    #endif

       If you hesitate to rewrite /usr/include/X11/Xlib.h on your
  system, first, run from 1. to 2. (3).  Next, copy the file in top
  directory of Canna, rewrite the file and continue compilation from
  2. (4).

/* Copyright 1994 NEC Corporation, Tokyo, Japan.
 *
 * Permission to use, copy, modify, distribute and sell this software
 * and its documentation for any purpose is hereby granted without
 * fee, provided that the above copyright notice appear in all copies
 * and that both that copyright notice and this permission notice
 * appear in supporting documentation, and that the name of NEC
 * Corporation not be used in advertising or publicity pertaining to
 * distribution of the software without specific, written prior
 * permission.  NEC Corporation makes no representations about the
 * suitability of this software for any purpose.  It is provided "as
 * is" without express or implied warranty.
 *
 * NEC CORPORATION DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
 * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN 
 * NO EVENT SHALL NEC CORPORATION BE LIABLE FOR ANY SPECIAL, INDIRECT OR
 * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF 
 * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR 
 * OTHER TORTUOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 
 * PERFORMANCE OF THIS SOFTWARE. 
 */

($Id: INSTALL,v 2.12 1994/07/21 09:12:05 misao Exp $)
