DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400 Tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400 Tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download
Index: ┃ M T

⟦78cacf180⟧ TextFile

    Length: 13408 (0x3460)
    Types: TextFile
    Names: »MAKEFILE«

Derivation

└─⟦5f3412b64⟧ Bits:30000745 8mm tape, Rational 1000, ENVIRONMENT 12_6_5 TOOLS 
    └─ ⟦91c658230⟧ »DATA« 
        └─⟦5d656759a⟧ 
            └─⟦this⟧ 
└─⟦d10a02448⟧ Bits:30000409 8mm tape, Rational 1000, ENVIRONMENT, D_12_7_3
    └─ ⟦fc9b38f02⟧ »DATA« 
        └─⟦8e9e227a9⟧ 
            └─⟦this⟧ 

TextFile

#==============================================================================
# Makefile - Use this to generate and/or install an executable version
#	     of the Rational X Interface program; RXI.
#
# Regeneration and Installation of RXI from sources :
#
#   Unix> make <what>
#
# <what> is one of:
#
#   install		- Installs just the rxi executables and data files.
#   install.man		- Installs just the rxi man page.
#   install.fonts	- Installs just the fonts that rxi needs
#   install.terminfo	- Installs the rxi terminal type into the terminfo db.
#   install.all		- Does install, install.man, and install.fonts.
#
#   relink		- Relinks the rxi executables with local workstation
#			  libraries (perhaps cause the use of shared
#			  libraries, a desirable situation.)
#   clean		- "Cleans" the directory so that you can rebuild
#			  rxi from sources.
#   all			- Creates all rxi executables (from sources if
#			  necessary, do this after a "make clean").
#   install.fonts.fallback- If the normal install.fonts process fails (some
#			  important system program is missing for instance)
#			  then this can be used to attempt to install the
#			  fonts using programs supplied by Rational.
#
#==============================================================================
#---Generated programs/fonts/etc. are installed into these directories.
#   You may want to change some or all of these directory specifications.
#
#	BINDIR		- where rxi shell command will reside; eg. /usr/bin
#	AIXBINDIR	- where AIX X Windows binaries currently reside;
#			  eg. /usr/bin
#	X11BINDIR	- where rxi executables will reside;
#			  eg. /usr/lpp/X11/bin
#	FONTDIR		- where fonts reside; eg. /usr/lib/X11/fonts
#	MANDIR		- the man page directory for the rxi man page
#	XAPPLOADDIR	- where application defaults files reside
#==============================================================================

#---Generated items are installed into these directories.

        DESTDIR =
         BINDIR = $(DESTDIR)/usr/bin
      X11BINDIR = $(DESTDIR)/usr/lpp/X11/bin
      AIXBINDIR = $(DESTDIR)/usr/bin
        FONTDIR = $(DESTDIR)/usr/lpp/fonts
         MANDIR = $(DESTDIR)/usr/man/mann
    XAPPLOADDIR = $(DESTDIR)/usr/lib/X11/app-defaults

#---Change this if you change MANDIR.  A MANDIR of /usr/man/man2.Z implies a
#   file name of rxi.2, etc.

        MANFILE = rxi.n

#==============================================================================
# You should not need to edit anything below this point.
#==============================================================================

             CC = cc
          CHMOD = chmod
             FC = $(X11BINDIR)/bdftosnf -t
             LD = ld
      MKFONTDIR = $(X11BINDIR)/mkfontdir
             MV = mv
             RM = rm -f
          SHELL = /bin/sh

#---These are passed to all normal make commands.

       ALLMAKES = BINDIR="$(BINDIR)" \
		  X11BINDIR="$(X11BINDIR)" \
		  FONTDIR="$(FONTDIR)" \
		  MANDIR="$(MANDIR)" \
		  XAPPLOADDIR="$(XAPPLOADDIR)" \
		  OPTIMIZE="$(OPTIMIZE)" \
                  CCFLAGS="$(CCFLAGS)" \
		  DEFINES="$(DEFINES)" \
                  SIZING="$(SIZING)"

#---These are passed to all recursive make commands.

 RECURSIVEMAKES = $(ALLMAKES) \
                  INCLUDES="$(INCLUDES)" \
                  LDFLAGS="$(LDFLAGS)" \
		  LIBDIRS="$(LIBDIRS)"

  RECURSIVEMAKE = make $(RECURSIVEMAKES) $(MFLAGS)

#---These are passed to all SUBDIR make commands.

    SUBDIRMAKES = $(ALLMAKES) \
                  INCLUDES="-I.. $(INCLUDES)" \
                  LDFLAGS="$(LDFLAGS)" \
		  LIBDIRS="$(LIBDIRS)"

     SUBDIRMAKE = make $(SUBDIRMAKES) $(MFLAGS)

