Newsgroups: comp.soft-sys.khoros

In comp.soft-sys.khoros, justin@hp750.ccs.uky.edu (Justin Sullivan) writes:

> Surprise! I can ALMOST compile Khoros, but I have a problem.. It could
> be a minor configuration problem, but everything in the configuration
> is so convoluted, I don't know where to begin.. 
> The configuration is an HP 9000/750 running HP-UX 8.07. I have followed
> the special instructions in the Khoros FAQ for installing on an HP to
> the letter. 
> 
> Everything goes along JUST FINE until it gets to here:
> 
> install in ./vipl/Lib done
> installing in ./vipl/arith_binary...
> installing in ./vipl/arith_binary/vabsdiff...
> 	cc +O1   -I/usr/local/khoros/include  -I/usr/include/X11R4  -s -Wp,-H512000 -DSYSV -DVFORK      -DREDEFFORTRAN -DWAIT3      -c vabsdiff.c
> Directory/: Make: Cannot open.  Stop.
> installing in ./vipl/arith_binary/vadd...

You mention following the instructions, but the -I/usr/include/X11R4
worries me :-)
HP does not ship the Athena widgets, and if you put your own
in /usr/include/X11R4 you may be in trouble, since you are mixing
HP's include files with. However, this has nothing to do with your
problem which looks like a PATH definition problem.
1. Be sure to have /etc in your PATH (otherwise you can't find install)
2. Be sure to have $KHOROS_HOME/bin in you PATH
I hope that helps.
Konstantin
----------------------------------

To port khoros 1 patch 5 to HP-UX on an HP9000/s370, s400, s800, or s700
the following steps were taken.

1. Get the Xaw and Xmu libraries and include files 
   from hpcvaaz.cv.hp.com:~ftp/pub/MitX11R4/libs.s300.Z (or libs.s800.Z
   for the snakes) using anonymous ftp.

   As an alternative, you can also get the X11R5 libraries from
   ~ftp/pub/MitX11R5 (same machine). This is probably the preferred
   approach if you want to use X11 shared libraries.

   Uncompress and untar them into your favorite directory.

   NOTE: Don't mix those binaries with HP binaries in /usr/lib/X11R4
   and the include files with include files in /usr/include/X11R4.
   Unpredictable core dumbs may happen!
   Instead use /usr/local/X11R4 or /usr/lib/X11R5 or whatever else
   you like.

   (Ignore this step if you already have somehow the above
   include files and libraries in your system.)

2. Edit src/xvroutines/Lib/xvforms/Imakefile
   Remove:
   #define UnsharedObjs
   UNSHAREDOBJS =\
	   init.o

  and include init.o with the other objects.

3. Edit /khoros/repos/config/imake_conf/hp.cf
  and /khoros/repos/config/imake_conf/Lib/hpLib.rules

  as shown in the diffs file below 
  The changes fix the following problems:
    a) Strip automatically the binaries (-s)
    b) On the s700 solve the "too much defining" error message. (-Wp,..)
    c) Include the appropriate Fortran libraries in the linking
       of C code, since some khoros libraries use FORTRAN routines too.
    d) Eliminate the -Dxxxx in f77 calls (with Shared Libraries).
    e) Point to the correct place for the X11 Libraries
    f) Install libraries with mode 555 (otherwise code with shared libraries
       will not run)

4. Depending on when you got your code you may want
    a) get the fixed src/dspl/Lib/ldfilter.c routine
      posted in the network. (4/9/92)
    b) rm khoros/src/dspl/Lib/poly_yacc.c
    (b) solves a linker problem on the s400.

5. Run installit. Everything should compile with no problems.
   After the compilation do
----------------------

1. edit bin/kinstall_csh, and replace "mail -s" with "mailx -s"
2. You may want to edit bin/prnmanual
(Even if you don't have troff or groff, but you have a postscript printer,
you can still print the man pages. Only set up the printer command and
always accept the default answers. It should print the existing xxxxx.ps files)

Konstantinos Konstantinides

Hewlett-Packard Laboratories
P.O. Box 10490
Palo Alto, CA 94303
tel: (415) 857-4086
e-mail: kk@hpkronos.hpl.hp.com

------------------------Diffs----------------------------------------
*** hp.cf.orig	Fri Apr 10 10:44:33 1992
--- hp.cf	Fri Apr 10 10:44:33 1992
***************
*** 7,15 ****
   */
  
  
! #define OSName                 HP-UX 8.05
  #define OSMajorVersion         8
! #define OSMinorVersion         5
  
  #define SystemV                YES
  
