Hi! What make html does for COBOL is quite inconsistent with all other FEs. Normally make html creates HTML/gcc-15.0.1/ subdirectory and puts there subdirectories like gcc, cpp, gccint, gfortran etc. and only those contain *.html files. COBOL puts gcobol.html and gcobol-io.html into the current directory instead.
The following patch puts them into $(build_htmldir)/gcobol/ directory. Tested on x86_64-linux with make html, ok for trunk? 2025-04-07 Jakub Jelinek <ja...@redhat.com> PR web/119227 * Make-lang.in (GCOBOL_HTML_FILES): New variable. (cobol.install-html, cobol.html, cobol.srchtml): Use $(GCOBOL_HTML_FILES) instead of gcobol.html gcobol-io.html. (gcobol.html): Rename goal to ... ($(build_htmldir)/gcobol/gcobol.html): ... this. Run mkinstalldirs. (gcobol-io.html): Rename goal to ... ($(build_htmldir)/gcobol/gcobol-io.html): ... this. Run mkinstalldirs. --- gcc/cobol/Make-lang.in.jj 2025-03-31 21:26:51.107135693 +0200 +++ gcc/cobol/Make-lang.in 2025-04-07 12:19:59.451852320 +0200 @@ -40,6 +40,8 @@ GCOBOL_TARGET_INSTALL_NAME := $(target_n GCOBC_INSTALL_NAME := $(shell echo gcobc|sed '$(program_transform_name)') GCOBC_TARGET_INSTALL_NAME := $(target_noncanonical)-$(shell echo gcobc|sed '$(program_transform_name)') +GCOBOL_HTML_FILES = $(addprefix $(build_htmldir)/gcobol/,gcobol.html gcobol-io.html) + cobol: cobol1$(exeext) cobol.serial = cobol1$(exeext) .PHONY: cobol @@ -303,8 +305,8 @@ cobol.install-pdf: installdirs gcobol.pd cobol.install-plugin: -cobol.install-html: installdirs gcobol.html gcobol-io.html - $(INSTALL_DATA) gcobol.html gcobol-io.html $(DESTDIR)$(htmldir)/ +cobol.install-html: installdirs $(GCOBOL_HTML_FILES) + $(INSTALL_DATA) $(GCOBOL_HTML_FILES) $(DESTDIR)$(htmldir)/ cobol.info: cobol.srcinfo: @@ -323,14 +325,16 @@ gcobol-io.pdf: $(srcdir)/cobol/gcobol.3 groff -mdoc -T pdf $^ > $@~ @mv $@~ $@ -cobol.html: gcobol.html gcobol-io.html -cobol.srchtml: gcobol.html gcobol-io.html +cobol.html: $(GCOBOL_HTML_FILES) +cobol.srchtml: $(GCOBOL_HTML_FILES) ln $^ $(srcdir)/cobol/ -gcobol.html: $(srcdir)/cobol/gcobol.1 +$(build_htmldir)/gcobol/gcobol.html: $(srcdir)/cobol/gcobol.1 + $(mkinstalldirs) $(build_htmldir)/gcobol mandoc -T html $^ > $@~ @mv $@~ $@ -gcobol-io.html: $(srcdir)/cobol/gcobol.3 +$(build_htmldir)/gcobol/gcobol-io.html: $(srcdir)/cobol/gcobol.3 + $(mkinstalldirs) $(build_htmldir)/gcobol mandoc -T html $^ > $@~ @mv $@~ $@ Jakub