# Automatic french style files installation for Unix & LaTeX # # QUI VEUT BIEN GENERALISER CE MAKEFILE AUX AUTRES PLATEFORMES ? Merci. # (email: gaulle@idris.fr) # ma derniere revision date du 9/1/96. # ######################################################################## # Start of customization section ######################################################################## # Defaults : hyconfig and kbconfig configurators are used. # ISO-Latin-1 (or nearly that) is the default encoding # For other choices read documentation or README files. THISFILE=Makefile.unx# we call it again #ALLTEXPATH=/usr/local/texmf# the usual pointer with TDS ALLTEXPATH=$$TEXMF#set the root directory if necessary SHELL=/bin/sh # choose your installation pgm # Either cp, install BSD or SYSTEM V: #INSTALLCMD=cp #INTERACTIVE=-i# for the "cp" commands INSTALLCMD=/usr/bin/install -c # #INSTALLCMD=/usr/ucb/install -c # on AIX! #INSTALLCMD=/etc/install # on HP-UX MODBIN=-m 755# chmod for binaries MODTXT=-m 644# chmod for textual files INTERACTIVE= CC=cc LEX=lex #LEX=flex -8 # use flex if you have any pb with lex (specially with solaris) LATEXCMD=rlatex2e# the unix command to run latex recursively with makeindex #LATEXCMD=latex# normally you should have at least this! PRINTDVI=dvips -n55 # command to print the first 55 pages of a dvi file # Where initex resides for your system (in the machine depend dir of TDS) #INIDIR=${ALLTEXPATH}/bin INIDIR=${ALLTEXPATH}/ds3100 # Where to move the binaries of kb8to7 and kb7to8 BINDIR=${ALLTEXPATH}/bin # The directory where all runtime files reside and new ones will be copied DESTDIR=${ALLTEXPATH}/tex/generic/french # The directory where the format file will reside FORMATS=${ALLTEXPATH}/web2c/ini # The directory where the documentation (dvi) will reside TEXDOCS=${ALLTEXPATH}/doc/generic/french # The directory where other (english) hyphen files reside HYPHDIR=${ALLTEXPATH}/tex/plain/base ####### # Check inputs/language.dat for languages and hyphenation file names. ####### ######### Set your environnement variables if necessary (eg TEXINPUTS and co) ######### SO THAT TeX WILL FIND at least THE FRENCH FILES IN THIS DIRECTORY. ######### (Edit the latexenv file for example and load it) ######### Edit the following only if you want to move *.fd or *.ist ######### to a different place. # The directory where the .fd files reside: FDDIR=${ALLTEXPATH}/tex/latex/fd # The directory where class and package files reside: INPUTDIR=$(DESTDIR) # The directory where the makeindex style files reside ISTDIR=$(DESTDIR) ######################################################################## # End of customization section ######################################################################## # "the" thing we are making FORMAT=latex default: noenglish french french: # @echo "$(DESTDIR) $(FORMATS)" @if test ! "${DESTDIR}" -o ! "$(FORMATS)" ; then \ echo "Destination directories not set." ; \ echo "Please edit the Makefile first!" ; \ exit 1 ; \ else \ make -f ${THISFILE} formats kb2lex ; \ echo "Generation is done, do you want to \"installall\"?"; \ fi english: cd $(INPUTS); ${CP} ${INTERACTIVE} Oenglish.doc english.doc;\ ${CP} ${INTERACTIVE} Oenglish.sty english.sty; noenglish: -cd $(INPUTS); rm english.doc english.sty; formats: initex/plain.fmt initex/$(FORMAT).fmt $(FORMAT).ltx: # see your favorite LaTeX distrib initex/plain.fmt: cd initex ; ${INIDIR}/initex plain.tex "\dump" @echo "You can test this format now ****" initex/$(FORMAT).fmt: $(FORMAT).ltx cd initex ; ${INIDIR}/initex $(FORMAT).ltx @echo "You can test this format now ****" kb2lex: kb8to7 kb7to8 kb8to7: kb8to7.lex kb7to8.lex ${LEX} -v kb8to7.lex ; ${CC} -o kb8to7 lex.yy.c -ll @echo "kb8to7 generated" kb7to8: kb8to7.lex kb7to8.lex ${LEX} -v kb7to8.lex ; ${CC} -o kb7to8 lex.yy.c -ll @echo "kb7to8 generated" @cat tst/french.tst > tst/f7ench.tst @./kb7to8 < tst/f7ench.tst > tst/french.tst @cat tst/frenchlb.tex > tst/f7enchlb.tex @./kb7to8 < tst/f7enchlb.tex > tst/frenchlb.tex @echo "Torture-test converted to 8-bit" kb8to7.lex kb7to8.lex: ${LATEXCMD} kb2lex CP=${INSTALLCMD} install: #initex/$(FORMAT).fmt mkdirhier ${FORMATS} cd initex ; ${CP} ${INTERACTIVE} ${MODTXT} plain.fmt $(FORMATS) cd initex ; ${CP} ${INTERACTIVE} ${MODTXT} $(FORMAT).fmt $(FORMATS) mkdirhier ${DESTDIR} -cd initex ; ${CP} ${INTERACTIVE} ${MODTXT} latex209.cfg ${DESTDIR} @echo "Format ${FORMAT} just installed." installall: install kb2lex mkdirhier ${BINDIR} -cp /dev/null ${BINDIR}/kb7to8 # clean for HP -${CP} ${INTERACTIVE} ${MODBIN} kb7to8 ${BINDIR} -cp /dev/null ${BINDIR}/kb8to7 # clean for HP -${CP} ${INTERACTIVE} ${MODBIN} kb8to7 ${BINDIR} @echo "kb7to8 and kb8to7 installed" cp ALIRE.dvi docfrench.dvi mkdirhier ${TEXDOCS} cp /dev/null ${TEXDOCS}/docfrench.dvi ${CP} ${MODTXT} docfrench.dvi ${TEXDOCS}/docfrench.dvi rm docfrench.dvi mkdirhier ${DESTDIR} @echo "Documentation installed" cd inputs ; for f in *.tex ; \ do \ echo ${CP} ${MODTXT} $$f ${DESTDIR} ; \ cp /dev/null ${DESTDIR}/$$f ; \ ${CP} ${MODTXT} $$f ${DESTDIR} ; \ done cd inputs ; for f in *.chk ; \ do \ cp /dev/null ${DESTDIR}/$$f ; \ echo ${CP} ${MODTXT} $$f ${DESTDIR} ; \ ${CP} ${MODTXT} $$f ${DESTDIR} ; \ done cd inputs ; for f in *.dmy ; \ do \ cp /dev/null ${DESTDIR}/$$f ; \ echo ${CP} ${MODTXT} $$f ${DESTDIR} ; \ ${CP} ${MODTXT} $$f ${DESTDIR} ; \ done cd inputs ; for f in *.sty ; \ do \ echo ${CP} ${MODTXT} $$f ${DESTDIR} ; \ cp /dev/null ${DESTDIR}/$$f ; \ ${CP} ${MODTXT} $$f ${DESTDIR} ; \ done cd inputs ; for f in *.doc ; \ do \ echo ${CP} ${MODTXT} $$f ${DESTDIR} ; \ cp /dev/null ${DESTDIR}/$$f ; \ ${CP} ${MODTXT} $$f ${DESTDIR} ; \ done cd inputs ; for f in *.dat ; \ do \ echo ${CP} ${MODTXT} $$f ${DESTDIR} ; \ cp /dev/null ${DESTDIR}/$$f ; \ ${CP} ${MODTXT} $$f ${DESTDIR} ; \ done @echo "French inputs installed" mkdirhier ${ISTDIR} cd inputs ; for f in *.ist ; \ do \ echo ${CP} ${MODTXT} $$f ${ISTDIR} ; \ cp /dev/null ${DESTDIR}/$$f ; \ ${CP} ${MODTXT} $$f ${ISTDIR} ; \ done @echo "Makeindex styles installed" # for future use: # ${CP} *.fd $(FDDIR) # ${CP} *.cls *.clo *.def $(INPUTDIR) @echo "*** All is installed *** except contribs and tests files." @echo "Do you make the \"reftest\" now?" reftest: cd tst ; ${LATEXCMD} frenchlb ; *.glo *.idx *.lof *.lot *.toc *.aux @echo "Torture test done, do you want the files to be \"printed\" (>100pages)?" printed: cd tst ; if [ "$$PRINTER" != "" ] ;\ then ${PRINTDVI}-P $$PRINTER frenchrf ;\ else ${PRINTDVI} frenchrf ; fi ; cd tst ; if [ "$$PRINTER" != "" ] ;\ then ${PRINTDVI}-P $$PRINTER frenchlb ;\ else ${PRINTDVI} frenchlb ; fi ; @echo "Please compare the outputs and then" @echo "send the message-file frmsgOK to B. Gaulle" # @echo "Are you ready to \"sendmessage\" now?" clean: -rm initex/plain.fmt -rm initex/$(FORMAT).fmt initex/*.log initex/latex209.cfg initex/*.aux -rm *.lex kb7to8 kb8to7 *.log *.aux lex.yy.c -rm tst/f7ench.tst tst/f7enchlb.tex -cd tst ; rm frenchlb.dvi *.log *.aux *.lof *.lot *.toc *.idx *.glo -cd initex/tests ; rm *.dvi *.log *.aux