home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-385-Vol-1of3.iso / c / comp-faq.zip / COMP-FAQ next >
Text File  |  1993-01-27  |  63KB  |  1,638 lines

  1.  
  2.  
  3.  
  4.         FREQUENTLY ASKED QUESTIONS ABOUT COMPILING KHOROS
  5.  
  6.         date last updated: Sept 25, 1992
  7.                        Sept 28, 1992
  8.                       fixed A3, A6, A9, Q28, added Q29
  9.                    Oct  03, 1992
  10.                       added new Q1, Q2, Q4, Q5, Q6, 
  11.                       scooted other #'s down
  12.                    Oct  27, 1992
  13.                       added Q35 - Q37
  14.  
  15.                 ( Please Read!  Please Redistribute! )
  16.  
  17.                 ( Also - Please See the General Khoros FAQ )
  18.  
  19.         Contents:  Questions 1 - 37
  20.  
  21.                    * installing Khoros on IBM RS6000, 386/486, HP
  22.            * compiling Khoros with shared libraries
  23.            * compiling Khoros with X11R5
  24.            * Makefiles, Imakefiles (compiling new programs)
  25.            * compiling with/without FORTRAN
  26.            * compiling with gcc
  27.            * and more!
  28.  
  29.  
  30. ----------  Installing Khoros on various architectures -----
  31.  
  32. Q1.  What machines does Khoros currently run on?
  33.  
  34. Q2.  I have machine X running operating system Y (not listed in A1).
  35.      Has anyone ported Khoros to this architecture?
  36.  
  37. Q3.  I want to install Khoros on an IBM RS/6000 workstation
  38.      running under AIX x.x {and am getting error messages from the
  39.      C compiler} {and would like more info} {has anybody done this}
  40.      {are binaries available}?.
  41.  
  42. Q4.  I want to install Khoros on a 386/486 machine {and am getting 
  43.      error messages from the C compiler} {and would like more info} 
  44.      {has anybody done this} {are binaries available}?.
  45.  
  46. Q5.  I want to install Khoros on an HP under HP-UX x.x {9000/s370, 
  47.      s400, s800, or s700}.  {and am getting error messages from the 
  48.      C compiler} {and would like more info} {has anybody done this} 
  49.      {are binaries available}?.
  50.  
  51. Q6.  I want to install Khoros on a Convex,  under ConvexOS x.x
  52.      {and am getting error messages from the C compiler} {and 
  53.      would like more info} {has anybody done this} {are binaries available}?.
  54.  
  55. Q7.  Can I run Khoros on my PC? Is Khoros available for PC's running DOS?
  56.  
  57. Q8.  Is there a port of Khoros for a VMS system?
  58.  
  59.  
  60. -----------  Compiling with shared libraries -----
  61.  
  62. Q9.  What are shared libraries?  Does Khoros work with shared libraries?  
  63.      What are the advantages/disadvantages of using shared libraries?
  64.      Should I compile Khoros with shared libraries?
  65.  
  66. Q10. Why do I get unresolved references when I compile Khoros with
  67.      shared libraries on a SUN4?
  68.  
  69. Q11. When compiling shared, I get a large set of errors from
  70.      the loader listed in my make.World file, as in:
  71.  
  72.         rm -f vadd
  73.         cc -o vadd vadd.o  -L/home/holst/khoros/lib -L/mnt/elocal/lang/SC1.0
  74.         -O -Bdynamic -lghost  -lvexpr  -lnum_anal  -ldspl  -lformat
  75.         -lgeo_surf  -lvipl  -lvutils  -lvmath  -lvrast  -lvgparm  -lverror
  76.         -ltiff  -lm -ll -ldl
  77.         ld: Undefined symbol
  78.            _cg_
  79.            _zgedi_
  80.            _zgeco_
  81.            _zgesl_
  82.            _zsvdc_
  83.            _ch_
  84.            _dgesl_
  85.            _dgefa_
  86.            _e_wsfe
  87.            _pow_ii
  88.            _s_wsFe
  89.            _s_stop
  90.         *** Error code 2
  91.         install in ./vipl/arith_binary/vadd done
  92.         make: Warning: Target `install' not remade because of errors
  93.  
  94. Q12. I am compiling [some xvroutine] against X11R5 with shared libraries.
  95.      The linker produces this error message:
  96.  
  97.      ld: /lib/libXaw.sa.5.0(sharedlib.o): _formWidgetClass: multiply defined
  98.          /lib/libXaw.sa.5.0(sharedlib.o): _labelWidgetClass: multiply defined
  99.      *** Error code 2
  100.      make: Fatal error: Command failed for target `{xvroutine}'
  101.  
  102. Q13. I am having problems using cantata (or other xvroutine)
  103.      after recently compiling on a SUN with shared libraries.  I get the
  104.      error message:
  105.  
  106.      Warning: Widget class VendorShell version mismatch (recompilation needed):
  107.        widget 11004 vs. intrinsics 11003.
  108.      Warning: Widget class Form version mismatch (recompilation needed):
  109.        widget 11004 vs. intrinsics 11003.
  110.  
  111.  
  112. Q14. Warpimage {or other xvroutine} did not compile after on a SUN4
  113.      architecture with static libraries;  in fact, it made the cc compiler
  114.      segmentation fault and core dump!  What happened?
  115.  
  116.  
  117. Q15. Khoros compiled ok under shared libraries.  However, when I try to
  118.      use the programs, I get messages that say:
  119.      lib{something}.so.1 not found
  120.  
  121. ------------  Compiling with X11R5 -----
  122.  
  123. Q16. Can I compile Khoros with X11R5?
  124.  
  125. Q17. I am compiling Khoros with MIT's X11R5.  When linking xvroutines
  126.      (cantata, editimage, etc), the compiler tells me that
  127.      _viewportWidgetClass is multiply defined.  What's the problem?
  128.  
  129.  
  130. ------------  Makefiles, Imakefiles (compiling new programs) -----
  131.  
  132. Q18. I don't want to compile Khoros source, but I want to compile
  133.      my own programs so I need the libraries. How can I obtain the
  134.      Khoros libraries?
  135.  
  136. Q19. I am trying to compile an xvroutine, and when I run make install
  137.      I get the error:
  138.      installing in ./{xvroutine}...
  139.      Make:  Don't know how to make {KHOROS_HOME}/lib/libdisplay.a.
  140.      Stop.
  141.      *** Error code 1
  142.  
  143. Q20. I want to link a {vroutine/xvroutine} for dbx.
  144.  
  145. Q21. I want my {vroutine/xvroutine} to use some specific 
  146.      include files and special libraries.
  147.  
  148. Q22. Is there a way to get ghostwriter to automatically generate 
  149.      the Makefile so that it will look for other include directories 
  150.      and libraries?
  151.  
  152. ------------  Compiling With gcc -----
  153.  
  154. Q23. I'm having a problem with gcc:
  155.  
  156.      % gcc test.c -I/usr/local/include -I$KHOROS_HOME/include
  157.  
  158.      In file included from KHOROS_HOME/include/vinclude.h:128,
  159.      from test.c:3:
  160.      KHOROS_HOME/include/vdefines.h:219: conflicting types for `malloc'
  161.      /usr/local/{...}/include/malloc.h:41: previous declaration of `malloc'
  162.      KHOROS_HOME/include/vdefines.h:223: conflicting types for `calloc'
  163.      /usr/local/{...}/include/malloc.h:39: previous declaration of `calloc
  164.  
  165. Q24. I noticed in the make.World file is that a few files are compiled 
  166.      using 'cc', while some others are compilied using 'gcc'. Is this normal? 
  167.      Also, there were messages like: 
  168.      gcc: file path prefix `dynamic' never used
  169.  
  170.  
  171. ------------  Compiling With/Without FORTRAN -----
  172.  
  173. Q25. Do I HAVE to have FORTRAN to compile Khoros?  Which Khoros programs
  174.      will I miss out on if I don't compile with FORTRAN?
  175.  
  176. Q26. How do I compile the Khoros system without FORTRAN?
  177.  
  178. Q27. I don't have a FORTRAN compiler, but I need the Khoros programs that
  179.      use FORTRAN.  What can I do?
  180.  
  181. Q28. I am writing a {vroutine/xvroutine} in which I need to make a call
  182.      from my C code to a FORTRAN subroutine.  How do I do this?
  183.  
  184. Q29. I am setting up my *.cf configuration file in preparation for compiling
  185.      Khoros.  How do I find out what libraries the linker expects in order
  186.      to link C code against FORTRAN, in order to provide the proper
  187.      libraries for the ForSysLibs option?
  188.  
  189. ------------  Miscellaneous -----
  190.  
  191. Q30. I seem to be having some trouble getting Khoros working on our Sun 3.
  192.      I have tried executing {cantata, editimage, etc}  {journal playbacks},
  193.      but I keep getting the error "ld.so: libXaw.so.4: not found".
  194.  
  195. Q31. Since RPC isn't implemented yet, I defined UseSunRPC as NO in my 
  196.      sun.cf file. Compiling phantomd results in the following message:
  197.           ld: Undefined
  198.           _sunrpc_tempnam
  199.           _sunrpc_gethostname
  200.  
  201. Q32. On Sun3, OS 4.1.1, a segmentation fault results when cantata is run.
  202.  
  203. Q33. During the compile of Khoros, I get this error message:
  204.          /: write failed, file system is full
  205.          compiler(iropt) error:  write_irfile: No space left on device
  206.  
  207. Q34. I am trying to compile a {toolbox, new program, etc}, but "make"
  208.      keeps giving me error messages that say:
  209.  
  210.      make: Fatal error:
  211.      Don't know how to make target `{KHOROS_HOME}/lib/lib{something}.a
  212.  
  213. Q35. Where in the Khoros Manual is the documentation relating to installation
  214.      of programs in Khoros?
  215.  
  216. Q36. How does one selectively fix a program and recompile it without doing
  217.      the whole installation process again?
  218.  
  219. Q37. When I try to compile dzresp, dfilter, mat2viff, etc., I get 
  220.      unresolved symbols for _dspl_parse, _format_parse, and _vexpr_parse.
  221.      Where do I find these routines?
  222.  
  223. ===============================================================================
  224.  
  225. ===========   Installing Khoros on Various Architectures ======================
  226.  
  227.    Q1.  What machines does Khoros currently run on?
  228.  
  229.    A1.  Khoros 1.0 compiles on the following machines (MIT X unless
  230.         otherwise noted):
  231.  
  232.         ApolloDN10000      OS 10.3, Fortran 10.8, cc 6.8
  233.         CRAY YMP's, XMP's, Cray II's running UNICOS 6.0, and 6.1.
  234.         DEC   5000/3100    Ultrix 4.2, mips cc 2.0, DEC f77 V3.0-2
  235.         DEC   Vax 3600     Ultrix 4.1, cc1.37.1
  236.         HP    9000/*       HP-UX 7.05, HP-UX 8.05
  237.         IBM   RS/6000      AIX v3.1
  238.         OMRON Luna88k      Mach 2.5, gcc 1.37, f77 1.8.5
  239.         NeXT  68030,40     MACH 2.0, gcc 1.37, Absoft f77 2.0, Pensoft X
  240.         SGI   All          OS 3.3.2, OS 4.0, X11 1.2, f77 3.3
  241.         SUN   SPARCstations, SUN4   SUN OS 4.1.1, f77 1.4.5
  242.         SUN   SUN3/        SUN OS 4.1.1, f77 1.3.1, gcc 1.39/2.0
  243.  
  244.         As of Patch 5, increased support was added for:
  245.  
  246.         Convex C220, running ConvexOS 9.1 with standard C compiler
  247.         MacII running A/UX 2.0.1 using gcc-1.39 as C compiler.
  248.         DG Aviion running DG/UX 4.3 (thanks to Bob Clark)
  249.         Intel 386/486 running Interactive Unix  (thanks to Maurizio Davini)
  250.         Luna 88K running Mach 2.0  (thanks to Ping-Kang Hsiung & Hideo Noro)
  251.  
  252.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  253.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  254.  
  255.    Q2.  I have machine X running operating system Y (not listed in A1).
  256.         Has anyone ported Khoros to this architecture?
  257.  
  258.    A2.  Currently, Khoros is being / has been ported by various people
  259.         in the Khoros user community to a variety of architectures,
  260.         including the Alliant VFX/2800, Apollo 425T, Convex C220,
  261.         DG Aviion, Fujitsu VP2200/10, IBM RS6000, Integraph
  262.         Interpro, MacII, Sony 3710, and some 386/486 machines.
  263.  
  264.         At this time, these platforms are not directly supported by the
  265.         Khoros group.  For more details, you may mail to
  266.         danielle@bullwinkle.eece.unm.edu; she is compiling a list of Khoros
  267.         ports, and can give you the information that she has so far.
  268.  
  269.         If YOU have done a port of Khoros to machine X running operating
  270.         system Y, she would very much appreciate a letter from you,
  271.         specifying:
  272.  
  273.            1) your name and place of employment (phone number optional)
  274.            2) your return email address
  275.            3) which version of Khoros you ported,
  276.            4) which machine /operating system you ported to
  277.            5) comments you might like to make.
  278.  
  279.         If you *do not* want to be contacted by other Khoros users, simply
  280.         say so and your name / email address will not be released.
  281.  
  282.  
  283.  
  284.  
  285.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  286.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  287.  
  288.  
  289.    Q3.  I want to install KHOROS on an IBM RS/6000 workstation
  290.     running under AIX x.x {and am getting error messages from the 
  291.         C compiler} {and would like more info} {has anybody done this}
  292.     {are binaries available}?.
  293.  
  294.    A3.  The Khoros group at UNM cannot help you directly with compiler errors
  295.         from the RS/6000, as they do not have an RS/6000 to test on.  However, 
  296.         binaries are available from an ftp site in Italy (thanks, Maurizio!) 
  297.         and advice from Nagarajan Ramesh has proven valuable to many:
  298.  
  299.         (1) Maurizio Davini (mau@ipifidpt.difi.unipi.it)
  300.  
  301.             Has ported Khoros 1.0 P5 to the IBM RS6000 running AIX 3.2;
  302.  
  303.             He has an official ftp site in Pisa, Italy, which includes the
  304.             Khoros source & system distribution, plus binaries for the
  305.             IBM RS6000 and Interactive Unix 2.2.1, available via anonymous ftp:
  306.  
  307.             address   = ipifidpt.difi.unipi.it (131.114.8.130)
  308.                  ftp  = anonymous (ftp)
  309.               passwd  = user@machine
  310.             directory = /pub/khoros
  311.             binaries  = /pub/khoros/bin/RS6000
  312.  
  313.         The khoros distribution is available also under our gopher server
  314.         ipifidpt.difi.unipi.it port 70
  315.  
  316.         (2) Nagarajan Ramesh (nagraj@watson.ibm.com)
  317.  
  318.             Has ported Khoros 1.0 P5 to IBM RS/6000 running AIX 3.1.5.
  319.             Has these comments for compiling on the RS6000 with AIX 3.1.5:
  320.  
  321.             "I substituted the bsd compiler for the 'cc' compile command, and
  322.             it works.  To do this you have to modify  your /etc/xlc.cfg file by
  323.             including the following stanza - EXACTLY THE WAY IT IS.
  324.  
  325.             bsdcc:  use             = DEFLT
  326.                     crt             = /lib/crt0.o
  327.                     mcrt            = /lib/mcrt0.o
  328.                     gcrt            = /lib/gcrt0.o
  329.                     libraries       = -lbsd, -lc
  330.                     proflibs        = -L/lib/profiled,-L/usr/lib/profiled
  331.                     options         = -H512,-T512, -qlanglvl=extended, -qnoro,
  332.                                       -D_BSD, -D_NONSTD_TYPES, -D_NO_PROTO,
  333.                                       -D_BSD_INCLUDES, -bnodelcsect,
  334.                                       -U__STR__, -U__MATH__
  335.  
  336.             Then, define a symbollic link from /bin/bsdcc to /bin/xlc.
  337.             You also have to change the 'cc' to 'bsdcc' in the ibm.cf file."
  338.  
  339.  
  340.  
  341.         (3) In addition, the following people have ported Khoros 1.0 P5
  342.             to IBM RS/6000 running AIX 3.2, and have been willing to answer
  343.             questions in the past:
  344.  
  345.             * Roque Donizete De Oliveira (oliveria@caen.engin.umich.edu)
  346.             * Edmond Mesrobian (edmond@cs.ucla.edu)
  347.             * Nick Kisseberth (nkissebe@delphi.beckman.uiuc.edu)
  348.  
  349.  
  350.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  351.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  352.  
  353.     Q4.  I want to install KHOROS on a 386/486 machine {and am getting 
  354.      error messages from the C compiler} {and would like more info} 
  355.      {has anybody done this} {are binaries available}?.
  356.  
  357.     A4.  (1) Scott Wilson (swilson@chama.eece.unm.edu)
  358.  
  359.             Khoros 1.0 P5 to Intel 486 based platform running Interactive
  360.             Unix System V/386 Release 3.2, Version 3.0. All software was
  361.             stock Interactive except  for the use of gcc2.2.2 as a compiler
  362.             and f2c to handle the fortran code.
  363.  
  364.             He is providing the Khoros 1.0 P5 on the main Khoros server.
  365.  
  366.             address   = pprg.eece.unm.edu (129.24.24.10)
  367.                  ftp  = anonymous (ftp)
  368.               passwd  = user@machine
  369.             directory = /pub/khoros
  370.             binaries  = /pub/khoros/bin/bin486
  371.             libraries = /pub/khoros/bin/lib486
  372.  
  373.  
  374.         (2) Maurizio Davini (mau@ipifidpt.difi.unipi.it)
  375.  
  376.             Khoros 1.0 to Interactive unix 386 2.2.1, using gcc 1.40 ,f2c
  377.             and X386 (the public domain version X11r4 of T.Roell).
  378.  
  379.             He is providing the Khoros 1.0 P5 binaries for Interactive
  380.             Unix 2.2.1, plus binaries for IBM RS6000 running AIX 3.2 via
  381.             anonymous ftp:
  382.  
  383.             address   = ipifidpt.difi.unipi.it (131.114.8.130)
  384.                  ftp  = anonymous (ftp)
  385.               passwd  = user@machine
  386.             directory = /pub/khoros
  387.             binaries  = /pub/khoros/bin/ISC-2.2.1
  388.                         /pub/khoros/bin/RS6000
  389.  
  390.             In the directory 386ix, you can also find the X11R4,
  391.             fortran compiler, and math library he used to compile Khoros.
  392.             For more information, please contact Maurizio.
  393.  
  394.  
  395.         (3) Dominic Richens (dominic@shamin.genie.uottawa.ca or
  396.                              richens@panda1.uottawa.ca)
  397.  
  398.             Khoros 1.0 P5 to HP Vectra RS-25C (386 box) running
  399.             SCO System V 3.2.2 ODT 1.1.
  400.  
  401.             He is providing the Khoros 1.0 P5 system with shell scripts
  402.             and patches needed to build Khoros under SCO ODT 1.1
  403.             via anonymous ftp:
  404.  
  405.             address   = popeye.genie.uottawa.ca (137.122.20.3)
  406.                  ftp  = anonymous (ftp)
  407.               passwd  = user@machine
  408.             directory = /pub/khoros
  409.  
  410.  
  411.         (4) Ulrich Breuer (breuer@pool.informatik.rwth-aachen.de)
  412.  
  413.             Used Maurizio Davini's port of Khoros 1.0 P5 as a starting point,
  414.             in order to port Khoros 1.0 P5 to 386ix running ISC Version 2.2 with
  415.             gcc-2.2.2 and no fortran.
  416.  
  417.             His configuration file, as well as a summary of the changes
  418.             necessary for doing the port may be obtained from Danielle Argiro
  419.             (danielle@chama.eece.unm.edu), or directly from him.
  420.  
  421.  
  422.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  423.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  424.  
  425.     Q5.  I want to install Khoros on an HP {9000/s370, s400, s800, or s700}.
  426.      {and am getting error messages from the C compiler} {and would like 
  427.      more info} {has anybody done this} {are binaries available}?.
  428.      
  429.     A5.  (answer thanks to Konstantinos Konstaninides, Hewlett-Packard 
  430.           Laboratories, Palo Alto, CA, kk@hpkronos.hpl.hp.com)
  431.  
  432.      Binaries are not available for the HP, but you should be able to
  433.      compile quite easily provided you have the complete C compiler
  434.      and a Fortran compiler.  To port khoros 1 patch 5 to HP-UX on an 
  435.      HP9000/s370, s400, s800, or s700, the following steps were taken.
  436.      
  437.      1. Get the Xaw and Xmu libraries and include files
  438.         from hpcvaaz.cv.hp.com:~ftp/pub/MitX11R4/libs.s300.Z (or libs.s800.Z
  439.         for the snakes) using anonymous ftp.
  440.      
  441.         As an alternative, you can also get the X11R5 libraries from
  442.         ~ftp/pub/MitX11R5 (same machine). This is probably the preferred
  443.         approach if you want to use X11 shared libraries.
  444.      
  445.         Uncompress and untar them into your favorite directory.
  446.      
  447.         NOTE: Don't mix those binaries with HP binaries in /usr/lib/X11R4
  448.         and the include files with include files in /usr/include/X11R4.
  449.         Unpredictable core dumbs may happen!
  450.         Instead use /usr/local/X11R4 or /usr/lib/X11R5 or whatever else
  451.         you like.
  452.      
  453.         (Ignore this step if you already have somehow the above
  454.         include files and libraries in your system.)
  455.      
  456.      2. Edit src/xvroutines/Lib/xvforms/Imakefile
  457.         Remove:
  458.         #define UnsharedObjs
  459.         UNSHAREDOBJS =\
  460.                 init.o
  461.      
  462.        and include init.o with the other objects.
  463.      
  464.      3. Edit $KHOROS_HOME/repos/config/imake_conf/hp.cf
  465.         and $KHOROS_HOME/repos/config/imake_conf/Lib/hpLib.rules
  466.      
  467.        as shown in the diffs file below
  468.        The changes fix the following problems:
  469.        a) Strip automatically the binaries (-s)
  470.        b) On the s700 solve the "too much defining" error message. (-Wp,..)
  471.        c) Include the appropriate Fortran libraries in the linking
  472.            of C code, since some khoros libraries use FORTRAN routines too.
  473.        d) Eliminate the -Dxxxx in f77 calls (with Shared Libraries).
  474.        e) Point to the correct place for the X11 Libraries
  475.        f) Install libraries with mode 555 (otherwise code with shared 
  476.                 libraries will not run)
  477.      
  478.      4. Depending on when you got your code you may want
  479.          a) get the fixed src/dspl/Lib/ldfilter.c routine
  480.            posted in the network. (4/9/92)
  481.          b) rm khoros/src/dspl/Lib/poly_yacc.c
  482.          (b) solves a linker problem on the s400.
  483.      
  484.      5. Run installit. Everything should compile with no problems.
  485.         After the compilation do
  486.      - ----------------------
  487.      
  488.      1. edit bin/kinstall_csh, and replace "mail -s" with "mailx -s"
  489.      2. You may want to edit bin/prnmanual
  490.         (Even if you don't have troff or groff, but you have a postscript 
  491.             printer, you can still print the man pages. Only set up the printer 
  492.             command and always accept the default answers. It should print the 
  493.             existing xxxxx.ps files)
  494.      
  495.  
  496.     -------------Diffs----------------
  497.  
  498. *** hp.cf.orig    Fri Apr 10 10:44:33 1992
  499. - --- hp.cf    Fri Apr 10 10:44:33 1992
  500. ***************
  501. *** 7,15 ****
  502.    */
  503.   
  504.   
  505. ! #define OSName                 HP-UX 8.05
  506.   #define OSMajorVersion         8
  507. ! #define OSMinorVersion         5
  508.   
  509.   #define SystemV                YES
  510.   
  511. - --- 7,15 ----
  512.    */
  513.   
  514.   
  515. ! #define OSName                 HP-UX 8.07
  516.   #define OSMajorVersion         8
  517. ! #define OSMinorVersion         7
  518.   
  519.   #define SystemV                YES
  520.   
  521. ***************
  522. *** 76,87 ****
  523.   #define InstallCmd $(SCRIPTSRC)/bsdinst.sh
  524.   #define BaseName /bin/basename
  525.   
  526.   #ifdef hp9000s800
  527. ! #   define StandardDefines        -DSYSV
  528.   #   define OptimizedCDebugFlags   +O1
  529.   #else
  530.   #  if OSMajorVersion == 8
  531. ! #      define StandardDefines        -DSYSV
  532.   #  else
  533.   #       define StandardDefines    -Wc,-Nd4000,-Ns4300,-Ne700,-Np300 -DSYSV -D_BSD -Drindex=strrchr -Dindex=strchr
  534.   #  endif
  535. - --- 76,88 ----
  536.   #define InstallCmd $(SCRIPTSRC)/bsdinst.sh
  537.   #define BaseName /bin/basename
  538.   
  539. + #define InstLibFlags -m 0555
  540.   #ifdef hp9000s800
  541. ! #   define StandardDefines        -s -Wp,-H512000 -DSYSV
  542.   #   define OptimizedCDebugFlags   +O1
  543.   #else
  544.   #  if OSMajorVersion == 8
  545. ! #  define StandardDefines         -s -DSYSV
  546.   #  else
  547.   #       define StandardDefines    -Wc,-Nd4000,-Ns4300,-Ne700,-Np300 -DSYSV -D_BSD -Drindex=strrchr -Dindex=strchr
  548.   #  endif
  549. ***************
  550. *** 89,98 ****
  551.   
  552.   #if OSMajorVersion == 8
  553.   #  if defined (hp9000s300) || defined (hp9000s400)
  554. ! #    define SysLibs -lBSD -lmalloc -lm -ll
  555.   #    define ForSysLibs -lFext -lF77 -lI77
  556.   #  else
  557. ! #    define SysLibs -lBSD -lmalloc -lm -ll
  558.   #    define ForSysLibs -lcl -lfsys
  559.   #  endif
  560.   #else
  561. - --- 90,99 ----
  562.   
  563.   #if OSMajorVersion == 8
  564.   #  if defined (hp9000s300) || defined (hp9000s400)
  565. ! #    define SysLibs -lBSD -lmalloc -lm -ll -lIO77
  566.   #    define ForSysLibs -lFext -lF77 -lI77
  567.   #  else
  568. ! #    define SysLibs -lBSD -lmalloc -lm -ll -lcl
  569.   #    define ForSysLibs -lcl -lfsys
  570.   #  endif
  571.   #else
  572. ***************
  573. *** 100,106 ****
  574. - --- 101,114 ----
  575.   #   define ForSysLibs -lFext -lF77 -lI77
  576.   #endif
  577.   
  578. + #define XLibDir  /usr/local/x11r4/lib.s300
  579. + #define XIncludes -I/usr/local/x11r4
  580.   /*
  581. + #define XLibDir  /usr/lib/X11R5
  582. + #define XIncludes -I/usr/include/X11R5
  583. + */
  584. + /*
  585.    * The Shared libaries for HP may not be complete.  We do not
  586.    * have an HP. This Lib/hpLib.rules is a guess at how hp
  587.    * shared libs should be made. Please mail and changes
  588. ***************
  589. *** 108,114 ****
  590.    * update for the next version. 
  591.    */
  592.   
  593. ! #define HasSharedLibraries NO
  594.   
  595.   #if HasSharedLibraries
  596.   #  define SharedLibRev 1.1                /* Use Khoros revision number */
  597. - --- 116,122 ----
  598.    * update for the next version. 
  599.    */
  600.   
  601. ! #define HasSharedLibraries YES
  602.   
  603.   #if HasSharedLibraries
  604.   #  define SharedLibRev 1.1                /* Use Khoros revision number */
  605. *** Lib/hpLib.rules.or    Mon Apr  6 13:38:05 1992
  606. - --- Lib/hpLib.rules    Mon Apr  6 13:38:05 1992
  607. ***************
  608. *** 73,81 ****
  609.                                       @@\
  610.   .f.o:                                    @@\
  611.       $(RM) $@ shared/$@                        @@\
  612. !     $(FC) -c $(SHAREDCODEDEF) $(SHLIBDEF) $(FLIBFLAGS) $*.f        @@\
  613.       $(MV) $*.o shared/$*.o                        @@\
  614. !     $(FC) -c $(SHLIBDEF) $(FLIBFLAGS) $*.f                @@\
  615.                                                                         @@\
  616.   clean::                                @@\
  617.       -@if [ -d shared ]; then echo " $(RM) shared/?*.o"; \        @@\
  618. - --- 73,81 ----
  619.                                       @@\
  620.   .f.o:                                    @@\
  621.       $(RM) $@ shared/$@                        @@\
  622. !     $(FC) -c $(FLIBFLAGS) $*.f                    @@\
  623.       $(MV) $*.o shared/$*.o                        @@\
  624. !     $(FC) -c $(FLIBFLAGS) $*.f                    @@\
  625.                                                                         @@\
  626.   clean::                                @@\
  627.       -@if [ -d shared ]; then echo " $(RM) shared/?*.o"; \        @@\
  628.  
  629.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  630.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  631.  
  632.    Q6.  I want to install Khoros on a Convex,  under ConvexOS x.x
  633.         {and am getting error messages from the C compiler} {and 
  634.         would like more info} {has anybody done this} {are binaries available}?.
  635.  
  636.    A6.  (answer thanks to Tait Cyrus, CONVEX Computer Corp., Colorado 
  637.      Springs, CO, cyrus@convex.com) 
  638.  
  639.     Binaries for the Convex are not available;  however, building
  640.         Khoros 1.0 P5 on the Convex is quite easy.  The following is a 
  641.     convex.cf file which may be used for compiling Khoros under 
  642.     ConvexOS 9.1.
  643.  
  644. /*
  645.  * convex.cf - Provided by W. Tait Cyrus (cyrus@convex.com) April. 22, 1992
  646.  * This is a configuration file for a Convex.
  647.  * Thanks to Minaz Punjani <cziup09@pluto.ulcc.ac.uk> for verifying under
  648.  *      ConvexOS 10.0.
  649.  *
  650.  * Khoros has been successfully compiled using the following:
  651.  *      ConvexOS        9.1 & 10.0
  652.  *      C               4.1, 4.3.1, and 4.3.2
  653.  *      Fortran         6.1 & 7.0 [see note below]
  654.  *      CXWindows       2.1 & 3.0
  655.  *
  656.  * SET VERSION NUMBERS BEFORE MAKING MAKEFILES
  657.  */
  658.  
  659. /*
  660.  * Set the major version number of the Fortran compiler you will be using
  661.  * in the following #define.
  662.  */
  663.  
  664. #define Convex_fc_MajorVersion 7
  665.  
  666. #if Convex_fc_MajorVersion >= 7
  667. #   define Convex_fc_lib        -llfs
  668. #else
  669. #   define Convex_fc_lib
  670. #endif
  671.  
  672. #define OSName                  ConvexOS V9.1
  673. #define OSMajorVersion          9
  674. #define OSMinorVersion          1 
  675. /*
  676.  * Uncommenting for a ConvexOS 10.0 system is not really necessary since 
  677.  * nowhere in Khoros is a check of OSMajorVersion made for 10.  The only check
  678.  * is the one below and it just checks against 8.
  679.  *
  680.  * #define OSName               ConvexOS V10.0
  681.  * #define OSMajorVersion       10
  682.  * #define OSMinorVersion       0 
  683.  */
  684.  
  685. /*
  686.  * does your machine support saber C
  687.  */
  688. #define HasSaberC               NO      /* for machines that have it */
  689.  
  690. /*
  691.  * Do you want to Compile the tiff library and tiff2viff/viff2tiff
  692.  * conversion routines? If set to NO, then the tiff library will
  693.  * not be compiled and thus no programs will link against that
  694.  * library.
  695.  */
  696.  
  697. #define UseTiff YES
  698.  
  699.  
  700. /*
  701.  * are you using gcc? if yes then set HasGcc to YES
  702.  */
  703. #define HasGcc                  NO
  704.  
  705. #define SystemV                 NO
  706. #define HasVoidSignalReturn     YES
  707. #define StandardDefines         -DXAW_BC
  708. #define VersionNumber           2.0
  709. #define HasFortran              YES
  710. #define FortranCmd              /usr/convex/fc
  711. #define HasPutenv               NO
  712. #define HasBsearch              YES
  713. #define HasVFork                YES
  714. #define HasTempnam              NO
  715. #define HasBsdTypes             YES
  716. #define HasRandom               YES
  717. #define HasDirent               NO
  718. #define HasWait3                NO
  719.  
  720. #if OSMajorVerson == 8
  721.  
  722. #   define OptimizedCDebugFlags -O3
  723. #   define InstScriptFlags      -m 0755 -g bin
  724. #   define InstManFlags         -m 0444 -g bin
  725. #   define BootstrapCFlags      -Dconvex -pcc
  726.  
  727. #   define DefaultCCOptions     -O3 -pcc
  728. #   define FortranDebugFlags    -O3
  729.  
  730. #   define ForSysLibs -lF77 -lI77 -lD77 -lmathC2 
  731.  
  732. #else  /* assuming OSMajorVersion > 8 */
  733.  
  734. #   define OptimizedCDebugFlags
  735. #   define InstScriptFlags      -m 0755 
  736. #   define InstManFlags         -m 0444
  737. #   define BootstrapCFlags      -Dconvex
  738. #   define DefaultCCOptions     -O3 -or none -fi
  739. #   define FortranFlags         -O3 -fi -or none
  740. #   define LibraryFCOptions     -O3 -fi -or none
  741. #   define ForSysLibs -lF77 -lI77 -lD77 -lmathC2 Convex_fc_lib
  742.  
  743. #endif
  744.  
  745. #define ReDefFortran NO
  746. #define UNCOMPRESSPATH /usr/local/bin/uncompress
  747. #define UseCCMakeDepend YES
  748. #define LibraryFDebugFlags -pp=fcpp1 -uo -is .
  749.  
  750. /* 
  751.  * the following is a list of data transports available for
  752.  * use within Khoros:
  753.  *      UseFile            - Standard file system transport
  754.  *      UseSockets         - bsd Sockets
  755.  *      UseSharedMem       - shared memory
  756.  *      UseSunVirMem       - sun virtual memory
  757.  *      UsePipes           - Pipes
  758.  *      UseStream          - Named pipes
  759.  *      UseSunRPC          - Sun's remote procedure call
  760.  *      UseKTLI            - sysV transport layer interface
  761.  *      UseApolloRPC       - Apollo's remote procedure call
  762.  *
  763.  * Set the data transports that you want to use to YES and
  764.  * all others to NO. normally, you should not have to
  765.  * modify this list.
  766.  * 
  767.  */
  768.  
  769. #define UseFile         YES
  770. #define UseSockets      NO
  771. #define UseSharedMem    NO
  772. #define UseSunVirMem    NO
  773. #define UsePipes        NO
  774. #define UseStream       NO
  775. #define UseSunRPC       NO
  776. #define UseKTLI         NO
  777. #define UseApolloRPC    NO
  778.  
  779. #define NormalFortranObjectRule()                                       @@\
  780. all::                                                                   @@\
  781.         $(FC) -il $(FSRCS)                                              @@\
  782.                                                                         @@\
  783. .f.o:                                                                   @@\
  784.         $(RM) $@                                                        @@\
  785.         $(FC) -c $(FLIBFLAGS) $*.f                                      @@\
  786.                                                                         @@\
  787. clean::                                                                 @@\
  788.         $(RM) *.fil
  789.  
  790.  
  791.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  792.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  793.  
  794.    Q7.  Can I run Khoros on my PC? Is Khoros available for PC's running DOS?
  795.  
  796.    A7a. The three major requirements for Khoros are: X11R4, a UNIX-type
  797.         operating system, and lots of space (min. 120-150 Meg).  Only if your
  798.         PC has these three prerequisites can you consider doing a port of
  799.         Khoros to your PC.  Successful ports of Khoros have been done for
  800.         the Mac II and various 386/486 machines that meet these requirements.    
  801.     Please see Q4 for more details on ports to the 386/486.
  802.  
  803.    A7b.    No, nor are there plans to make Khoros available for PC's
  804.     running DOS as of yet.  The design changes necessary for
  805.     completing such a task would be so extensive as to make the
  806.     attempt unworkable at this time.
  807.  
  808.  
  809.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  810.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  811.  
  812.    Q8.  Is there a port of Khoros for a VMS system?
  813.  
  814.    A8.  No.  The software depends heavily on system functions that are
  815.         unique to Unix-based operating systems.
  816.  
  817.  
  818.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  819.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  820.  
  821. ================  Compile With Shared Libraries ===============================
  822.  
  823.    Q9.  What are shared libraries?  Does Khoros work with shared libraries?
  824.         What are the advantages/disadvantages of using shared libraries?
  825.     Should I compile Khoros with shared libraries?
  826.  
  827.    A9a. Shared libraries are a mechanism implemented by some operating 
  828.     systems (SUN, HP, DG Aviion, etc)  that allow a significant savings
  829.     of disk space by allowing programs to link against any necessary
  830.     libraries at runtime rather than at compile time.  Since the libraries
  831.     are not compiled into the program's executable, each program that
  832.     is compiled with shared libraries takes up much less space. 
  833.  
  834.    A9b. Yes. You can compile Khoros with/for shared libraries.
  835.         If you are compiling shared, make sure that your machine.cf
  836.         configuration file has the symbol HasSharedLibraries set to YES.
  837.  
  838.    A9c. The advantage, of course, is savings on disk space.  The disadvantage
  839.         is that because libraries must be linked in at runtime, you will
  840.     experience a lag in startup time of programs.  The disk space savings,
  841.     like amount of the extra time at startup, will vary with machine 
  842.     architecture, operating system implementation, and other factors.
  843.  
  844.    A9d. That depends on your position with respect to the tradeoffs.  
  845.     If you are short on disk space, using shared libraries may be the 
  846.     answer to your problems.  If you have plenty of disk space to waste, 
  847.     you may want to go ahead and compile statically so that programs 
  848.     run faster.  
  849.  
  850.     Some excerpts of mail from Khoros users who have reported disk savings 
  851.     due to shared libraries follow (thanks, guys, for the info):
  852.  
  853.     "I've just brought Khoros up with shared libraries under
  854.      DG/UX 5.4 (DG AViiON).  However, the size savings seems quite
  855.      a bit less than I was expecting...Anyway, there is a net disk 
  856.      savings of 22.2MB, some 27MB (from 86MB to 59MB) in bin and about
  857.      4.7MB in lib).        -- Steve"  
  858.  
  859.     "I don't know about the savings, but do know the sizes with SUN
  860.      shared libs.  (patchlevel 5) Bin: 24Mb Lib: 9.2Mb, with 3.7Mb shared 
  861.      libs.  I recall needing approx. 80-90 Mb for bin without shared libs 
  862.      (for patch level 2).   -- Klamer"
  863.  
  864.     "I got 7 MB of libraries and about 20 MB of executables on a 
  865.      SPARCstation running {shared libs}. I would have to expect 63 MB of 
  866.      executables + 21 MB of librares and objects when not using shared 
  867.      code - it saved about 40 - 50 MB...  -- Kritt"
  868.  
  869.     "Here are my numbers for khoros patch 5: bin 9.3 MB, lib 9.1 MB
  870.      The lib contains BOTH shared and archive libs. Thus, making khoros 
  871.      shared gives 9.3 MB bins + 4.5 MB libs = 13.8 MB...  Not long ago I 
  872.      had an unstrip'ed code of patch 4 that took (read my lips) 165 MB!!   
  873.      -- Peder"
  874.  
  875.  
  876.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  877.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  878.  
  879.    Q10. Why do I get unresolved references when I compile Khoros with
  880.         shared libraries on a SUN4?
  881.  
  882.    A10. If you are compiling on a SUN4 under 4.1.1 and have installed
  883.         the loader (ld) program patch, or you are compiling on a SUN4
  884.         under 4.1.2 you must compile Khoros statically. Make sure
  885.         you set HasSharedLibraries to NO in the sun.cf file.
  886.  
  887.         The ld program under 4.1.1 (with the patch) and under 4.1.2
  888.         requires that all references in the libraries be resolved. So,
  889.         this means that every Khoros routine will need to load against
  890.         all the libraries. This is not reasonable for Khoros, and the
  891.         size of the shared executables after loading against all the
  892.         libraries are not significantly smaller than if they were
  893.         loaded statically.
  894.  
  895.  
  896.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  897.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  898.  
  899.    Q11. When compiling shared, I get a large set of errors from
  900.         the loader listed in my make.World file, as in:
  901.  
  902.         rm -f vadd
  903.         cc -o vadd vadd.o  -L/home/holst/khoros/lib -L/mnt/elocal/lang/SC1.0
  904.         -O -Bdynamic -lghost  -lvexpr  -lnum_anal  -ldspl  -lformat
  905.         -lgeo_surf  -lvipl  -lvutils  -lvmath  -lvrast  -lvgparm  -lverror
  906.         -ltiff  -lm -ll -ldl
  907.         ld: Undefined symbol
  908.            _cg_
  909.            _zgedi_
  910.            _zgeco_
  911.            _zgesl_
  912.            _zsvdc_
  913.            _ch_
  914.            _dgesl_
  915.            _dgefa_
  916.            _e_wsfe
  917.            _pow_ii
  918.            _s_wsFe
  919.            _s_stop
  920.         *** Error code 2
  921.         install in ./vipl/arith_binary/vadd done
  922.         make: Warning: Target `install' not remade because of errors
  923.  
  924.    A11. This is the behavior of the loader in Sun OS 4.1.2. It
  925.         insists on resolving everything in linpack, and since that
  926.         version of linpack does not appear to be fully consistent
  927.         (i.e. those routines are reference but not defined), you get
  928.         these error messages.
  929.         To solve the problem, you may:
  930.  
  931.         * use the (pre ld patch) loader of 4.1.1.
  932.  
  933.       suggestion, to use something like:
  934.           lrwxrwxrwx  1 root            8 Jun 10 11:04 /usr/bin/ld -> ld.4.1.1
  935.           -rwxr-xr-x  1 root       156161 Mar  5 15:46 /usr/bin/ld.4.1.1*
  936.           -rwxr-xr-x  1 root       156161 Oct 23  1991 /usr/bin/ld.4.1.2*
  937.       so that you can switch between the two loaders easily.
  938.  
  939.         * add stub routines to linpack (like extern void zgeco_() {} )
  940.  
  941.         * in $KHOROS_HOME/repos/config/imake_conf/sun.cf,
  942.           change:
  943.         #  define DefaultCCOptions -Bdynamic
  944.         #  define LibraryLdOptions -assert pure-text
  945.       to:
  946.         #  define DefaultCCOptions -Bdynamic -Qoption ld -assert -Qoption ld
  947.               nodefinitions
  948.             #  define LibraryLdOptions -assert nodefinitions
  949.  
  950.  
  951.         If you are compiling on a SUN4 under 4.1.1 and have installed
  952.         the loader (ld) program patch, you must either follow the solutions 
  953.     given above, or  compile statically.
  954.  
  955.  
  956.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  957.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  958.  
  959.  
  960.    Q12. I am compiling [some xvroutine] against X11R5 with shared libraries.
  961.         The linker produces this error message:
  962.  
  963.     ld: /lib/libXaw.sa.5.0(sharedlib.o): _formWidgetClass: multiply defined
  964.             /lib/libXaw.sa.5.0(sharedlib.o): _labelWidgetClass: multiply defined
  965.         *** Error code 2
  966.         make: Fatal error: Command failed for target `{xvroutine}'
  967.  
  968.    A12. You will need to change Form.c in 
  969.         $KHOROS_HOME/src/xvroutines/Lib/xvutils.
  970.  
  971.     Try changing line 137 from:
  972.         WidgetClass formWidgetClass = (WidgetClass)&formClassRec;
  973.     to:
  974.         static WidgetClass formWidgetClass = (WidgetClass)&formClassRec;
  975.  
  976.     And, in the file Label.c in $KHOROS_HOME/src/xvroutines/Lib/xvutils,
  977.     Try changing line 140 from:
  978.         WidgetClass labelWidgetClass = (WidgetClass)&labelClassRec;
  979.     to:
  980.         static WidgetClass labelWidgetClass = (WidgetClass)&labelClassRec;
  981.  
  982.     Recompile the xvutils library, and recompile the xvroutine.
  983.  
  984.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  985.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  986.  
  987.    Q13. I am having problems using cantata (or other xvroutine)
  988.         after recently compiling on a SUN with shared libraries.  I get the
  989.         error message:
  990.      Warning: Widget class VendorShell version mismatch (recompilation needed):
  991.        widget 11004 vs. intrinsics 11003.
  992.      Warning: Widget class Form version mismatch (recompilation needed):
  993.        widget 11004 vs. intrinsics 11003.
  994.  
  995.    A13. Your LD_LIBRARY_PATH environment variable that you use to compile
  996.         your object files with is different than your run time environment.
  997.  
  998.         To get a bit of information about what is going on, do:
  999.         % ldd $KHOROS_HOME/bin/{problem program}
  1000.  
  1001.         If the path printed for Xaw and Xt is different than what is listed
  1002.         when you do:
  1003.         % printenv
  1004.         then this is the problem.  To fix it, unset LD_LIBRARY_PATH or set it
  1005.         to the correct path.
  1006.  
  1007.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  1008.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1009.  
  1010.    Q14. Warpimage {or other xvroutine} did not compile after on a SUN4 
  1011.     architecture with static libraries;  in fact, it made the cc compiler 
  1012.     segmentation fault and core dump!  What happened?
  1013.  
  1014.    A14. The problem is that the Makefile that is created for warpimage has
  1015.         a line that is too long for ld to handle.  The solution is to edit
  1016.         the Makefile and delete these three lines:
  1017.  
  1018.         $(FILEFORMATLIB) \
  1019.         $(DSPLLIB) \
  1020.         $(TIFFLIB)
  1021.  
  1022.         and change the line
  1023.         $(VERRORLIB) \
  1024.         to
  1025.         $(VERRORLIB)
  1026.  
  1027.         This causes the cc line to be of a reasonable length, and warpimage
  1028.         {or other xvroutine} will now compile properly.
  1029.  
  1030.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  1031.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1032.  
  1033.    Q15. Khoros compiled ok under shared libraries.  However, when I try to
  1034.         use the programs, I get messages that say:
  1035.  
  1036.         lib{something}.so.1 not found
  1037.  
  1038.    A15. The message implies that your LD_LIBRARY_PATH environment variable 
  1039.         that was used to compile the Khoros object files is different than 
  1040.         your run time environment.
  1041.  
  1042.         To get a bit of information about what is going on, do:
  1043.         % ldd $KHOROS_HOME/bin/{problem program}
  1044.  
  1045.         If the path printed for lib{something} is different than what is 
  1046.         listed when you do:
  1047.         % printenv
  1048.         then this is the problem.  To fix it, unset LD_LIBRARY_PATH or set 
  1049.         it to the correct path.
  1050.  
  1051.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1052.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1053.  
  1054. =====================   Compiling with X11R5  ================================
  1055.  
  1056.  
  1057.    Q16. Can I compile Khoros with X11R5?
  1058.  
  1059.    A16. Yes.  See Q12 for the most frequent problems when compiling 
  1060.     Khoros with X11R5.
  1061.  
  1062.  
  1063.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  1064.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  1065.  
  1066.    Q17. I am compiling Khoros with MIT's X11R5.  When linking xvroutines
  1067.         (cantata, editimage, etc), the compiler tells me that
  1068.         _viewportWidgetClass is multiply defined.  What's the problem?
  1069.  
  1070.    A17. This problem is due to the fact that we have our own bugged fixed
  1071.         versions of the Viewport widget.  We were hoping that R5
  1072.         would have these fixes so that we could delete them, but unfortunately
  1073.         this isn't the case.  Kim Tang provides these fixes to get around the
  1074.         problem:
  1075.  
  1076.         In $KHOROS_HOME/src/xvroutines/cantata/Viewport.c, change line 141 to:
  1077.         static WidgetClass viewportWidgetClass = (WidgetClass)&viewportClassRec;
  1078.  
  1079.  
  1080.    Q17b. ld: /lib/libXaw.sa.5.0(sharedlib.o): _formWidgetClass: multiply defined
  1081.             /lib/libXaw.sa.5.0(sharedlib.o): _labelWidgetClass: multiply defined
  1082.         *** Error code 2
  1083.         make: Fatal error: Command failed for target `{xvroutine}'
  1084.  
  1085.    A17b. see Q13.
  1086.  
  1087.  
  1088.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  1089.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  1090.  
  1091.  
  1092. ===========  Makefiles, Imakefiles (Compiling New Programs) ===================
  1093.  
  1094.    Q18. I don't want to compile Khoros source, but I want to compile
  1095.         my own programs so I need the libraries. How can I obtain the
  1096.         Khoros libraries?
  1097.  
  1098.    A18. We distribute libraries for the SUN4, Decmips, and SGI via
  1099.         anonymous FTP:
  1100.   
  1101.            USA:                 ftp pprg.eece.unm.edu  (129.24.24.10)
  1102.         (University of  Login:  anonymous  (or ftp)
  1103.             New Mexico) Password: user_name@machine
  1104.   
  1105.         To obtain the libraries, cd to "pub/khoros/bin". You will find
  1106.         three sub-directories called libsun4, libdecmips and libsgi.
  1107.         In these sub-directories are the compressed tar files containing
  1108.         the libraries. Unpack the libraries the same way you would
  1109.         unpack the binaries. Consult the Khoros installation guide.
  1110.  
  1111.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1112.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1113.  
  1114.     Q19. I am trying to compile an xvroutine, and when I run make install
  1115.          I get the error:
  1116.          installing in ./{xvroutine}...
  1117.          Make:  Don't know how to make {KHOROS_HOME}/lib/libdisplay.a.
  1118.          Stop.
  1119.          *** Error code 1
  1120.  
  1121.     A19. Most likely, you do not have the Khoros libraries that are necessary
  1122.          to compile spectrum (and any other toolbox you may acquire).
  1123.          These libraries (*.a) would be located in $KHOROS_HOME/lib if you
  1124.          had them.  If you do not have them, you may either:
  1125.          (1) ftp them from pprg  (see Q11)
  1126.          - or -
  1127.          (2) compile the Khoros system (you must have source code for this)
  1128.  
  1129.  
  1130.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1131.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1132.  
  1133.     Q20. I want to link a {vroutine/xvroutine} for dbx.
  1134.  
  1135.     A20. In your Imakefile, add:
  1136.          CDEBUGFLAGS = -g
  1137.  
  1138.      % makemake
  1139.  
  1140.          To remake your Makefile.
  1141.  
  1142.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1143.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1144.  
  1145.     Q21. I want my {vroutine/xvroutine} to use some specific 
  1146.          include files and special libraries.
  1147.  
  1148.     A21. Suppose you have additional include files you want (relative to the
  1149.          program) in "../../include" and an extra library you want to use in
  1150.          "../../lib/libfubar.a."
  1151.  
  1152.          So in your Imakefile, you'd add:
  1153.  
  1154.          EXTRA_INCLUDES =  -I../../include
  1155.          EXTRA_LIBRARIES = ../../lib/libfubar.a
  1156.  
  1157.      % makemake 
  1158.  
  1159.      To remake your Makefile.  You can also use the absolute path, but 
  1160.      this is not a good idea if you have your program on more than one 
  1161.          architectures using NFS, as all the architectures will use the same 
  1162.      Imakefile, but the absolute path on one machine may not be the same 
  1163.          as the absolute path on the second.
  1164.  
  1165.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1166.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1167.  
  1168.    Q22.  Is there a way to get ghostwriter to automatically generate 
  1169.      the Makefile so that it will look for other include directories 
  1170.          and libraries?
  1171.  
  1172.    A22.  (answer thanks to Bradford Castallia, Planetary Image Research Lab,
  1173.           University of Arizona)
  1174.  
  1175.          You can specify site-specific libraries that should always be 
  1176.          referenced.
  1177.  
  1178.       However, for specific cases, modify the {toolbox}.def file (under
  1179.       $TOOLBOX/repos/config/imake_conf). Edit the lines containing the
  1180.       definitions of TOOLBOXINCLUDE and TOOLBOX_LIBRARIES, and you may also
  1181.       want to edit the line defining TOOLBOX_DEP_LIBRARIES to be consistent
  1182.       with the definition of TOOLBOX_LIBRARIES. For example, I have a
  1183.       toolbox for applications that access our digital filmwriter which
  1184.       requires access to a few special include files and libraries, so I have
  1185.       modified filmwriter.def thus:
  1186.       
  1187.       TOOLBOXINCLUDE = -I$(TB_NAME)/include \
  1188.                        -I/usr/local/QCR/include \
  1189.                        -I/usr/local/image/include \
  1190.                         -I/usr/local/PIRL
  1191.       
  1192.       TOOLBOX_LIBRARIES = -lfilmwriter \
  1193.                           -lQCR \
  1194.                           -lImage \
  1195.                           -lPIRL
  1196.      
  1197.          TOOLBOX_DEP_LIBRARIES = $(LIBDIR)/libfilmwriter.a \
  1198.                                /usr/local/lib/libQCR.a \
  1199.                                /usr/local/lib/libImage.a \
  1200.                                /usr/local/lib/libPIRL.a
  1201.       
  1202.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1203.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1204.  
  1205. ===================  Compiling with gcc ======================================
  1206.  
  1207.  
  1208.    Q23.  I'm having a problem with gcc:
  1209.  
  1210.       % gcc test.c -I/usr/local/include -I$KHOROS_HOME/include
  1211.  
  1212.      In file included from {KHOROS_HOME}/include/vinclude.h:128, 
  1213.      from test.c:3: 
  1214.      {KHOROS_HOME}/include/vdefines.h:219: conflicting types for `malloc' 
  1215.          /usr/local/{...}/include/malloc.h:41: previous declaration of `malloc'
  1216.          {KHOROS_HOME}/include/vdefines.h:223: conflicting types for `calloc'
  1217.          /usr/local/{...}/include/malloc.h:39: previous declaration of `calloc'
  1218.  
  1219.    A23.  In the file $KHOROS_HOME/include/vdefines.h,
  1220.      change the line:
  1221.  
  1222.      #ifndef AUX
  1223.      to:
  1224.       #if !defined(AUX) && !defined(__GNUC__)
  1225.  
  1226.      Then, in $KHOROS_HOME/src, execute 
  1227.      % make Makefiles
  1228.      % make install
  1229.  
  1230.  
  1231.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1232.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1233.  
  1234.    Q24. I noticed in the make.World file is that a few files are compiled 
  1235.         using 'cc', while some others are compilied using 'gcc'. Is this normal? 
  1236.         Also, there were messages like: 
  1237.         gcc: file path prefix `dynamic' never used
  1238.  
  1239.    A24. The -Bdynamic flag does not exist for gcc. Use -static for a static
  1240.         binary compile, as the default is to load dynamically. The -Bdynamic 
  1241.         flag was ignored and not used.
  1242.  
  1243.     It is normal that some files will be compiled with cc.  We use cc to 
  1244.         compile the bootstrap programs such as imake. However, gcc should have
  1245.         been used for all the rest of the routines.
  1246.  
  1247.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1248.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1249.  
  1250. ===================  Compiling With/Without FORTRAN ==========================
  1251.  
  1252.    Q25. Do I HAVE to have FORTRAN to compile Khoros?  Which Khoros programs
  1253.         will I miss out on if I don't compile with FORTRAN?
  1254.  
  1255.    A25. No, you don't have to have FORTRAN to compile Khoros, although there
  1256.         are some Khoros programs that use it.  If you don't compile with
  1257.         FORTRAN, you will NOT be able to run the following programs, nor will
  1258.     you be able to make calls to any of their associated library routines:  
  1259.  
  1260.     Program         Library Call
  1261.         -------         ------------
  1262.     * warpimage
  1263.     * vbilinco     (lvbilinco)
  1264.     * vpolyco    (lvpolyco)
  1265.     * vsvpsf    (lvsvpsf)
  1266.     * vblse        (lvblse)
  1267.     * vfft        (lvfft)
  1268.     * dmusic    (ldmusic)
  1269.     * dminorm    (ldminorm)
  1270.     * dacorr    (ldacorr)
  1271.     * dxcorr    (ldxcorr)
  1272.     * dconvo    (ldconvo)
  1273.     * dfft1d    (ldfft1d)
  1274.     * difft1d    (ldifft1d)
  1275.     * minvert    (lminvert)
  1276.     * msvd        (lmsvd)
  1277.     * meigen    (lmeigen)
  1278.     * mlud        (lmlud)
  1279.     * mlse        (lmlse)
  1280.     * minfo        (lminfo)
  1281.  
  1282.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1283.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1284.  
  1285.    Q26. How do I compile the Khoros system without FORTRAN?
  1286.  
  1287.    A26. Look for the line in your configuration (*.cf) file that says,
  1288.         #define HasFortran YES
  1289.         Change it to:
  1290.         #define HasFortran NO
  1291.  
  1292.         For those compiling on a SUN architecture, note that in the sun.cf 
  1293.     file for Khoros 1.0 Patch 5, there is an INCORRECT comment:
  1294.         /*
  1295.          * does your machine have fortran? If not comment the next
  1296.          * two lines
  1297.          */
  1298.     The comment lies.  Do not comment out the lines, simply make
  1299.     sure that HasFortran is set to 'NO' (not 'no' or 'No').  
  1300.  
  1301.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1302.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1303.  
  1304.    Q27. I don't have a FORTRAN compiler, but I need the Khoros programs that
  1305.         use FORTRAN.  What can I do?
  1306.  
  1307.    A27. The public domain "f2c" FORTRAN-to-C converter can be used to produce
  1308.         C code from the FORTRAN sections of Khoros.  The "f2c" program can
  1309.         be obtained via anonymous ftp from various sites including 
  1310.     pprg.eece.unm.edu (129.24.24.10) in the directory, /pub/dist/f2c, and
  1311.     research.att.com (192.20.225.2) in the directory, /netlib.  
  1312.     Khoros programs that depend on FORTRAN code that was converted to 
  1313.     C by the f2c program dont't have their results guaranteed by the Khoros 
  1314.     group, however, at least not at this time.
  1315.  
  1316.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1317.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1318.  
  1319.    Q28. I am writing a {vroutine/xvroutine} in which I need to make a call
  1320.         from my C code to a FORTRAN subroutine/function.  How do I do this?
  1321.  
  1322.    A28. (1) Declare the FORTRAN subroutine/function, making sure you use an 
  1323.             underscore after the name, as in:
  1324.             (void) subroutine_();
  1325.             (type) function_();
  1326.  
  1327.     (2) Call the subroutine/function, remembering that when you call FORTRAN 
  1328.         from C, you must always pass values by reference (address), as in:
  1329.             int int_value, *int_array;
  1330.         (void) subroutine_(&int_value, int_array);
  1331.  
  1332.     (3) Note that 2D arrays in FORTRAN are stored in the opposite way 
  1333.         from those in C.  In C, a 2D array is stored as row by row, 
  1334.         whereas in FORTRAN a 2D array is stored column by column.  
  1335.  
  1336.     (4) Also note that the TRUE and FALSE status values returned by 
  1337.         a FORTRAN program may not be the 1 and 0 that are used by 
  1338.         convention in C.
  1339.  
  1340.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1341.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1342.  
  1343.    Q29.  I am setting up my *.cf configuration file in preparation for compiling
  1344.          Khoros.  How do I find out what libraries the linker expects in order
  1345.          to link C code against FORTRAN, in order to provide the proper
  1346.          libraries for the ForSysLibs option?
  1347.  
  1348.    A29.  You can find out what libraries the linker expects by compiling any
  1349.          available Fortran program with the [-v] option, and looking for the
  1350.          libraries specified after a [-l] that are NOT used when compiling
  1351.          C code.  Roque Donizete De Oliveria provides the example below, which
  1352.          he used in getting Khoros to compile under Ultrix 4.2:
  1353.  
  1354.         % f77 -v machar.F
  1355.         /lib/cpp -DLANGUAGE_FORTRAN -DMIPSEL -Dunix -Dmips -Dhost_mips 
  1356.            machar.F > machar.i
  1357.         /usr/lib/cmplrs/fort/decfort -o /tmp/forAAAa01710.o machar.i
  1358.         /usr/bin/cc -v /tmp/forAAAa01710.o -nocount -lUfor -lfor -lutil 
  1359.        -li -lot s -lm
  1360.         /usr/lib/cmplrs/cc/ld -G 8 -g0 -nocount /usr/lib/cmplrs/cc/crt0.o 
  1361.        -count /tmp/forAAAa01710.o -nocount -lUfor -lfor -lutil -li 
  1362.            -lots -lm -nocount -lc
  1363.         0.2u 1.7s 0:09 21% 84+285k 333+63io 17pf+0w
  1364.  
  1365.          In this case, therefore, you would specify in the ultrix.cf file:
  1366.  
  1367.          ForSysLibs: -lUfor -lfor -lutil -li -lots
  1368.  
  1369.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1370.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1371.  
  1372. ===================  Miscellaneous ============================================
  1373.  
  1374.     Q30. I seem to be having some trouble getting Khoros working on our Sun 3. 
  1375.          I have tried executing {cantata, editimage, etc}  {journal playbacks}, 
  1376.      but I keep getting the error "ld.so: libXaw.so.4: not found".
  1377.  
  1378.     A30. (answer thanks to Mike Gross, Physics Board, Univ of California)
  1379.  
  1380.      Your problem is that you have to run ldconfig to tell your system where
  1381.      your shared libraries are. The syntax is:
  1382.  
  1383.      ldconfig <directory> [<directory>] [<directory>] ...
  1384.  
  1385.      where each directory is a possible location for a *.so.* file. You
  1386.      may have to use find to figure out where all the libraries are. Try
  1387.      this out, and if it works, put the ldconfig command in /etc/rc.local,
  1388.      so that you won't lose it next time your system crashes.
  1389.  
  1390.      An alternative is to compile khoros using static libraries, but this
  1391.      will make your executables much larger.
  1392.  
  1393.  
  1394.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1395.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1396.  
  1397.     Q31.  Since the docs say that RPC isn't implemented yet, I defined 
  1398.       UseSunRPC as NO.  Compiling phantomd results in the following:
  1399.       ld: Undefined
  1400.       _sunrpc_tempnam
  1401.       _sunrpc_gethostname
  1402.  
  1403.     A31.  Suggestions:
  1404.  
  1405.       1) make sure that the SunRPC variable in 
  1406.              repos/config/imake_conf/sun.cf is set to 'NO' rather than 'no'.
  1407.  
  1408.           2) cd into src and run the "installit" script again.
  1409.                         - or -
  1410.       2) cd into src/Lib/vgparm and run:
  1411.  
  1412.             % make Makefile
  1413.             % make install
  1414.  
  1415.             You should see it recompile with a set of defines specified on 
  1416.             the compilation command.  Make sure that -DKSUNRPC option is *not*
  1417.             defined.  This is what's trying to pull in the non-existent
  1418.             Sun RPC transport.
  1419.  
  1420.          3) If you are not using shared libraries, then change directories 
  1421.             to $KHOROS_HOME/src and run:
  1422.             % make install
  1423.  
  1424.         If you are using shared libraries, simply rerunning the phantomd
  1425.         should work.
  1426.  
  1427.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1428.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1429.  
  1430.      Q32. On Sun3, OS 4.1.1, a segmentation fault results when cantata is run.
  1431.  
  1432.      The problem is that the bug is caused in the vgparm and vutils 
  1433.      library, not in the cantata program code.  
  1434.  
  1435.      In the file $KHOROS_HOME/src/Lib/vgparm/listfile.c there is a bug.
  1436.      Make the following changes to this file
  1437.     
  1438.      at line 100 change:
  1439.  
  1440.             char    character, *fullpath, entry[LENGTH], **list;
  1441.      to:
  1442.             char    character[2], *fullpath, entry[LENGTH], **list;
  1443.  
  1444.  
  1445.          and line 144 change:
  1446.  
  1447.            if ((void) fscanf(file, " %[#]", &character) == 1)
  1448.          to:
  1449.            if ((void) fscanf(file, " %[#]", character) == 1)
  1450.  
  1451.  
  1452.          and line 157 change:
  1453.  
  1454.            else if ((void)fscanf(file, "%[/]%[*]", &character, &character) == 2)
  1455.          to:
  1456.            else if ((void) fscanf(file, "%[/]%[*]", character, character) == 2)
  1457.  
  1458.  
  1459.          Then in the file $KHOROS_HOME/src/Lib/vutils/readascii.c some
  1460.      changes need to be made.
  1461.     
  1462.      at line 99 change:
  1463.  
  1464.            char    dummy[512], character;
  1465.          to:
  1466.            char    dummy[512], character[2];
  1467.  
  1468.  
  1469.          and line 128 change:
  1470.            if ((void) fscanf(file, "%[#]", &character) == 1)
  1471.          to:
  1472.            if ((void) fscanf(file, "%[#]", character) == 1)
  1473.  
  1474.  
  1475.          and line 139 change:
  1476.            else if ((void)fscanf(file, "%[/]%[*]", &character, &character) == 2)
  1477.          to:
  1478.            else if ((void)fscanf(file, "%[/]%[*]", character, character) == 2)
  1479.  
  1480.  
  1481.          there also seems to be a problem caused by the optimizer
  1482.          using -O on sun3.  It is necessary to recompile the system using -01
  1483.          which is defined as follows in your sun.cf file:
  1484.  
  1485.           #define HaveSunPatchedLd NO
  1486.           #define HasGcc NO
  1487.           #define DefaultCDebugFlags -O1          /* for programs */
  1488.           #define LibraryCDebugFlags -O1          /* for libraries */
  1489.  
  1490.          Note that a comment in sun.cf has a typing error.  The correct
  1491.          flag is -O1 (minus oh one) and not -01 (minus zero one).  
  1492.  
  1493.          Then change directory to $KHOROS_HOME/src, run "make allclean"
  1494.          and then the "installit".
  1495.  
  1496.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1497.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1498.  
  1499.    Q33.  During the compile of Khoros, I get this error message:
  1500.          /: write failed, file system is full
  1501.          compiler(iropt) error:  write_irfile: No space left on device
  1502.  
  1503.    A33.  This error is becuase you have run out of disk space in /tmp. 
  1504.          By default the C compilier uses /tmp as the place to store 
  1505.          intermediate files. To fix this, set the environment variable 
  1506.      TMPDIR to a partition with more disk space, as in:
  1507.      % setenv TMPDIR /large_tmp_dir
  1508.  
  1509.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1510.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1511.  
  1512.    Q34. I am trying to compile a {toolbox, new program, etc}, but "make"
  1513.     keeps giving me error messages that say:
  1514.  
  1515.     make: Fatal error: 
  1516.     Don't know how to make target `{KHOROS_HOME}/lib/lib{something}.a
  1517.  
  1518.    A34. It is likely that you simply don't have the Khoros libraries installed 
  1519.     on your system.  Look and see if there is a {KHOROS_HOME}/lib 
  1520.     directory, which contains a large variety of files ending in ".a".
  1521.     If this directory is missing, whoever installed Khoros probably got 
  1522.     just system & binaries.  If you want to compile anything, though, 
  1523.     you must have the Khoros libraries installed properly in 
  1524.     $KHOROS_HOME/lib.  You may obtain the Khoros libraries in one of 
  1525.     two ways:
  1526.  
  1527.        (1) for SUN4, SGI, DECMIPS, and 486 architectures, the libraries can
  1528.                be ftp'd from pprg.eece.unm.edu, in /pub/khoros/bin.  Put 
  1529.                the *.a's in $KHOROS_HOME/lib, and you will be able to compile.
  1530.  
  1531.        (2) you may acquire Khoros source code from pprg.eece.unm.edu, in
  1532.            /pub/khoros/src, and compile the Khoros system according to the
  1533.            installation guide.  The Khoros libraries will be compiled as
  1534.            part of the entire Khoros installation process.
  1535.  
  1536.  
  1537.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1538.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1539.  
  1540.    Q35. Where in the Khoros Manual is the documentation relating to 
  1541.     compilation/installation of programs in Khoros?
  1542.  
  1543.    A35. The installation guide for the Khoros system as a whole is  
  1544.         available via anonymous ftp from pprg.eece.unm.edu, in the 
  1545.     file /pub/khoros/release/install.ftp.  This is also Chapter 10
  1546.     of the Khoros Programmer's Manual.
  1547.  
  1548.     For becoming familiar with the source configuration of Khoros,
  1549.         the imake system, the tools available for compiling Khoros programs,
  1550.     adding new routines to existing libraries, creating new libraries,
  1551.     creating new programs, and maintaining Khoros on multiple architectures,
  1552.     you want Chapter 9 of the Khoros Programmer's Manual.
  1553.  
  1554.     Either of these chapters may be printed using the "prnmanual" program.
  1555.  
  1556.  
  1557.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1558.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1559.  
  1560.    Q36. How does one selectively fix a program and recompile it without doing
  1561.         the whole installation process again?
  1562.  
  1563.    A36. The process will differ if the fix is to a library on which the 
  1564.     program depends, or to the program itself.
  1565.  
  1566.     Case 1: Fix is to a library on which the program depends.
  1567.  
  1568.     a1) In the case that the fix involves adding a new file to the 
  1569.             library, copy the new file to the library.  Then execute "imkmf",
  1570.         followed by "make Makefile".
  1571.  
  1572.         a2) In the case that the fix involves over-writing an old file with a 
  1573.             new, bug-fixed file, it is generally wise to make a backup copy
  1574.             of the old file before you over-write it.  
  1575.  
  1576.      b) Now, execute, "make depend", followed by "make install".  
  1577.         This recompiles the library.
  1578.  
  1579.      c) Finally, you must recompile the program(s) which depend on the
  1580.             library.  
  1581.  
  1582.         In some cases, there will be only one program that is affected.  
  1583.         For example, if the fix was in the IPL library, the DSPL library,
  1584.         or the File Formats library, it is likely that the fix will only 
  1585.         affect one program.  Find the directory in which the program is
  1586.         located, and recompile it using, "make install".
  1587.  
  1588.         In the case of the xvdisplay, xvforms, xvgraphics, and xvutils
  1589.         libraries,  all xvroutines will be affected.  
  1590.         Go to $KHOROS_HOME/src/xvroutines and execute, "make install".
  1591.  
  1592.         In other cases, the fix to the library may affect every program in
  1593.         the Khoros system.  This will be the case with fixes to the 
  1594.         verror, vexpr, vgparm, vmath, vrast, and vutils libraries.  
  1595.         After making a fix to one of these libraries, it is best to go to 
  1596.         $KHOROS_HOME/src, and do "installit" again.
  1597.  
  1598.  
  1599.     Case 2: the fix is to the program itself
  1600.  
  1601.     In this case, simply find the program in the KHOROS_HOME source tree.
  1602.  
  1603.     a1) In the case that the fix involves adding a new file to the 
  1604.             program, copy the new file to the program directory.  
  1605.         Then execute "imkmf", followed by "make Makefile".
  1606.  
  1607.         a2) In the case that the fix involves over-writing an old file with a 
  1608.             new, bug-fixed file, it is generally wise to make a backup copy
  1609.             of the old file before you over-write it.  
  1610.  
  1611.      a) Now, execute, "make depend", followed by "make install".  
  1612.         This recompiles and installs the program.
  1613.  
  1614.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1615.     ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~~ ~ ~ ~ ~ ~
  1616.  
  1617.    Q37. When I try to compile dzresp, dfilter, mat2viff, etc., I get 
  1618.         unresolved symbols for _dspl_parse, _format_parse, and _vexpr_parse.
  1619.         Where do I find these routines?
  1620.  
  1621.    A37. The problem you are experiencing is the result of using GNU's version
  1622.         of the program 'sed'.  What you need to do is change your path so
  1623.         that /bin/sed or /usr/bin/sed are used and then do the following:
  1624.  
  1625.         cd $KHOROS_HOME/src/Lib/vexpr
  1626.         make clean
  1627.         cd $KHOROS_HOME/src/dspl/Lib
  1628.         make clean
  1629.         cd $KHOROS_HOME/src/file_formats/Lib
  1630.         make clean
  1631.         cd $KHOROS_HOME/src
  1632.         make install
  1633.  
  1634.  
  1635.  
  1636.  
  1637.