fix Makefile bugs, improve make help quick_www www, status.html formation

Fixed errors in `1991/davidguy/Makefile`, `2000/bmeyer/Makefile`
and `2012/kang/Makefile` where a multi-line `CSILENCE` make variable
was not properly continued onto the next line.

Improve the output of `make quick_www` and `make www` no be less
verbose and more informative.  Doing this allowed us to uncover
some bugs in the above mentioned entry Makefiles.

The `make quick_www` and `make www` no longer perform a
`make gen_status`.

The `make gen_top_html` rule, via `bin/gen-top-html.sh` will form
`status.html` based solely on the contents of `status.md`.  Only
the `make gen_status` rule will modify `status.md` if needed, and
then rebuild `status.html` if needed.

The `status.html` file was updated to reflect the common way that
`make gen_top_html` forms this file.  The `make timestamp` performs
a `make gen_top_html` after running `make gen_status` so that the
resulting  `status.html` file matches what `make quick_www` and
`make www` would produce.

Changed `bin/gen-top-html.sh` VERSION from "1.4.5 2024-05-19"
to "1.4.6 2024-05-24" to perform the above.

Improved the text written by `make help`.

Added "for $TOOL" to the debug output of `bin/all-run.sh` to
help identify the tool performing the action.

Changed `bin/all-run.sh` VERSION from "1.3.3 2024-04-13"
to "1.3.4 2024-05-24" to perform the above.

Moved `make gen_other_html` after `make entry_index` and after the
`make quick_entry_index` in `make quick_www` and `make www`.

Perform `make quick_www` to perform the above and test under macOS.

Perform `make www` to perform the above and test under macOS.
This commit is contained in:
Landon Curt Noll committed 2024-05-24 16:31:36 -07:00
1 parent 578651ecf4
commit 36ab67dfd3
7 files changed
+96 -54

No files matched your search

