#! ../srexx

/*
 *   inst_apl18: makes apl18 font
 *
 */

signal on novalue
address csh
signal on error

parse arg force

if userid() ~= 'root' then
 { say
   say 'inst_apl18: I need to be root.'
   say
   exit 1
 }

/* if force = '' then
 { rel = (`'uname -r'`)[1:3]

   if rel >= 5.6  then
    { say ''
      say 'The APL18 font does not work with Solaris 2.6+'
      say ''
      exit
    }
 } */

sayx 'cp apl18.bdf /usr/openwin/lib/X11/fonts/75dpi'
say 'cd /usr/openwin/lib/X11/fonts/75dpi'
cd '/usr/openwin/lib/X11/fonts/75dpi'
sayx 'bdftopcf apl18.bdf >! apl18.pcf'

sayx 'compress -f apl18.pcf'
sayx 'rm apl18.bdf'

sayx 'mkfontdir /usr/openwin/lib/X11/fonts/75dpi'

sayx 'xset fp rehash'

exit

error:
say
say 'Unable to install APL18.'
say
exit