#---These are passed to all make commands done for Rational maintenance.

  MAINTINCLUDES = 

     MAINTMAKES = $(ALLMAKES) \
		  INCLUDES="$(MAINTINCLUDES) $(INCLUDES)" \
                  LDFLAGS="" \
		  LIBDIRS=""

      MAINTMAKE = make $(MAINTMAKES)     $(MFLAGS)

#==============================================================================

#---These macros are defined on the make command line or not at all.

        CCFLAGS =
        DEFINES =
       INCLUDES =
        LDFLAGS =
        LIBDIRS =

#---These macros are redefined on the make command line if some special effect
#   is desirec.

#       OPTIMIZE =
       OPTIMIZE = -O

#---These are flags necessary to get things to compile on the RT.
#    -Nn1234 - symbol table size
#    -Nd1234 - dimension table size
#    -Np1234 - constant table size
#    -Nt1234 - parse tree table size
#    -w      - no silly messages

         SIZING = 

#---These macros are (presumably) never overridded by the command line.

    intCCFLAGS  = $(OPTIMIZE) $(SIZING) $(intDEFINES) $(intINCLUDES)
    nopCCFLAGS  =             $(SIZING) $(intDEFINES) $(intINCLUDES)
    intDEFINES  = -DUTMP -DRIOS -D_ALL_SOURCE -D_XOPEN_SOURCE $(DEFINES)
    intINCLUDES = -I. $(INCLUDES)
    intLDFLAGS  = $(LDFLAGS) $(intLIBDIRS)
    intLIBDIRS  = $(LIBDIRS)

.c.o:
	$(CC) $(intCCFLAGS) -c $*.c

           XLIB = -lX11
       XTOOLLIB = -lXt

   INSTAPPFLAGS = 0555
   INSTDEFFLAGS = 0444

         RM_CMD = $(RM) *.CKP *.ln *.BAK *.bak *.o core errs ,* *~ *.a \
			make.log X11/*.o *.tmp

OBJS1 = main.o input.o charproc.o cursor.o util.o tabs.o \
        screen.o scrollbar.o button.o misc.o \
        RMForm.o ratmenu.o VTPrsTbl.o data.o menu.o \
        RMShell.o RMLabel.o RMSub.o RMCommand.o

PROGRAMS = rxi RXI.tmp RXI.tmp2 version.info rxi.man

OBJS = $(OBJS1) $(OBJS2) $(OBJS3)

#==============================================================================
# Compilation/Generation
#==============================================================================

all:
	$(RECURSIVEMAKE) all-libraries
	$(RECURSIVEMAKE) all-programs

all-libraries:
	cd X11 ; $(SUBDIRMAKE) all

all-programs: $(PROGRAMS)

X11/libX.o:
	cd X11 ; $(SUBDIRMAKE) all

main.o: X11/libX.o

util.o:
	$(CC) $(nopCCFLAGS) -c $*.c

rxi: $(OBJS1) X11/libX.o
	$(RM) $@
	$(CC) -o $@ $(intLDFLAGS) $(OBJS1) X11/libX.o \
		$(XTOOLLIB) $(XLIB) -lcurses

relink: all-libraries
	$(RM) $(PROGRAMS)
	for pgm in $(PROGRAMS) ; do \
	    $(RECURSIVEMAKE) $$pgm ; \
	done

TMPL = sed \
    -e 's=@BINDIR@='$(BINDIR)'=g' \
    -e 's=@X11BINDIR@='$(X11BINDIR)'=g' \
    -e 's=@APPDEF@='$(XAPPLOADDIR)'=g'

RXI_ENV = $(XAPPLOADDIR)/RXI_Env_Menu

RXI.tmp: RXI.Xdefaults Makefile version.info
	rm -f RXI.tmp
	@(echo 'BEGIN { print "BEGIN {"; }' ; \
	  echo '/#define *defGeometry/ { print "GEO = " $$3 ";" ; }' ; \
	  echo '/#define *defRV/ { print " RCG = " $$3 ";" ; }' ; \
	  echo '{ next; }' ; \
	  echo 'END { print "}"; }' ; \
	) > awk.tmp
	awk -f awk.tmp rcg.h > awk2.tmp
	@(echo '/\*recognition:[ 	]*<.*>/ ' \
			'{ print $$1 "    " RCG ; next ;}' ; \
	  echo '/\*vt100.geometry:[ 	]*<.*>/ ' \
			'{ print $$1 "    " GEO ; next; }' ; \
	  echo '/\*menu.envMenuFile:[ 	]*<.*>/ ' \
			'{ print $$1 "    '"$(RXI_ENV)"'" ; next;}' ; \
	  echo '{ print; }' ; \
	) >> awk2.tmp
	awk '{ print "# " $$0; }' version.info  >  RXI.tmpx
	echo ''					>> RXI.tmpx
	awk -f awk2.tmp RXI.Xdefaults		>> RXI.tmpx
	mv RXI.tmpx RXI.tmp
	@rm -f awk.tmp awk2.tmp

RXI.tmp2: RXI_Env_Menu Makefile version.info
	rm -f RXI.tmp2
	awk '{ print "/* " $$0 " */"; }' version.info	>  RXI.tmpx
	echo ''						>> RXI.tmpx
	cat RXI_Env_Menu 				>> RXI.tmpx
	mv RXI.tmpx RXI.tmp2

