diff options
-rw-r--r-- | Changes | 3 | ||||
-rw-r--r-- | Makefile | 3 | ||||
-rw-r--r-- | Makefile.common | 2 | ||||
-rw-r--r-- | Makefile.config.in | 8 | ||||
-rw-r--r-- | api_docgen/ocamldoc/Makefile | 9 | ||||
-rw-r--r-- | api_docgen/odoc/Makefile | 13 | ||||
-rwxr-xr-x | configure | 10 | ||||
-rw-r--r-- | configure.ac | 8 | ||||
-rw-r--r-- | man/Makefile | 18 | ||||
-rw-r--r-- | man/ocaml.1 (renamed from man/ocaml.m) | 0 | ||||
-rw-r--r-- | man/ocamlc.1 (renamed from man/ocamlc.m) | 0 | ||||
-rw-r--r-- | man/ocamlc.opt.1 | 1 | ||||
-rw-r--r-- | man/ocamlcp.1 (renamed from man/ocamlcp.m) | 0 | ||||
-rw-r--r-- | man/ocamldebug.1 (renamed from man/ocamldebug.m) | 0 | ||||
-rw-r--r-- | man/ocamldep.1 (renamed from man/ocamldep.m) | 0 | ||||
-rw-r--r-- | man/ocamldoc.1 (renamed from man/ocamldoc.m) | 0 | ||||
-rw-r--r-- | man/ocamllex.1 (renamed from man/ocamllex.m) | 0 | ||||
-rw-r--r-- | man/ocamlmktop.1 (renamed from man/ocamlmktop.m) | 0 | ||||
-rw-r--r-- | man/ocamlopt.1 (renamed from man/ocamlopt.m) | 0 | ||||
-rw-r--r-- | man/ocamlopt.opt.1 | 1 | ||||
-rw-r--r-- | man/ocamloptp.1 | 1 | ||||
-rw-r--r-- | man/ocamlprof.1 (renamed from man/ocamlprof.m) | 0 | ||||
-rw-r--r-- | man/ocamlrun.1 (renamed from man/ocamlrun.m) | 0 | ||||
-rw-r--r-- | man/ocamlyacc.1 (renamed from man/ocamlyacc.m) | 0 |
24 files changed, 30 insertions, 47 deletions
@@ -257,6 +257,9 @@ Working version ### Build system: +- #10717 Simplify the installation of man mages + (Sébastien Hinderer, review by ???) + ### Bug fixes: - #9214, #10709: Wrong unmarshaling of function pointers in debugger mode. @@ -439,8 +439,7 @@ ifeq "$(INSTALL_SOURCE_ARTIFACTS)" "true" endif $(MAKE) -C tools install ifeq "$(UNIX_OR_WIN32)" "unix" # Install manual pages only on Unix - $(MKDIR) "$(INSTALL_MANDIR)/man$(PROGRAMS_MAN_SECTION)" - -$(MAKE) -C man install + $(MAKE) -C man install endif for i in $(OTHERLIBRARIES); do \ $(MAKE) -C otherlibs/$$i install || exit $$?; \ diff --git a/Makefile.common b/Makefile.common index 42fa671b61..43068151c8 100644 --- a/Makefile.common +++ b/Makefile.common @@ -33,6 +33,8 @@ INSTALL_BINDIR := $(DESTDIR)$(BINDIR) INSTALL_LIBDIR := $(DESTDIR)$(LIBDIR) INSTALL_STUBLIBDIR := $(DESTDIR)$(STUBLIBDIR) INSTALL_MANDIR := $(DESTDIR)$(MANDIR) +INSTALL_PROGRAMS_MAN_DIR := $(DESTDIR)$(PROGRAMS_MAN_DIR) +INSTALL_LIBRARIES_MAN_DIR := $(DESTDIR)$(LIBRARIES_MAN_DIR) INSTALL_DOCDIR := $(DESTDIR)$(DOCDIR) FLEXDLL_SUBMODULE_PRESENT := $(wildcard $(ROOTDIR)/flexdll/Makefile) diff --git a/Makefile.config.in b/Makefile.config.in index 6008aac04f..eb3d85eb1d 100644 --- a/Makefile.config.in +++ b/Makefile.config.in @@ -53,11 +53,11 @@ LIBDIR=@libdir@ STUBLIBDIR=@libdir@/stublibs ### Where to install the man pages -# Man pages for commands go in $(MANDIR)/man$(PROGRAMS_MAN_SECTION) -# Man pages for the library go in $(MANDIR)/man/man$(LIBRARIES_MAN_SECTION) +# Man pages for commands go in $(MANDIR)/man1 +# Man pages for the library go in $(MANDIR)/man3 MANDIR=@mandir@ -PROGRAMS_MAN_SECTION=@programs_man_section@ -LIBRARIES_MAN_SECTION=@libraries_man_section@ +PROGRAMS_MAN_DIR=$(MANDIR)/man1 +LIBRARIES_MAN_DIR=$(MANDIR)/man3 ### Do #! scripts work on your system? ### Beware: on some systems (e.g. SunOS 4), this will work only if diff --git a/api_docgen/ocamldoc/Makefile b/api_docgen/ocamldoc/Makefile index 87cd9cdb85..decc724af5 100644 --- a/api_docgen/ocamldoc/Makefile +++ b/api_docgen/ocamldoc/Makefile @@ -117,10 +117,9 @@ $(filter-out camlinternal%,$(compilerlibref)),\ build/latex/compilerlibs_input.tex: | build/latex echo $(compilerlibs_INPUT) > $@ -INSTALL_MANODIR=$(INSTALL_MANDIR)/man3 -.PHONY:install +.PHONY: install install: - $(MKDIR) "$(INSTALL_MANODIR)" + $(MKDIR) "$(INSTALL_LIBRARIES_MAN_DIR)" if test -d build/man; then \ - $(INSTALL_DATA) build/man/*.3o "$(INSTALL_MANODIR)"; \ - else : ; fi + $(INSTALL_DATA) build/man/*.3o "$(INSTALL_LIBRARIES_MAN_DIR)"; \ + fi diff --git a/api_docgen/odoc/Makefile b/api_docgen/odoc/Makefile index 5c22a15b46..1d9437ab75 100644 --- a/api_docgen/odoc/Makefile +++ b/api_docgen/odoc/Makefile @@ -181,13 +181,12 @@ $(ALL_PAGED_DOC:%=build/%.3o.stamp):build/%.3o.stamp:build/%.odocl | build/ touch $@ # Man pages are the only installed documentation -INSTALL_MANODIR=$(INSTALL_MANDIR)/man3 -.PHONY:install +.PHONY: install install: - $(MKDIR) "$(INSTALL_MANODIR)" + $(MKDIR) "$(INSTALL_LIBRARIES_MAN_DIR)" if test -d build/man/libref ; then \ - $(INSTALL_DATA) build/man/libref/* "$(INSTALL_MANODIR)"; \ - else : ; fi + $(INSTALL_DATA) build/man/libref/* "$(INSTALL_LIBRARIES_MAN_DIR)"; \ + fi if test -d build/man/compilerlibref ; then \ - $(INSTALL_DATA) build/man/libref/* "$(INSTALL_MANODIR)"; \ - else : ; fi + $(INSTALL_DATA) build/man/libref/* "$(INSTALL_LIBRARIES_MAN_DIR)"; \ + fi @@ -816,8 +816,6 @@ ccomptype mkexedebugflag mkexe fpic -libraries_man_section -programs_man_section extralibs syslib outputobj @@ -2786,12 +2784,6 @@ $as_echo "$as_me: Configuring OCaml version 4.14.0+dev0-2021-06-03" >&6;} ## Command-line arguments passed to configure CONFIGURE_ARGS="$*" -# Command-line tools section of the Unix manual -programs_man_section=1 - -# Library section of the Unix manual -libraries_man_section=3 - # Command to build executalbes # In general this command is supposed to use the CFLAGs- and LDFLAGS- # related variables (OC_CFLAGS and OC_LDFLAGS for ocaml-specific @@ -2931,8 +2923,6 @@ OCAML_VERSION_SHORT=4.14 - - # TODO: rename this variable diff --git a/configure.ac b/configure.ac index 607d992411..9d49d213c4 100644 --- a/configure.ac +++ b/configure.ac @@ -30,12 +30,6 @@ AC_MSG_NOTICE([Configuring OCaml version AC_PACKAGE_VERSION]) ## Command-line arguments passed to configure CONFIGURE_ARGS="$*" -# Command-line tools section of the Unix manual -programs_man_section=1 - -# Library section of the Unix manual -libraries_man_section=3 - # Command to build executalbes # In general this command is supposed to use the CFLAGs- and LDFLAGS- # related variables (OC_CFLAGS and OC_LDFLAGS for ocaml-specific @@ -107,8 +101,6 @@ AC_SUBST([outputexe]) AC_SUBST([outputobj]) AC_SUBST([syslib]) AC_SUBST([extralibs]) -AC_SUBST([programs_man_section]) -AC_SUBST([libraries_man_section]) AC_SUBST([fpic]) AC_SUBST([mkexe]) AC_SUBST([mkexedebugflag]) diff --git a/man/Makefile b/man/Makefile index 52d1c19f53..36d3126563 100644 --- a/man/Makefile +++ b/man/Makefile @@ -14,17 +14,13 @@ #************************************************************************** ROOTDIR = .. -include $(ROOTDIR)/Makefile.config +include $(ROOTDIR)/Makefile.common -DESTDIR ?= -INSTALL_DIR=$(DESTDIR)$(MANDIR)/man$(PROGRAMS_MAN_SECTION) +MANPAGES = $(addsuffix .1,\ + ocaml ocamlc ocamlc.opt ocamlcp ocamldebug ocamldep ocamldoc ocamllex \ + ocamlmktop ocamlopt ocamlopt.opt ocamloptp ocamlprof ocamlrun ocamlyacc) +.PHONY: install install: - for i in *.m; do cp \ - $$i $(INSTALL_DIR)/`basename $$i .m`.$(PROGRAMS_MAN_SECTION); done - echo '.so man$(PROGRAMS_MAN_SECTION)/ocamlc.$(PROGRAMS_MAN_SECTION)' \ - > $(INSTALL_DIR)/ocamlc.opt.$(PROGRAMS_MAN_SECTION) - echo '.so man$(PROGRAMS_MAN_SECTION)/ocamlopt.$(PROGRAMS_MAN_SECTION)' \ - > $(INSTALL_DIR)/ocamlopt.opt.$(PROGRAMS_MAN_SECTION) - echo '.so man$(PROGRAMS_MAN_SECTION)/ocamlcp.$(PROGRAMS_MAN_SECTION)' \ - > $(INSTALL_DIR)/ocamloptp.$(PROGRAMS_MAN_SECTION) + $(MKDIR) $(INSTALL_PROGRAMS_MAN_DIR) + $(INSTALL_DATA) $(MANPAGES) $(INSTALL_PROGRAMS_MAN_DIR) diff --git a/man/ocaml.m b/man/ocaml.1 index 9d19f1b3c5..9d19f1b3c5 100644 --- a/man/ocaml.m +++ b/man/ocaml.1 diff --git a/man/ocamlc.m b/man/ocamlc.1 index adbfe3ec8b..adbfe3ec8b 100644 --- a/man/ocamlc.m +++ b/man/ocamlc.1 diff --git a/man/ocamlc.opt.1 b/man/ocamlc.opt.1 new file mode 100644 index 0000000000..3d957b581d --- /dev/null +++ b/man/ocamlc.opt.1 @@ -0,0 +1 @@ +.so man1/ocamlc.1 diff --git a/man/ocamlcp.m b/man/ocamlcp.1 index d6c983d167..d6c983d167 100644 --- a/man/ocamlcp.m +++ b/man/ocamlcp.1 diff --git a/man/ocamldebug.m b/man/ocamldebug.1 index f03ad60f39..f03ad60f39 100644 --- a/man/ocamldebug.m +++ b/man/ocamldebug.1 diff --git a/man/ocamldep.m b/man/ocamldep.1 index 1c39e9d52a..1c39e9d52a 100644 --- a/man/ocamldep.m +++ b/man/ocamldep.1 diff --git a/man/ocamldoc.m b/man/ocamldoc.1 index ffdee529a8..ffdee529a8 100644 --- a/man/ocamldoc.m +++ b/man/ocamldoc.1 diff --git a/man/ocamllex.m b/man/ocamllex.1 index 58e0362764..58e0362764 100644 --- a/man/ocamllex.m +++ b/man/ocamllex.1 diff --git a/man/ocamlmktop.m b/man/ocamlmktop.1 index 09a4126c01..09a4126c01 100644 --- a/man/ocamlmktop.m +++ b/man/ocamlmktop.1 diff --git a/man/ocamlopt.m b/man/ocamlopt.1 index 8540a08c1e..8540a08c1e 100644 --- a/man/ocamlopt.m +++ b/man/ocamlopt.1 diff --git a/man/ocamlopt.opt.1 b/man/ocamlopt.opt.1 new file mode 100644 index 0000000000..f548264fa1 --- /dev/null +++ b/man/ocamlopt.opt.1 @@ -0,0 +1 @@ +.so man1/ocamlopt.1 diff --git a/man/ocamloptp.1 b/man/ocamloptp.1 new file mode 100644 index 0000000000..bfd9d3e31a --- /dev/null +++ b/man/ocamloptp.1 @@ -0,0 +1 @@ +.so man1/ocamlcp.1 diff --git a/man/ocamlprof.m b/man/ocamlprof.1 index 97d5671441..97d5671441 100644 --- a/man/ocamlprof.m +++ b/man/ocamlprof.1 diff --git a/man/ocamlrun.m b/man/ocamlrun.1 index 78216f2eb5..78216f2eb5 100644 --- a/man/ocamlrun.m +++ b/man/ocamlrun.1 diff --git a/man/ocamlyacc.m b/man/ocamlyacc.1 index f522d5cc26..f522d5cc26 100644 --- a/man/ocamlyacc.m +++ b/man/ocamlyacc.1 |