1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-01 08:17:38 +00:00

Minor lispintro tweaks

* doc/lispintro/Makefile.in (emacsdir): New variable..
(MAKEINFO_OPTS, ENVADD): Add $emacsdir.
(srcs): Add emacsver.texi.
(dist): Include emacsver.texi.  Edit emacsdir.

* doc/lispintro/emacs-lisp-intro.texi (emacsver.texi): Include it.
(copying): For non-printed versions, uses Emacs version rather
than that of the printed book.
(Complications, Lisp macro, defvar and asterisk, defcustom): Copyedits.

* doc/lispintro/makefile.w32-in (emacsdir): New variable.
(INFO_SOURCES): Add emacsver.texi.
(ENVADD): Add $emacsdir (and $texinfodir).
This commit is contained in:
Glenn Morris 2013-04-23 20:58:23 -04:00
parent edbf456935
commit 09b98a01c1
4 changed files with 55 additions and 20 deletions

View File

@ -1,3 +1,17 @@
2013-04-24 Glenn Morris <rgm@gnu.org>
* emacs-lisp-intro.texi (emacsver.texi): Include it.
(copying): For non-printed versions, uses Emacs version rather
than that of the printed book.
(Complications, Lisp macro, defvar and asterisk, defcustom): Copyedits.
* Makefile.in (emacsdir): New variable..
(MAKEINFO_OPTS, ENVADD): Add $emacsdir.
(srcs): Add emacsver.texi.
(dist): Include emacsver.texi. Edit emacsdir.
* makefile.w32-in (emacsdir): New variable.
(INFO_SOURCES): Add emacsver.texi.
(ENVADD): Add $emacsdir (and $texinfodir).
2013-04-23 Xue Fuqiao <xfq.free@gmail.com> 2013-04-23 Xue Fuqiao <xfq.free@gmail.com>
* emacs-lisp-intro.texi (Complications, defvar, Writing Defuns) * emacs-lisp-intro.texi (Complications, defvar, Writing Defuns)

View File

@ -25,6 +25,8 @@ version=@version@
buildinfodir = $(srcdir)/../../info buildinfodir = $(srcdir)/../../info
# Directory with the (customized) texinfo.tex file. # Directory with the (customized) texinfo.tex file.
texinfodir = $(srcdir)/../misc texinfodir = $(srcdir)/../misc
# Directory with emacsver.texi.
emacsdir = $(srcdir)/../emacs
MKDIR_P = @MKDIR_P@ MKDIR_P = @MKDIR_P@
@ -33,17 +35,18 @@ INFO_EXT=@INFO_EXT@
INFO_OPTS=@INFO_OPTS@ INFO_OPTS=@INFO_OPTS@
MAKEINFO = @MAKEINFO@ MAKEINFO = @MAKEINFO@
MAKEINFO_OPTS = --force -I $(srcdir) MAKEINFO_OPTS = --force -I $(emacsdir) -I $(srcdir)
TEXI2DVI = texi2dvi TEXI2DVI = texi2dvi
TEXI2PDF = texi2pdf TEXI2PDF = texi2pdf
DVIPS = dvips DVIPS = dvips
ENVADD = TEXINPUTS="$(srcdir):$(texinfodir):$(TEXINPUTS)" \ ENVADD = TEXINPUTS="$(srcdir):$(texinfodir):$(emacsdir):$(TEXINPUTS)" \
MAKEINFO="$(MAKEINFO) $(MAKEINFO_OPTS)" MAKEINFO="$(MAKEINFO) $(MAKEINFO_OPTS)"
mkinfodir = @${MKDIR_P} ${buildinfodir} mkinfodir = @${MKDIR_P} ${buildinfodir}
srcs = ${srcdir}/emacs-lisp-intro.texi ${srcdir}/doclicense.texi srcs = ${srcdir}/emacs-lisp-intro.texi ${srcdir}/doclicense.texi \
${emacsdir}/emacsver.texi
.PHONY: info dvi html pdf ps .PHONY: info dvi html pdf ps
@ -97,9 +100,10 @@ dist:
rm -rf emacs-lispintro-${version} rm -rf emacs-lispintro-${version}
mkdir emacs-lispintro-${version} mkdir emacs-lispintro-${version}
cp ${srcdir}/*.texi ${srcdir}/*.eps ${srcdir}/*.pdf \ cp ${srcdir}/*.texi ${srcdir}/*.eps ${srcdir}/*.pdf \
${texinfodir}/texinfo.tex \ ${texinfodir}/texinfo.tex ${emacsdir}/emacsver.texi \
${srcdir}/ChangeLog* ${srcdir}/README emacs-lispintro-${version}/ ${srcdir}/ChangeLog* ${srcdir}/README emacs-lispintro-${version}/
sed -e 's/@sr[c]dir@/./' -e 's/^\(texinfodir *=\).*/\1 ./' \ sed -e 's/@sr[c]dir@/./' -e 's/^\(texinfodir *=\).*/\1 ./' \
-e 's/^\(emacsdir *=\).*/\1 ./' \
-e 's/^\(buildinfodir *=\).*/\1 ./' \ -e 's/^\(buildinfodir *=\).*/\1 ./' \
-e 's/^\(clean:.*\)/\1 infoclean/' \ -e 's/^\(clean:.*\)/\1 infoclean/' \
-e "s/@ver[s]ion@/${version}/" \ -e "s/@ver[s]ion@/${version}/" \

