1 .PHONY : texinfo-all-menus-update
5 local-WWW-2: $(addprefix $(outdir)/,$(TEXI_FILES:.texi=.html))
7 local-doc: $(OUTTXT_FILES)
9 check-info: texinfo-all-menus-update
12 local-install: install-info
13 local-uninstall: uninstall-info
14 install-info: local-install-info
15 uninstall-info: local-uninstall-info
17 install-info: $(INFO_FILES)
18 $(INFO_INSTALL_COMMAND) local-install
21 $(INFO_INSTALL_COMMAND) local-uninstall
27 else # $(INFO_FILES) non empty
28 # There are two modes for info: with and without images.
31 # This builds all .info targets with images, in out-www.
32 # Viewable with a recent Emacs, doing: C-u C-h i out-www/lilypond.info
34 local-install-info: info
35 -$(INSTALL) -d $(DESTDIR)$(infodir)
36 ifneq ($(patsubst %/local,%,$(DESTDIR)$(prefix)),/usr)
37 ## Can not have absolute symlinks because some binary packages build schemes
38 ## install files in nonstandard root. Best we can do is to notify the
39 ## builder or packager.
41 @echo "***************************************************************"
42 @echo "Please add or update the LilyPond direntries, do"
44 @echo " install-info --info-dir=$(infodir) $(outdir)/$(MAIN_INFO_DOC).info"
46 @echo "For images in the INFO docs to work, do: "
48 @echo " (cd $(infodir) && ln -sfT ../doc/lilypond/html/$(DEST_INFO_IMAGES_SUBDIR) $(INFO_IMAGES_DIR))"
49 @echo "or add something like that to the postinstall script."
51 else # installing directly into standard /usr/...
52 -$(INSTALL) -d $(DESTDIR)$(infodir)
53 $(foreach f,$(INFO_FILES),install-info --remove --info-dir=$(infodir) $(f) ; )true
54 install-info --info-dir=$(infodir) $(outdir)/$(MAIN_INFO_DOC).info
55 cd $(infodir) && ln -sfT $(webdir)/$(DEST_INFO_IMAGES_SUBDIR) $(INFO_IMAGES_DIR)
56 endif # installing directly into standard /usr/...
59 rm -f $(infodir)/$(INFO_IMAGES_DIR)
63 local-install-info: info
64 -$(INSTALL) -d $(DESTDIR)$(package_infodir)
65 ifneq ($(patsubst %/local,%,$(DESTDIR)$(prefix)),/usr)
66 ## Can not have absolute symlinks because some binary packages build schemes
67 ## install files in nonstandard root. Best we can do is to notify the
68 ## builder or packager.
70 @echo "***************************************************************"
71 @echo "Please add or update the LilyPond direntries, do"
73 @echo " install-info --info-dir=$(infodir) out/$(MAIN_INFO_DOC).info"
75 @echo "For images in the INFO docs to work, do"
77 @echo " make out=www install-info "
79 @echo "and read the extra instructions."
81 else # installing directly into standard /usr/...
82 -$(INSTALL) -d $(DESTDIR)$(infodir)
83 $(foreach f,$(INFO_FILES),install-info --remove --info-dir=$(infodir) $(f) ; )true
84 install-info --info-dir=$(infodir) $(outdir)/$(MAIN_INFO_DOC).info
86 @echo "***************************************************************"
87 @echo "For images in the INFO docs to work, do"
89 @echo " make out=www install-info "
91 endif # installing into standard /usr/* root# installing into /usr/...
95 endif # $(INFO_FILES) non empty
97 TEXINFO_ALL_MENUS_UPDATE_EL ='\
99 (version-control nil))\
100 (load-library "texinfo")\
102 (texinfo-all-menus-update)\
103 (if (buffer-modified-p (current-buffer))\
107 # buffer-modified-p is ALWAYS true, even if there were no actual
108 # changes, so we try setting origal (timestamp) back if there
111 # ugh: emacs20.7 batch mode is not really batch:
113 # answer `echo q' to the question:
114 # FILE locked by EMAIL (pid PID): (s, q, p, ?)?
116 texinfo-all-menus-update:
117 -$(foreach i, $(TEXINFO_SOURCES), echo q | emacs --batch --no-site-file $(i) --eval $(TEXINFO_ALL_MENUS_UPDATE_EL); )
118 $(foreach i, $(sort $(TEXINFO_SOURCES)), if diff -u $(i)~ $(i); then mv $(i)~ $(i); fi && ) true
120 local-help: local-texinfo-help
124 info [out=www] update Info documentation (use \`out=www' for having images)\n\
125 install-info [out=www] install Info documentation (idem)\n\
126 texinfo-all-menus-update update node menus in Texinfo source files (use with caution)\n"