rxi.man: rxi.man.tmpl Makefile version.info
	rm -f rxi.man
	@( echo '/@VERSION@/ {' ; \
	   awk '{ printf "print %c%s%c;", 34, $$0, 34; }' version.info ; \
	   echo ' next;}' ; \
	   echo '{ print; }' ; \
	) > awk.tmp
	awk -f awk.tmp rxi.man.tmpl > rxi.many
	d="`awk '/ [12][90][0-9][0-9]/ {print $$0;exit;}' version.info`" ; \
	    $(TMPL) -e 's=@DATE@='"$$d"'=g' rxi.many > rxi.manx
	rm -f awk.tmp rxi.many
	mv rxi.manx rxi.man

rxi.sh: rxi.sh.tmpl Makefile
	$(TMPL) rxi.sh.tmpl > rxi.sh

version.info: rcg.h
	@(echo 'BEGIN { GO = 0; }' ; \
	  echo '/RatRXIVersion\[\]/                   { GO = 1; next; }' ; \
	  echo '/^ *0 *\};/ || (GO == 1 && /#ifdef /) { GO = 0; exit; }' ; \
	  echo 'GO == 1 { print $$0; }' ; \
	) > awk.tmp
	awk -f awk.tmp rcg.h | sed -e 's=", *==g' -e 's= *"==g' > version.info

#==============================================================================
# Install Executables
#==============================================================================

install.all: install.man  install.fonts  install install.terminfo

install.terminfo: terminfo
	tic terminfo

install.man: rxi.man
	-cp rxi.man $(MANDIR)/$(MANFILE)
	-$(CHMOD) 0444 $(MANDIR)/$(MANFILE)
	-rm rxi.man

install: all-libraries $(X11BINDIR) $(XAPPLOADDIR) rxi.sh RXI.tmp RXI.tmp2
	if [ -f $(X11BINDIR)/rxi ] ; then \
		mv $(X11BINDIR)/rxi $(X11BINDIR)/rxi.old ; \
	else \
		echo New installation. ; \
	fi
	cp rxi                          $(X11BINDIR)/rxi
	cp rxi.sh                       $(BINDIR)/rxi
	cp RXI.tmp                      $(XAPPLOADDIR)/RXI
	cp RXI.tmp2                     $(XAPPLOADDIR)/RXI_Env_Menu
	$(CHMOD) $(INSTAPPFLAGS)        $(X11BINDIR)/rxi
	$(CHMOD) $(INSTAPPFLAGS)        $(BINDIR)/rxi
	$(CHMOD) $(INSTDEFFLAGS)        $(XAPPLOADDIR)/RXI
	$(CHMOD) $(INSTDEFFLAGS)        $(XAPPLOADDIR)/RXI_Env_Menu
	rm rxi.sh RXI.tmp RXI.tmp2

$(BINDIR):
	mkdir -p $(BINDIR)

$(X11BINDIR):
	mkdir -p $(X11BINDIR)

$(XAPPLOADDIR):
	mkdir -p $(XAPPLOADDIR)

#==============================================================================
# Fonts
#==============================================================================

install.fonts.source:
	cp fixed-screen-*.bdf $(FONTSRC)
	cp bdf.Imakefile         $(FONTSRC)
	@echo -n '=================================================='
	@echo '========================='
	@echo -n Please cd $(FONTSRC) and add fixed-screen-'*'.bdf to 
	@echo the Imakefile.
	@echo -n and then do '"make Makefile"' and '"make install"'.  See
	@echo  bdf.Imakefile for
	@echo example Imakefile entries for these fonts.
	@echo -n '=================================================='
	@echo '========================='

install.fonts:
	for bdf in fixed-screen-*.bdf ; do \
	    snf=`echo $$bdf | sed 's/\.bdf/.snf/g'` ; \
	    echo $$bdf '=>' $(FONTDIR)/$$snf ; \
	    $(FC) $(FCFLAGS) $$bdf > $(FONTDIR)/$$snf ; \
	done
	( cd $(FONTDIR) ; \
		mv fonts.dir fonts.dir.`date | sed -e 's/ /-/g'` ; \
		cp /dev/null fonts.dir ; \
		$(MKFONTDIR) . )