View File

@ -8,6 +8,8 @@
@syncodeindex fn cp @syncodeindex fn cp
@finalout @finalout
@include emacsver.texi
@c --------- @c ---------
@c <<<< For hard copy printing, this file is now @c <<<< For hard copy printing, this file is now
@c set for smallbook, which works for all sizes @c set for smallbook, which works for all sizes
@ -35,9 +37,9 @@
\global\hbadness=6666 % don't worry about not-too-underfull boxes \global\hbadness=6666 % don't worry about not-too-underfull boxes
@end tex @end tex
@c These refer to the printed book sold by the FSF.
@set edition-number 3.10 @set edition-number 3.10
@set update-date 28 October 2009 @set update-date 28 October 2009
@c FIXME can this be updated? -- xfq
@ignore @ignore
## Summary of shell commands to create various output formats: ## Summary of shell commands to create various output formats:
@ -227,7 +229,12 @@
This is an @cite{Introduction to Programming in Emacs Lisp}, for This is an @cite{Introduction to Programming in Emacs Lisp}, for
people who are not programmers. people who are not programmers.
@sp 1 @sp 1
@iftex
Edition @value{edition-number}, @value{update-date} Edition @value{edition-number}, @value{update-date}
@end iftex
@ifnottex
Distributed with Emacs version @value{EMACSVER}.
@end ifnottex
@ifset WWW_GNU_ORG @ifset WWW_GNU_ORG
@html @html
<p>The homepage for GNU Emacs is at <p>The homepage for GNU Emacs is at
@ -244,7 +251,7 @@ Foundation, Inc.
@iftex @iftex
Published by the:@* Published by the:@*
GNU Press, @hfill @uref{http://www.fsf.org/campaigns/gnu-press/}@* GNU Press, @hfill @uref{http://www.fsf.org/licensing/gnu-press/}@*
a division of the @hfill email: @email{sales@@fsf.org}@* a division of the @hfill email: @email{sales@@fsf.org}@*
Free Software Foundation, Inc. @hfill Tel: +1 (617) 542-5942@* Free Software Foundation, Inc. @hfill Tel: +1 (617) 542-5942@*
51 Franklin Street, Fifth Floor @hfill Fax: +1 (617) 542-2652@* 51 Franklin Street, Fifth Floor @hfill Fax: +1 (617) 542-2652@*
@ -252,10 +259,10 @@ Boston, MA 02110-1301 USA
@end iftex @end iftex
@ifnottex @ifnottex
Published by the: Printed copies available from @uref{http://shop.fsf.org/}. Published by:
@example @example
GNU Press, http://www.fsf.org/campaigns/gnu-press/ GNU Press, http://www.fsf.org/licensing/gnu-press/
a division of the email: sales@@fsf.org a division of the email: sales@@fsf.org
Free Software Foundation, Inc. Tel: +1 (617) 542-5942 Free Software Foundation, Inc. Tel: +1 (617) 542-5942
51 Franklin Street, Fifth Floor Fax: +1 (617) 542-2652 51 Franklin Street, Fifth Floor Fax: +1 (617) 542-2652
@ -264,7 +271,6 @@ Boston, MA 02110-1301 USA
@end ifnottex @end ifnottex
@sp 1 @sp 1
@c Printed copies are available from @uref{http://shop.fsf.org/} for $35 each.@*
ISBN 1-882114-43-4 ISBN 1-882114-43-4
Permission is granted to copy, distribute and/or modify this document Permission is granted to copy, distribute and/or modify this document
@ -1623,13 +1629,20 @@ do not work in the usual manner. Those that don't are called
@dfn{special forms}. They are used for special jobs, like defining a @dfn{special forms}. They are used for special jobs, like defining a
function, and there are not many of them. In the next few chapters, function, and there are not many of them. In the next few chapters,
you will be introduced to several of the more important special forms. you will be introduced to several of the more important special forms.
And there are also @dfn{macros}. Macro is a construct defined in
Lisp, which differs from a function in that it translates a Lisp
expression into another expression which is to be evaluated instead of
the original expression. (@xref{Lisp macro}.)
As well as special forms, there are also @dfn{macros}. A macro
is a construct defined in Lisp, which differs from a function in that it
translates a Lisp expression into another expression that is to be
evaluated in place of the original expression. (@xref{Lisp macro}.)
The third and final complication is this: if the function that the For the purposes of this introduction, you do not need to worry too much
about whether something is a special form, macro, or ordinary function.
For example, @code{if} is a special form (@pxref{if}), but @code{when}
is a macro (@pxref{Lisp macro}). In earlier versions of Emacs,
@code{defun} was a special form, but now it is a macro (@pxref{defun}).
It still behaves in the same way.
The final complication is this: if the function that the
Lisp interpreter is looking at is not a special form, and if it is part Lisp interpreter is looking at is not a special form, and if it is part
of a list, the Lisp interpreter looks to see whether the list has a list of a list, the Lisp interpreter looks to see whether the list has a list
inside of it. If there is an inner list, the Lisp interpreter first inside of it. If there is an inner list, the Lisp interpreter first
@ -8313,7 +8326,7 @@ an @code{if} without the possibility of an else clause. In your mind,
you can replace @code{when} with @code{if} and understand what goes you can replace @code{when} with @code{if} and understand what goes
on. That is what the Lisp interpreter does. on. That is what the Lisp interpreter does.
Technically speaking, @code{when} is a Lisp macro. A Lisp @dfn{macro} Technically speaking, @code{when} is a Lisp macro. A Lisp macro
enables you to define new control constructs and other language enables you to define new control constructs and other language
features. It tells the interpreter how to compute another Lisp features. It tells the interpreter how to compute another Lisp
expression which will in turn compute the value. In this case, the expression which will in turn compute the value. In this case, the
@ -9366,7 +9379,7 @@ In the past, Emacs used the @code{defvar} special form both for
internal variables that you would not expect a user to change and for internal variables that you would not expect a user to change and for
variables that you do expect a user to change. Although you can still variables that you do expect a user to change. Although you can still
use @code{defvar} for user customizable variables, please use use @code{defvar} for user customizable variables, please use
@code{defcustom} instead, since that special form provides a path into @code{defcustom} instead, since it provides a path into
the Customization commands. (@xref{defcustom, , Specifying Variables the Customization commands. (@xref{defcustom, , Specifying Variables
using @code{defcustom}}.) using @code{defcustom}}.)
@ -17025,7 +17038,7 @@ Finally, the @code{:group} keyword tells the Emacs Customization
command in which group the variable is located. This tells where to command in which group the variable is located. This tells where to
find it. find it.
The @code{defcustom} function recognizes more than a dozen keywords. The @code{defcustom} macro recognizes more than a dozen keywords.
For more information, see @ref{Customization, , Writing Customization For more information, see @ref{Customization, , Writing Customization
Definitions, elisp, The GNU Emacs Lisp Reference Manual}. Definitions, elisp, The GNU Emacs Lisp Reference Manual}.

View File

@ -23,10 +23,13 @@ srcdir = .
infodir = $(srcdir)/../../info infodir = $(srcdir)/../../info
# Directory with the (customized) texinfo.tex file. # Directory with the (customized) texinfo.tex file.
texinfodir = $(srcdir)/../misc texinfodir = $(srcdir)/../misc
# Directory with emacsver.texi.
emacsdir = $(srcdir)/../emacs
INFO_EXT=.info INFO_EXT=.info
INFO_OPTS=--no-split INFO_OPTS=--no-split
INFO_SOURCES = $(srcdir)/emacs-lisp-intro.texi $(srcdir)/doclicense.texi INFO_SOURCES = $(srcdir)/emacs-lisp-intro.texi $(emacsdir)/emacsver.texi \
$(srcdir)/doclicense.texi
# The file name eintr must fit within 5 characters, to allow for # The file name eintr must fit within 5 characters, to allow for
# -NN extensions to fit into DOS 8+3 limits without clashing # -NN extensions to fit into DOS 8+3 limits without clashing
INFO_TARGETS = $(infodir)/eintr$(INFO_EXT) INFO_TARGETS = $(infodir)/eintr$(INFO_EXT)
@ -37,8 +40,9 @@ INSTALL_INFO = install-info
TEXI2DVI = texi2dvi TEXI2DVI = texi2dvi
TEXI2PDF = texi2pdf TEXI2PDF = texi2pdf
DVIPS = dvips DVIPS = dvips
ENVADD = $(srcdir)\..\..\nt\envadd.bat "TEXINPUTS=$(srcdir);$(TEXINPUTS)" \ ENVADD = $(srcdir)\..\..\nt\envadd.bat \
"MAKEINFO=$(MAKEINFO) -I$(srcdir) -I$(texinfodir)" /C "TEXINPUTS=$(srcdir);$(texinfodir);$(emacsdir);$(TEXINPUTS)" \
"MAKEINFO=$(MAKEINFO) -I$(srcdir) -I$(emacsdir) -I$(texinfodir)" /C
.SUFFIXES: .dvi .ps .texi .SUFFIXES: .dvi .ps .texi