+1 -1
View File
@@ -43,7 +43,7 @@ CSILENCE= -Wno-bitwise-op-parentheses -Wno-error -Wno-implicit-function-declarat
-Wno-deprecated-non-prototype -Wno-implicit-int \ -Wno-deprecated-non-prototype -Wno-implicit-int \
-Wno-deprecated-declarations -Wno-incompatible-pointer-types \ -Wno-deprecated-declarations -Wno-incompatible-pointer-types \
-Wno-maybe-uninitialized -Wno-misleading-indentation \ -Wno-maybe-uninitialized -Wno-misleading-indentation \
-Wno-missing-parameter-type -Wno-parentheses -Wno-strict-aliasing -Wno-missing-parameter-type -Wno-parentheses -Wno-strict-aliasing \
-Wno-unused-value -Wno-unused-value
# Common C compiler warning flags # Common C compiler warning flags
+1 -1
View File
@@ -39,7 +39,7 @@ include ../../var.mk
# Common C compiler warnings to silence # Common C compiler warnings to silence
# #
CSILENCE= -Wno-format -Wno-parentheses -Wno-string-plus-int \ CSILENCE= -Wno-format -Wno-parentheses -Wno-string-plus-int \
-Wno-strict-prototypes -Wno-int-in-bool-context -Wno-strict-prototypes -Wno-int-in-bool-context \
-Wno-misleading-indentation -Wno-misleading-indentation
# Common C compiler warning flags # Common C compiler warning flags
+2 -2
View File
@@ -38,8 +38,8 @@ include ../../var.mk
# Common C compiler warnings to silence # Common C compiler warnings to silence
# #
CSILENCE= -Wno-bitwise-op-parentheses -Wno-error CSILENCE= -Wno-bitwise-op-parentheses -Wno-error \
-Wno-implicit-function-declaration -Wno-implicit-int -Wno-int-conversion -Wno-implicit-function-declaration -Wno-implicit-int -Wno-int-conversion \
-Wno-pointer-to-int-cast -Wno-deprecated-non-prototype -Wno-pointer-to-int-cast -Wno-deprecated-non-prototype
# Common C compiler warning flags # Common C compiler warning flags
+82 -41
View File
@@ -179,7 +179,6 @@ diff_orig_alt:
done done
@echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-=' @echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-='
# diff alt and orig
diff_alt_orig: diff_alt_orig:
@echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-=' @echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-='
@-for i in ${YEARS}; do \ @-for i in ${YEARS}; do \
@@ -259,34 +258,58 @@ indent.c:
# here! # here!
# #
help: help:
@echo "make genpath - form top level .top, YYYY level .year and winner .path files" @echo '# Rules for those who wish to expore the winning IOCCC entries:'
@echo "make genfilelist - generate YYYY level .filelist"
@echo "make verify_entry_files - check to be sure all files in all entries exist"
@echo "make sort_gitignore - sort .gitignore files according to rules in bin/sgi.sh"
@echo "make gen_authors - generate the top level authors.html page"
@echo "make gen_location - generate the top level location.html page"
@echo "make gen_years - generate the top level years.html page"
@echo "make entry_index - force the build of ALL winner index.html files"
@echo "make gen_other_html - build entry HTML files from markdown other than README.md"
@echo "make gen_year_index - generate year level index.html files using the"
@echo "make gen_top_html - generate a number of the top level HTML files from markdown"
@echo "make gen_status - generate status.json and status.html"
@echo "make quick_entry_index - build winner index.html files that might be out of date"
@echo "make find_missing_links - find markdown links to missing local files"
@echo "make quick_www - generate html files more quickly, checking timestamps"
@echo "make www - build html pages for web site"
@echo @echo
@echo "make untar_entry_tarball - untar all entry tarballs" @echo 'make clobber - Remove all temprary, compiled and constructed files from all winning IOCCC entries'
@echo "make untar_year_tarball - untar all year level tarballs" @echo 'make all - Compile all winning IOCCC entries'
@echo @echo
@echo "make form_entry_tarball - form all entry compressed tarballs" @echo 'make alt - Compile all alternative executables for winning IOCCC entries'
@echo "make form_year_tarball - form all IOCCC year level compressed tarballs" @echo 'make everything - make all and make alt'
@echo "make tar - build all tarballs"
@echo @echo
@echo "make gen_sitemap - generate the XML sitemap" @echo 'make diff_orig_prog - diff original source and current source'
@echo "make timestamp - generate things with timestamps (status, sitemap etc.)" @echo 'make diff_prog_orig - diff current source and original source'
@echo @echo
@echo "make update - update everything on the web site" @echo 'make diff_alt_prog - diff alternative source and current source'
@echo 'make diff_prog_alt - diff current source and alternative source'
@echo
@echo 'make diff_alt_orig - diff alternative source and original source'
@echo 'make diff_orig_alt - diff original source and alternative source'
@echo
@echo '# Rules for building a local copy of the IOCCC web site:'
@echo
@echo 'make genpath - form top level .top, YYYY level .year and winner .path files'
@echo 'make genfilelist - generate YYYY level .filelist'
@echo 'make verify_entry_files - check to be sure all files in all entries exist'
@echo 'make sort_gitignore - sort .gitignore files according to rules in bin/sgi.sh'
@echo 'make gen_authors - generate the top level authors.html page'
@echo 'make gen_location - generate the top level location.html page'
@echo 'make gen_years - generate the top level years.html page'
@echo 'make entry_index - force the build of ALL winner index.html files'
@echo 'make gen_other_html - build entry HTML files from markdown other than README.md'
@echo 'make gen_year_index - generate year level index.html files using the'
@echo 'make gen_top_html - generate a number of the top level HTML files from markdown'
@echo 'make quick_entry_index - build winner index.html files that might be out of date'
@echo 'make find_missing_links - find markdown links to missing local files'
@echo
@echo '# Compound make rules for building a local copy of the IOCCC web site:'
@echo
@echo 'make quick_www - generate html files more quickly, checking timestamps'
@echo 'make www - build html pages for web site'
@echo
@echo '# Rules that are useful only for those IOCCC judges who mainain the official IOCCC web site:'
@echo
@echo 'make untar_entry_tarball - untar all entry tarballs'
@echo 'make untar_year_tarball - untar all year level tarballs'
@echo
@echo 'make form_entry_tarball - form all entry compressed tarballs'
@echo 'make form_year_tarball - form all IOCCC year level compressed tarballs'
@echo 'make tar - build all tarballs'
@echo
@echo 'make gen_status - generate status.json and status.html'
@echo 'make gen_sitemap - generate the XML sitemap'
@echo 'make timestamp - generate things with timestamps (status, sitemap etc.)'
@echo
@echo 'make update - update everything in a local copy of the web site'
# form the top level .top, YYYY level .year and winner level .path files # form the top level .top, YYYY level .year and winner level .path files
# #
@@ -302,7 +325,6 @@ genpath:
done done
@-if ${CMP} -s .tmp.genpath .top; then \ @-if ${CMP} -s .tmp.genpath .top; then \
${RM} -f .tmp.genpath; \ ${RM} -f .tmp.genpath; \
echo ".top already up to date"; \
else \ else \
${MV} -f .tmp.genpath .top; \ ${MV} -f .tmp.genpath .top; \
${CHMOD} 0444 .top; \ ${CHMOD} 0444 .top; \
@@ -323,7 +345,6 @@ genfilelist:
${SORT} -f -d -u > "$$i/.genfilelist.tmp"; \ ${SORT} -f -d -u > "$$i/.genfilelist.tmp"; \
if ${CMP} -s "$$i/.genfilelist.tmp" "$$i/.filelist"; then \ if ${CMP} -s "$$i/.genfilelist.tmp" "$$i/.filelist"; then \
${RM} -f "$$i/.genfilelist.tmp"; \ ${RM} -f "$$i/.genfilelist.tmp"; \
echo "$$i/.filelist already up to date"; \
else \ else \
${MV} -f "$$i/.genfilelist.tmp" "$$i/.filelist"; \ ${MV} -f "$$i/.genfilelist.tmp" "$$i/.filelist"; \
${CHMOD} 0444 "$$i/.filelist"; \ ${CHMOD} 0444 "$$i/.filelist"; \
@@ -336,14 +357,14 @@ genfilelist:
# #
verify_entry_files: ${ALL_RUN} ${CHK_ENTRY} verify_entry_files: ${ALL_RUN} ${CHK_ENTRY}
@echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-=' @echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-='
${ALL_RUN} -v 3 ${CHK_ENTRY} ${ALL_RUN} -v 1 ${CHK_ENTRY}
@echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-=' @echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-='
# sort .gitignore files according to rules in bin/sgi.sh # sort .gitignore files according to rules in bin/sgi.sh
# #
sort_gitignore: ${ALL_RUN} ${SORT_GITIGNORE} sort_gitignore: ${ALL_RUN} ${SORT_GITIGNORE}
@echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-=' @echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-='
${ALL_RUN} -v 3 ${SORT_GITIGNORE} -v 1 ${ALL_RUN} -v 1 ${SORT_GITIGNORE} -v 1
@echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-=' @echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-='
# generate the top level authors.html page using the # generate the top level authors.html page using the
@@ -452,9 +473,15 @@ find_missing_links:
# Well, short of pushing changes to the GitHub repo, that is. :-) # Well, short of pushing changes to the GitHub repo, that is. :-)
# #
quick_www: quick_www:
@echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-=' @echo '=-=-=-=-=-= IOCCC begin make $@ =-=-=-=-=-='
${MAKE} clobber @echo '=-=-=-=-= IOCCC begin make clobber =-=-=-=-='
${MAKE} genpath @echo '... hiding verbose output on stdout ...'
@${MAKE} clobber >/dev/null
@echo '=-=-=-=-= IOCCC complete make clobber =-=-=-=-='
@echo '=-=-=-=-= IOCCC begin make genpath =-=-=-=-='
@echo '... hiding verbose output on stdout ...'
@${MAKE} genpath >/dev/null
@echo '=-=-=-=-= IOCCC complete make genpath =-=-=-=-='
${MAKE} genfilelist ${MAKE} genfilelist
${MAKE} verify_entry_files ${MAKE} verify_entry_files
${MAKE} sort_gitignore ${MAKE} sort_gitignore
@@ -462,21 +489,34 @@ quick_www:
${MAKE} gen_location ${MAKE} gen_location
${MAKE} gen_years ${MAKE} gen_years
${MAKE} gen_year_index ${MAKE} gen_year_index
${MAKE} gen_other_html
${MAKE} gen_top_html ${MAKE} gen_top_html
${MAKE} gen_status
${MAKE} quick_entry_index ${MAKE} quick_entry_index
${MAKE} gen_other_html
${MAKE} find_missing_links ${MAKE} find_missing_links
@echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-=' @echo '=-=-=-=-=-= IOCCC complete make $@ =-=-=-=-=-='
foo:
@echo '=-=-=-=-=-= IOCCC begin make $@ =-=-=-=-=-='
@echo '=-=-=-=-= IOCCC begin make sort_gitignore =-=-=-=-='
@echo '... hiding verbose output on stdout ...'
@${MAKE} sort_gitignore >/dev/null
@echo '=-=-=-=-= IOCCC complete make sort_gitignore =-=-=-=-='
@echo '=-=-=-=-=-= IOCCC complete make $@ =-=-=-=-=-='
# do everything needed to build HTML content for the web site # do everything needed to build HTML content for the web site
# #
# Well, short of pushing changes to the GitHub repo, that is. :-) # Well, short of pushing changes to the GitHub repo, that is. :-)
# #
www: www:
@echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-=' @echo '=-=-=-=-=-= IOCCC begin make $@ =-=-=-=-=-='
${MAKE} clobber @echo '=-=-=-=-= IOCCC begin make clobber =-=-=-=-='
${MAKE} genpath @echo '... hiding verbose output on stdout ...'
@${MAKE} clobber >/dev/null
@echo '=-=-=-=-= IOCCC complete make clobber =-=-=-=-='
@echo '=-=-=-=-= IOCCC begin make genpath =-=-=-=-='
@echo '... hiding verbose output on stdout ...'
@${MAKE} genpath >/dev/null
@echo '=-=-=-=-= IOCCC complete make genpath =-=-=-=-='
${MAKE} genfilelist ${MAKE} genfilelist
${MAKE} verify_entry_files ${MAKE} verify_entry_files
${MAKE} sort_gitignore ${MAKE} sort_gitignore
@@ -484,12 +524,11 @@ www:
${MAKE} gen_location ${MAKE} gen_location
${MAKE} gen_years ${MAKE} gen_years
${MAKE} gen_year_index ${MAKE} gen_year_index
${MAKE} gen_other_html
${MAKE} gen_top_html ${MAKE} gen_top_html
${MAKE} gen_status
${MAKE} entry_index ${MAKE} entry_index
${MAKE} gen_other_html
${MAKE} find_missing_links ${MAKE} find_missing_links
@echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-=' @echo '=-=-=-=-=-= IOCCC complete make $@ =-=-=-=-=-='
# untar all entry tarballs # untar all entry tarballs
# #
@@ -537,6 +576,7 @@ tar:
# #
gen_status: ${GEN_STATUS} gen_status: ${GEN_STATUS}
@echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-=' @echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-='
${MAKE} gen_top_html
${GEN_STATUS} -v 1 ${GEN_STATUS} -v 1
@echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-=' @echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-='
@@ -552,6 +592,7 @@ gen_sitemap sitemap: ${GEN_SITEMAP}
timestamp: timestamp:
@echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-=' @echo '=-=-=-=-= IOCCC begin make $@ =-=-=-=-='
${MAKE} gen_status ${MAKE} gen_status
${MAKE} gen_top_html
${MAKE} gen_sitemap ${MAKE} gen_sitemap
@echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-=' @echo '=-=-=-=-= IOCCC complete make $@ =-=-=-=-='
+3 -3
View File
@@ -113,7 +113,7 @@ shopt -s globstar # enable ** to match all files and zero or more directories an
# set variables referenced in the usage message # set variables referenced in the usage message
# #
export VERSION="1.3.3 2024-04-13" export VERSION="1.3.4 2024-05-24"
NAME=$(basename "$0") NAME=$(basename "$0")
export NAME export NAME
export V_FLAG=0 export V_FLAG=0
@@ -446,7 +446,7 @@ for YYYY in $(< "$TOP_FILE"); do
# debug YYYY # debug YYYY
# #
if [[ $V_FLAG -ge 1 ]]; then if [[ $V_FLAG -ge 1 ]]; then
echo "$0: debug[1]: starting to process year: $YYYY" 1>&2 echo "$0: debug[1]: for $TOOL: starting to process year: $YYYY" 1>&2
fi fi
# verify that YYYY is a readable directory # verify that YYYY is a readable directory
@@ -506,7 +506,7 @@ for YYYY in $(< "$TOP_FILE"); do
# debug YYYY # debug YYYY
# #
if [[ $V_FLAG -ge 3 ]]; then if [[ $V_FLAG -ge 3 ]]; then
echo "$0: debug[3]: starting to process year/dir: $YYYY_DIR" 1>&2 echo "$0: debug[3]: for $TOOL: starting to process year/dir: $YYYY_DIR" 1>&2
fi fi
# parse YYYY_DIR # parse YYYY_DIR
+2 -1
View File
@@ -93,7 +93,7 @@ shopt -s globstar # enable ** to match all files and zero or more directories an
# set variables referenced in the usage message # set variables referenced in the usage message
# #
export VERSION="1.4.5 2024-05-19" export VERSION="1.4.6 2024-05-24"
NAME=$(basename "$0") NAME=$(basename "$0")
export NAME export NAME
export V_FLAG=0 export V_FLAG=0
@@ -135,6 +135,7 @@ TOP_MD_SET+=("next/README")
TOP_MD_SET+=("next/guidelines") TOP_MD_SET+=("next/guidelines")
TOP_MD_SET+=("next/rules") TOP_MD_SET+=("next/rules")
TOP_MD_SET+=("nojs-menu") TOP_MD_SET+=("nojs-menu")
TOP_MD_SET+=("status")
TOP_MD_SET+=("thanks-for-help") TOP_MD_SET+=("thanks-for-help")
declare -ag TOP_MD_SELECT_SET declare -ag TOP_MD_SELECT_SET
# #
+5 -5
View File
@@ -25,14 +25,14 @@
<!-- END: this line ends content from: inc/head.default.html --> <!-- END: this line ends content from: inc/head.default.html -->
<!-- --> <!-- -->
<!-- This web page was formed via the tool: bin/gen-status.sh --> <!-- This web page was formed via the tool: bin/gen-top-html.sh -->
<!-- The main section of this web page came from JSON and other data files --> <!-- The content of main section of this web page came from: status.md -->
<!-- --> <!-- -->
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> <!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<!-- The main section of this web page was generated via the tool: bin/gen-status.sh --> <!-- !!! Do not modify this web page, instead modify the file: status.md !!! -->
<!-- The main section of this web page was generated via the tool: bin/gen-status.sh --> <!-- !!! Do not modify this web page, instead modify the file: status.md !!! -->
<!-- The main section of this web page was generated via the tool: bin/gen-status.sh --> <!-- !!! Do not modify this web page, instead modify the file: status.md !!! -->
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> <!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<!-- Markdown content was converted into HTML via the tool: bin/md2html.sh --> <!-- Markdown content was converted into HTML via the tool: bin/md2html.sh -->