install.fonts.fallback:
	mv bdftosnf.exe bnftosnf
	mv mkfontdir.exe mkfontdir
	$(RECURSIVEMAKE) "MKFONTDIR=`pwd`/mkfontdir" \
			 "FC=`pwd`/bnftosnf -t "install.fonts
	mv bdftosnf bnftosnf.exe
	mv mkfontdir mkfontdir.exe

#==============================================================================

clean:
	$(RM_CMD) \#*
	$(RM) RXI.tmp* rxi.man rx rxsun4 rxsun3 version.info rxi-backup*
	$(RM) $(PROGRAMS) *.snf
	cd X11 ; $(SUBDIRMAKE) clean

#==============================================================================
# RXI Maintenance
#==============================================================================

maint:
	$(MAINTMAKE) all

backup.fonts:
	for bdf in fixed-screen-*.bdf ; do \
	    snf=`echo $$bdf | sed 's/\.bdf/.snf/g'` ; \
	    echo $$bdf '=>' $$snf ; \
	    $(FC) $(FCFLAGS) $$bdf > $$snf ; \
	done

backup.relink:
	$(MAINTMAKE) relink

backup: backup.fonts backup.relink
	sed -e 's/\(#define *[a-zA-Z_0-9]* *\)1/\10/g' RXI_Env_Menu > foo
	mv foo RXI_Env_Menu
	rm -f rxi-backup version.info RXI.Tmp RXI.Tmp2
	$(CHMOD) ug+rw * */*
	tar -c -v -f - * > ../rxi-backup$$$$ ; \
	    mv ../rxi-backup$$$$ ./rxi-backup

restore: rxi-backup
	tar -x -f ./rxi-backup
	for hfile in *.hh ; do \
	    mv $$hfile `echo $$hfile | sed -e 's/\.hh/.h/g'` ; \
	done
	sleep 2
	touch *.o
	sleep 2
	touch $(PROGRAMS)
	rm rxi-backup

deinstall:
	rm -f $(X11BINDIR)/rxi
	rm -f $(XAPPLOADDIR)/RXI*
	rm -f $(FONTDIR)/misc/fixed-{r,b,wr,wb}-{11,12,13,14,15,16}.snf
	@echo '======================================================'
	@echo 'You will probably now see messages about "foo: invalid'
	@echo 'font, skipping".  Ignore them.  They are normal.'
	@echo '======================================================'
	( cd $(FONTDIR) ; $(AIXBINDIR)/mkfontdir . )

#==============================================================================
# DO NOT DELETE
#==============================================================================

button.o:	ptyx.h data.h error.h menu.h ratmenu.h 
charproc.o:	ptyx.h VTparse.h data.h error.h main.h menu.h ratmenu.h
cursor.o:	ptyx.h 
data.o:		ptyx.h data.h
input.o:	ptyx.h data.h ratmenu.h
main.o:		ptyx.h data.h error.h main.h rcg.h
menu.o:		menu.h ptyx.h data.h
misc.o:		ptyx.h data.h error.h gray.ic wait.ic waitmask.ic ratmenu.h
screen.o:	ptyx.h error.h
scrollbar.o:	ptyx.h data.h X11/Scroll.h error.h
tabs.o:		ptyx.h 
RMForm.o:	RMFormP.h RMForm.h ratmenu.h RMLabelP.h RMLabel.h
RMForm.o:	X11/Label.h X11/Simple.h X11/LabelP.h X11/SimpleP.h 
RMForm.o:	RMSubP.h RMSub.h RMCommand.h RMCommandP.h
ratmenu.o:	RMCommand.h X11/Label.h X11/Simple.h RMForm.h 
ratmenu.o:	ratmenu.h RMShellP.h RMShell.h RMLabelP.h RMLabel.h
ratmenu.o:	X11/LabelP.h X11/SimpleP.h RMSubP.h RMSub.h
ratmenu.o:	RMCommandP.h ptyx.h data.h menu.h
util.o:		ptyx.h data.h error.h
VTPrsTbl.o:	VTparse.h
RMShell.o:	ratmenu.h RMShellP.h RMShell.h X11/Simple.h 
RMLabel.o:	RMLabelP.h RMLabel.h X11/Label.h X11/Simple.h X11/LabelP.h
RMLabel.o:	X11/SimpleP.h
RMSub.o:	RMSubP.h RMSub.h RMCommand.h X11/Label.h X11/Simple.h
RMSub.o:	RMCommandP.h X11/LabelP.h X11/SimpleP.h
RMCommand.o:	RMCommandP.h RMCommandI.h RMCommand.h