diff options
Diffstat (limited to 'Master/texmf-dist/doc/latex/circuit-macros/examples/Makefile')
-rw-r--r-- | Master/texmf-dist/doc/latex/circuit-macros/examples/Makefile | 104 |
1 files changed, 81 insertions, 23 deletions
diff --git a/Master/texmf-dist/doc/latex/circuit-macros/examples/Makefile b/Master/texmf-dist/doc/latex/circuit-macros/examples/Makefile index c582c0b35c4..fd8ab4ea497 100644 --- a/Master/texmf-dist/doc/latex/circuit-macros/examples/Makefile +++ b/Master/texmf-dist/doc/latex/circuit-macros/examples/Makefile @@ -10,11 +10,14 @@ # Type "make <diag>.png" to make a .png file from <diag>.m4 # Type "make <diag>.tif" to make a .tif file from <diag>.m4 # -# See also: the svg subdirectory for generating svg directly. +# See also: dpv subdirectory for creating svg with dpic -v without LaTeX # # To test the file test.m4, type "make tst" if boxdims is used, otherwise # type "make tst1". In either case the file tst.ps is created. # +# There are a few extra examples in this directory. Process them one +# at a time, or type "make extras.pdf" +# # To debug a single diagram in a directory other than this examples # directory, copy this makefile and tst.tex to where you want to work, # redefine LIBDIR (below) appropriately, and type "make <diag>.xxx" @@ -54,18 +57,19 @@ PNGOPTS = -quiet -density 400 -scale 25% -alpha Remove M4 = m4 DOC = examples -PICS = \ - ABlogix.tex Adder.tex Alogix.tex AmpTable.tex Antennas.tex \ +TEXPICS = \ + ABlogix.tex Adder.tex Alogix.tex AmpTable.tex Antennas.tex Arresters.tex \ Audio.tex Bip.tex Btree.tex Buttons.tex Byte.tex \ Capacitors.tex CanLogic.tex Chips.tex Conn.tex Connectors.tex \ - Contacts.tex Contact.tex control.tex Crossbar.tex Crow.tex \ + Contacts.tex Contact.tex control.tex Crow.tex \ csc.tex Csource.tex Decoder.tex \ Demultiplexer.tex diamond.tex Dini.tex Diodes.tex Drive.tex \ EEP.tex Emarrows.tex Escher.tex EVplugs.tex \ ex00.tex ex01.tex ex02.tex ex03.tex ex04.tex ex05.tex ex06.tex ex08.tex \ ex09.tex ex10.tex ex11.tex ex12.tex ex15.tex ex16.tex ex17.tex ex18.tex \ - ex21.tex exp.tex fet.tex Flow.tex Fuses.tex GrayCode.tex graysurf.tex \ - Grounds.tex Headers.tex Heathkit.tex \ + ex21.tex exp.tex fet.tex Flow.tex Fuses.tex \ + Geometry.tex GrayCode.tex graysurf.tex Grounds.tex \ + Headers.tex Heathkit.tex \ I2L.tex Incleps.tex Inductors.tex Jack.tex \ lcct.tex Logic.tex Loglog.tex MC.tex Mixer.tex MoreTable.tex \ MotorControl.tex Multiplexer.tex \ @@ -73,16 +77,15 @@ PICS = \ Pconn.tex Plate.tex PushPull.tex pwrsupply.tex \ Quantum.tex quick.tex \ random.tex Rectifiers.tex recycle.tex relaycoil.tex Relay.tex \ - Resistors.tex rose.tex Rotbox.tex \ + Resistors.tex Rotbox.tex \ Schottky.tex sfg.tex shapes.tex ShiftR.tex Sierpinski.tex Sixpole.tex \ - Sources.tex SQUID.tex Switches.tex \ - Tgate.tex Three.tex thyristor.tex \ - TTLnand.tex Ttree.tex Tubediags.tex ujt.tex Variable.tex Windings.tex \ - worm.tex Xform.tex XOR.tex + Smithchart.tex Sources.tex SQUID.tex Switches.tex \ + Tgate.tex Three.tex thyristor.tex TTLnand.tex Tubediags.tex \ + UNO.tex ujt.tex Variable.tex Windings.tex worm.tex Xform.tex XOR.tex # Files that have to be processed twice: -BOXDIMS = ex09.tex Crow.tex Incleps.tex Loglog.tex Opamp.tex \ - random.tex Ttree.tex Windings.tex +BOXDIMS = Btree.tex ex09.tex Crow.tex Incleps.tex Loglog.tex Opamp.tex \ + random.tex Windings.tex ######################################################################### @@ -173,20 +176,21 @@ LTXFILE=printf "|documentclass[11pt]{article}\n\ make $*.pdf convert $(PNGOPTS) $*.pdf $*.png @if test -f $*.png.0 ; then mv $*.png.0 $*.png ; fi - rm $*.pdf +# rm $*.pdf .m4.gif: make $*.pdf convert $(GIFOPTS) $*.pdf $*.gif - rm $*.pdf +# rm $*.pdf .m4.tif: make $*.pdf convert $(EPSOPTS) $*.pdf $*.tif @if test -f $*.tif.0 ; then mv $*.tif.0 $*.tif ; fi - rm $*.pdf +# rm $*.pdf .m4.svg: make $*.pdf dvisvgm --pdf $*.pdf $*.svg - rm $*.pdf + chmod 644 $*.svg +# rm $*.pdf ######################################################################### @@ -199,9 +203,22 @@ $(DOC).pdf: clean pdfmode $(DOC).tex files.tex header.tex rm -f $(BOXDIMS) ${BOXDIMS:%.tex=%.pic} $(DOC).pdf make CONF=pgf.m4 MODE=-g DIMFILE=$(DOC).dim $(BOXDIMS) pdflatex $(DOC) + @printf "\n\n optpdf trims the pdf file\n" optpdf $(DOC).pdf -pics: $(PICS) +rose.pdf: rose.m4 + m4 pdf.m4 rose.m4 | dpic -d > rose.pdf + +paletteDPV.svg: paletteDPV.m4 + m4 svg.m4 paletteDPV.m4 | dpic -v > paletteDPV.svg + +keyboard.svg: keyboard.m4 + m4 svg.m4 keyboard.m4 | dpic -v > keyboard.svg + +keyboard.pdf: keyboard.svg + convert keyboard.svg keyboard.pdf + +pics: $(TEXPICS) rose.pdf keyboard.pdf touch pics $(DOC).ps: psmode $(DOC).dvi @@ -245,13 +262,50 @@ gpic: dvips $(DVIPSOPTS) tst -o tst.ps echopics: - @echo $(PICS) + @echo $(TEXPICS) + +XTRASRC=printf "|documentclass[11pt]{article}\n\ +|usepackage[dvipsnames]{xcolor}\n\ +|usepackage{times,boxdims,siunitx,amssymb,tikz,geometry}\n\ +|geometry{margin=0.5cm}\n\ +|begin{document}\n" | $(BS) + +extras: + ( for file in `ls *.m4` ; do \ + fbase=`basename $$file .m4` ; \ + if test "`grep -L $$fbase files.tex`" = "files.tex" ; then \ + echo $$fbase ; \ + fi ; \ + done ) | sed -e '/Ball/d' \ + -e '/ASME_Y14-5/d' -e '/FlowchartDefs/d' -e '/tubedefs/d' \ + -e '/debug1/d' -e '/debug2/d' \ + -e '/paletteSVG/d' \ + -e '/Consumption/d' -e '/rotatetext/d' -e '/windows/d' \ + > extras + +XBOXDIMS = Chuck + +extras.pdf: extras + @$(XTRASRC) > extras.tex + touch extras.dim + -for file in `cat extras` ; do \ + $(M4) pgf.m4 extras.dim $$file.m4 | $(PIC) -g > $$file.tex ; \ + printf "\n|input{$$file.tex}\n" | $(BS) >> extras.tex ; \ + printf "\n $$file.m4\n |pagebreak\n" | $(BS) >> extras.tex ; \ + done + printf "\n|end{document}\n" | $(BS) >> extras.tex + pdflatex extras + -for file in $(XBOXDIMS) ; do \ + rm -f $$file.tex ; \ + $(M4) pgf.m4 extras.dim $$file.m4 | $(PIC) -g > $$file.tex ; \ + done + pdflatex extras testall: (cd mf; make) (cd mpost; make) (cd psfrag; make) - (cd svg; make) + (cd dpv; make) (cd xfig; make) clobber: clean @@ -270,12 +324,16 @@ clobber: clean # @if test -f distmakefile ; then make -f distmakefile clobber ; fi clean: - @printf "\n examples clean:\n" + @printf "\n\n examples clean:\n\n" + -if test -f extras ; then \ + for file in `cat extras` ; do rm -f $$file.pic $$file.tex ; done ; fi + rm -f extras extras.* rm -f core boxdims.tar.gz pics rm -f *.dvi *.aux *.log *.toc *.blg *.eps *.tif *.epsi eps *-mfpic* *.svg - rm -f fig*.tex $(PICS) *.roff *.int *.pic gpic.m4 test.tex xxx* *.fig + rm -f fig*.tex $(TEXPICS) *.roff *.int *.pic gpic.m4 test.tex xxx* *.fig + rm -f rose.pdf rm -f *.dim *.bak rotate.ps tst.ps *.bbl *-pics.ps - rm -f *.tfm *[0-9]pk *.png *.1 *.gif + rm -f *.tfm *[0-9]pk *.png *.svg *.1 *.gif rm -f F_* Version.tex *stackdump *.ico ./.[A-Za-z]* rm -rf distfile distfile.tar.gz mode.tex @printf "\n" |