Fred Drake | 47fd8fe | 1998-05-08 15:36:36 +0000 | [diff] [blame] | 1 | # Generate the Python "info" documentation. |
| 2 | |
Fred Drake | 78104a9 | 1999-01-08 15:33:38 +0000 | [diff] [blame] | 3 | TOPDIR=.. |
| 4 | TOOLSDIR=$(TOPDIR)/tools |
Fred Drake | 78104a9 | 1999-01-08 15:33:38 +0000 | [diff] [blame] | 5 | HTMLDIR=$(TOPDIR)/html |
| 6 | |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 7 | # The emacs binary used to build the info docs. GNU Emacs 21 is required. |
| 8 | EMACS=emacs |
| 9 | |
Fred Drake | 78104a9 | 1999-01-08 15:33:38 +0000 | [diff] [blame] | 10 | MKINFO=$(TOOLSDIR)/mkinfo |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 11 | SCRIPTS=$(TOOLSDIR)/checkargs.pm $(TOOLSDIR)/mkinfo $(TOOLSDIR)/py2texi.el |
Fred Drake | 78104a9 | 1999-01-08 15:33:38 +0000 | [diff] [blame] | 12 | |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 13 | # set VERSION to code the VERSION number into the info file name |
| 14 | # allowing installation of more than one set of python info docs |
| 15 | # into the same directory |
| 16 | VERSION= |
Fred Drake | 47fd8fe | 1998-05-08 15:36:36 +0000 | [diff] [blame] | 17 | |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 18 | all: check-emacs-version \ |
Fred Drake | 6c85bcb | 2003-07-16 04:02:58 +0000 | [diff] [blame] | 19 | api dist ext mac ref tut whatsnew \ |
| 20 | lib |
| 21 | # doc inst |
Fred Drake | 47fd8fe | 1998-05-08 15:36:36 +0000 | [diff] [blame] | 22 | |
Fred Drake | 6c85bcb | 2003-07-16 04:02:58 +0000 | [diff] [blame] | 23 | api: python$(VERSION)-api.info |
| 24 | dist: python$(VERSION)-dist.info |
| 25 | doc: python$(VERSION)-doc.info |
| 26 | ext: python$(VERSION)-ext.info |
| 27 | inst: python$(VERSION)-inst.info |
| 28 | lib: python$(VERSION)-lib.info |
| 29 | mac: python$(VERSION)-mac.info |
| 30 | ref: python$(VERSION)-ref.info |
| 31 | tut: python$(VERSION)-tut.info |
| 32 | whatsnew: $(WHATSNEW) |
| 33 | $(WHATSNEW): python$(VERSION)-$(WHATSNEW).info |
Fred Drake | 47fd8fe | 1998-05-08 15:36:36 +0000 | [diff] [blame] | 34 | |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 35 | check-emacs-version: |
| 36 | @v="`$(EMACS) --version 2>&1 | egrep '^(GNU |X)Emacs [12]*'`"; \ |
| 37 | if `echo "$$v" | grep '^GNU Emacs 21' >/dev/null 2>&1`; then \ |
| 38 | echo "Using $(EMACS) to build the info docs"; \ |
| 39 | else \ |
| 40 | echo "GNU Emacs 21 is required to build the info docs"; \ |
| 41 | echo "Found $$v"; \ |
| 42 | false; \ |
| 43 | fi |
Fred Drake | 47fd8fe | 1998-05-08 15:36:36 +0000 | [diff] [blame] | 44 | |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 45 | python$(VERSION)-api.info: ../api/api.tex $(SCRIPTS) |
Fred Drake | 66abcee | 2002-11-13 19:31:04 +0000 | [diff] [blame] | 46 | EMACS=$(EMACS) $(MKINFO) $< $*.texi $@ |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 47 | |
| 48 | python$(VERSION)-ext.info: ../ext/ext.tex $(SCRIPTS) |
Fred Drake | 66abcee | 2002-11-13 19:31:04 +0000 | [diff] [blame] | 49 | EMACS=$(EMACS) $(MKINFO) $< $*.texi $@ |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 50 | |
| 51 | python$(VERSION)-lib.info: ../lib/lib.tex $(SCRIPTS) |
Fred Drake | 66abcee | 2002-11-13 19:31:04 +0000 | [diff] [blame] | 52 | EMACS=$(EMACS) $(MKINFO) $< $*.texi $@ |
Fred Drake | 47fd8fe | 1998-05-08 15:36:36 +0000 | [diff] [blame] | 53 | |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 54 | python$(VERSION)-mac.info: ../mac/mac.tex $(SCRIPTS) |
Fred Drake | 66abcee | 2002-11-13 19:31:04 +0000 | [diff] [blame] | 55 | EMACS=$(EMACS) $(MKINFO) $< $*.texi $@ |
Fred Drake | 47fd8fe | 1998-05-08 15:36:36 +0000 | [diff] [blame] | 56 | |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 57 | python$(VERSION)-ref.info: ../ref/ref.tex $(SCRIPTS) |
Fred Drake | 66abcee | 2002-11-13 19:31:04 +0000 | [diff] [blame] | 58 | EMACS=$(EMACS) $(MKINFO) $< $*.texi $@ |
Fred Drake | 47fd8fe | 1998-05-08 15:36:36 +0000 | [diff] [blame] | 59 | |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 60 | python$(VERSION)-tut.info: ../tut/tut.tex $(SCRIPTS) |
Fred Drake | 66abcee | 2002-11-13 19:31:04 +0000 | [diff] [blame] | 61 | EMACS=$(EMACS) $(MKINFO) $< $*.texi $@ |
Fred Drake | 47fd8fe | 1998-05-08 15:36:36 +0000 | [diff] [blame] | 62 | |
Fred Drake | 6c85bcb | 2003-07-16 04:02:58 +0000 | [diff] [blame] | 63 | # Not built by default; the conversion doesn't handle \p and \op |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 64 | python$(VERSION)-doc.info: ../doc/doc.tex $(SCRIPTS) |
Fred Drake | 66abcee | 2002-11-13 19:31:04 +0000 | [diff] [blame] | 65 | EMACS=$(EMACS) $(MKINFO) $< $*.texi $@ |
Fred Drake | ca92eeb | 2000-10-26 19:26:47 +0000 | [diff] [blame] | 66 | |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 67 | python$(VERSION)-dist.info: ../dist/dist.tex $(SCRIPTS) |
Fred Drake | 66abcee | 2002-11-13 19:31:04 +0000 | [diff] [blame] | 68 | EMACS=$(EMACS) $(MKINFO) $< $*.texi $@ |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 69 | |
Fred Drake | 6c85bcb | 2003-07-16 04:02:58 +0000 | [diff] [blame] | 70 | # Not built by default; the conversion chokes on \installscheme |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 71 | python$(VERSION)-inst.info: ../inst/inst.tex $(SCRIPTS) |
Fred Drake | 66abcee | 2002-11-13 19:31:04 +0000 | [diff] [blame] | 72 | EMACS=$(EMACS) $(MKINFO) $< $*.texi $@ |
Fred Drake | 8981fdf | 1998-05-11 19:54:57 +0000 | [diff] [blame] | 73 | |
Fred Drake | 6c85bcb | 2003-07-16 04:02:58 +0000 | [diff] [blame] | 74 | # "whatsnew20" doesn't currently work |
| 75 | python$(VERSION)-$(WHATSNEW).info: ../whatsnew/$(WHATSNEW).tex $(SCRIPTS) |
| 76 | EMACS=$(EMACS) $(MKINFO) $< $*.texi $@ |
| 77 | |
Fred Drake | 8981fdf | 1998-05-11 19:54:57 +0000 | [diff] [blame] | 78 | clean: |
Fred Drake | 78104a9 | 1999-01-08 15:33:38 +0000 | [diff] [blame] | 79 | rm -f *.texi~ *.texi |
Fred Drake | 8981fdf | 1998-05-11 19:54:57 +0000 | [diff] [blame] | 80 | |
| 81 | clobber: clean |
Fred Drake | bfc18bd | 2002-05-03 04:50:51 +0000 | [diff] [blame] | 82 | rm -f *.texi python*-*.info python*-*.info-[0-9]* |