diff --git a/Makefile.maint b/Makefile.maint index b242b67ae..a27690d3e 100644 --- a/Makefile.maint +++ b/Makefile.maint @@ -75,6 +75,7 @@ syntax-check-rules = \ sc_dd_max_sym_length \ sc_error_exit_success \ sc_file_system \ + sc_obsolete_symbols \ sc_prohibit_atoi_atof \ sc_prohibit_jm_in_m4 \ sc_root_tests \ @@ -147,6 +148,13 @@ sc_file_system: 'rewrite to use "file system"' 1>&2; \ exit 1; } || : +sc_obsolete_symbols: + @( $(CVS_LIST) ) > /dev/null 2>&1 || : && \ + grep -E '\<(HAVE_(FCNTL|UNISTD)_H)\>' \ + $$($(CVS_LIST) | grep -vEf .x-$@ ) && \ + { echo '$(ME): do not use HAVE_FCNTL_H or HAVE_UNISTD_H' \ + 1>&2; exit 1; } || : + # FIXME: warn about definitions of EXIT_FAILURE, EXIT_SUCCESS, STREQ # Each nonempty line must start with a year number, or a TAB.