--- 7,15 ----
   */
  
  
! #define OSName                 HP-UX 8.07
  #define OSMajorVersion         8
! #define OSMinorVersion         7
  
  #define SystemV                YES
  
***************
*** 76,87 ****
  #define InstallCmd $(SCRIPTSRC)/bsdinst.sh
  #define BaseName /bin/basename
  
  #ifdef hp9000s800
! #   define StandardDefines        -DSYSV
  #   define OptimizedCDebugFlags   +O1
  #else
  #  if OSMajorVersion == 8
! #      define StandardDefines        -DSYSV
  #  else
  #       define StandardDefines	-Wc,-Nd4000,-Ns4300,-Ne700,-Np300 -DSYSV -D_BSD -Drindex=strrchr -Dindex=strchr
  #  endif
--- 76,88 ----
  #define InstallCmd $(SCRIPTSRC)/bsdinst.sh
  #define BaseName /bin/basename
  
+ #define InstLibFlags -m 0555
  #ifdef hp9000s800
! #   define StandardDefines        -s -Wp,-H512000 -DSYSV
  #   define OptimizedCDebugFlags   +O1
  #else
  #  if OSMajorVersion == 8
! #  define StandardDefines         -s -DSYSV
  #  else
  #       define StandardDefines	-Wc,-Nd4000,-Ns4300,-Ne700,-Np300 -DSYSV -D_BSD -Drindex=strrchr -Dindex=strchr
  #  endif
***************
*** 89,98 ****
  
  #if OSMajorVersion == 8
  #  if defined (hp9000s300) || defined (hp9000s400)
! #    define SysLibs -lBSD -lmalloc -lm -ll
  #    define ForSysLibs -lFext -lF77 -lI77
  #  else
! #    define SysLibs -lBSD -lmalloc -lm -ll
  #    define ForSysLibs -lcl -lfsys
  #  endif
  #else
--- 90,99 ----
  
  #if OSMajorVersion == 8
  #  if defined (hp9000s300) || defined (hp9000s400)
! #    define SysLibs -lBSD -lmalloc -lm -ll -lIO77
  #    define ForSysLibs -lFext -lF77 -lI77
  #  else
! #    define SysLibs -lBSD -lmalloc -lm -ll -lcl
  #    define ForSysLibs -lcl -lfsys
  #  endif
  #else
***************
*** 100,106 ****
--- 101,114 ----
  #   define ForSysLibs -lFext -lF77 -lI77
  #endif
  
+ #define XLibDir  /usr/local/x11r4/lib.s300
+ #define XIncludes -I/usr/local/x11r4
  /*
+ #define XLibDir  /usr/lib/X11R5
+ #define XIncludes -I/usr/include/X11R5
+ */
+ 
+ /*
   * The Shared libaries for HP may not be complete.  We do not
   * have an HP. This Lib/hpLib.rules is a guess at how hp
   * shared libs should be made. Please mail and changes
***************
*** 108,114 ****
   * update for the next version. 
   */
  
! #define HasSharedLibraries NO
  
  #if HasSharedLibraries
  #  define SharedLibRev 1.1                /* Use Khoros revision number */
--- 116,122 ----
   * update for the next version. 
   */
  
! #define HasSharedLibraries YES
  
  #if HasSharedLibraries
  #  define SharedLibRev 1.1                /* Use Khoros revision number */
*** Lib/hpLib.rules.or	Mon Apr  6 13:38:05 1992
--- Lib/hpLib.rules	Mon Apr  6 13:38:05 1992
***************
*** 73,81 ****
  									@@\
  .f.o:									@@\
  	$(RM) $@ shared/$@						@@\
! 	$(FC) -c $(SHAREDCODEDEF) $(SHLIBDEF) $(FLIBFLAGS) $*.f		@@\
  	$(MV) $*.o shared/$*.o						@@\
! 	$(FC) -c $(SHLIBDEF) $(FLIBFLAGS) $*.f				@@\
                                                                          @@\
  clean::									@@\
  	-@if [ -d shared ]; then echo " $(RM) shared/?*.o"; \		@@\
--- 73,81 ----
  									@@\
  .f.o:									@@\
  	$(RM) $@ shared/$@						@@\
! 	$(FC) -c $(FLIBFLAGS) $*.f		@@\
  	$(MV) $*.o shared/$*.o						@@\
! 	$(FC) -c $(FLIBFLAGS) $*.f				@@\
                                                                          @@\
  clean::									@@\
  	-@if [ -d shared ]; then echo " $(RM) shared/?*.o"; \		@@\