Skip to content

Commit

Permalink
Remove makefile.local functionality
Browse files Browse the repository at this point in the history
Remove makefile.local functionality in the Makefiles as this can cause
compilation problems and the purpose of the file is no longer needed. Should one
really want to override things they can pass it at the command line manually.
This change means that the jparse_bug_report.sh script has been updated as
well. This problem actually caused the mess of commits
bcb793e and the commit that rolled it back,
bcb793e, as when trying to fix a mess in
another repo that used it, by accident it was pushed to this repo, undoing fixes
from yesterday.
  • Loading branch information
xexyl committed Nov 19, 2024
1 parent 1806bce commit ef45fa8
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 91 deletions.
12 changes: 12 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,18 @@
# Significant changes in the JSON parser repo


## Release 2.1.4 2024-11-19

Remove `makefile.local` functionality in the Makefiles as this can cause
compilation problems and the purpose of the file is no longer needed. Should one
really want to override things they can pass it at the command line manually.
This change means that the `jparse_bug_report.sh` script has been updated as
well. This problem actually caused the mess of commits
bcb793e7d996da45fa9d47ae70084c9294eb1f2c and the commit that rolled it back,
bcb793e7d996da45fa9d47ae70084c9294eb1f2c, as when trying to fix a mess in
another repo that used it, by accident it was pushed to this repo, undoing fixes
from yesterday.

## Release 2.1.3 2024-11-18

Improve function `parse_json_str()` and `parse_json()` by allowing for empty or
Expand Down
17 changes: 0 additions & 17 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -424,23 +424,6 @@ TMP_BUILD_LOG= ".build.log.$$$$"
BUILD_LOG= build.log


############################################################
# User specific configurations - override Makefile values #
############################################################

# The directive below retrieves any user specific configurations from makefile.local.
#
# The - before include means it's not an error if the file does not exist.
#
# We put this directive just before the first all rule so that you may override
# or modify any of the above Makefile variables. To override a value, use := symbols.
# For example:
#
# CC:= gcc
#
-include makefile.local


###########################################
# all rule - default rule - must be first #
###########################################
Expand Down
59 changes: 4 additions & 55 deletions jparse_bug_report.sh
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,8 @@ export TOOLS="
verge
"

# we need this to find overriding makefile.local in all directories to see if
# the user is overriding any Makefile. As well, we check if the directory even
# is searchable and has a Makefile.
# We need to verify that certain subdirectories, in particular
# test_jparse/, are searchable and have a readable Makefile.
export SUBDIRS="
test_jparse
"
Expand All @@ -80,7 +79,7 @@ if [[ -z "$MAKE" ]]; then
fi
export MAKE
export MAKE_FLAGS="V=@ S=@ Q= E=@ I= Q_V_OPTION=1 INSTALL_V='-v' MAKE_CD_Q="
export BUG_REPORT_VERSION="2.0.1 2024-11-16"
export BUG_REPORT_VERSION="2.0.2 2024-11-19"
export FAILURE_SUMMARY=
export NOTICE_SUMMARY=
export DBG_LEVEL="0"
Expand Down Expand Up @@ -1468,7 +1467,7 @@ if [[ -z "$T_FLAG" ]]; then
# ...and yes, this actually happened by chance, not deliberately, at least
# in the mkiocccentry repo. Later on, after this script in jparse was
# updated to be correct, the numbers were kept the same even after the tools
# that were unneeded were removed.
# that were unneeded were removed, due to the 'significance' of 42.
run_check 42 "$MAKE $MAKE_FLAGS all"

# make test: run the jparse test suite
Expand Down Expand Up @@ -1638,56 +1637,6 @@ for d in $SUBDIRS; do
done
write_echo ""

# check for makefile.local files to see if user is overriding any rules or variables.
#
# NOTE: we don't use run_check for this because it's not an actual error whether
# or not the user has a makefile.local file. What matters is the contents of it
# if they do have one.
#
write_echo "## CHECKING IF \"makefile.local\" EXISTS"
if [[ -e "./makefile.local" ]]; then
if [[ -r "./makefile.local" ]]; then
write_echo "### Warning: found \"Makefile\" overriding file \"makefile.local\":"
write_echo "RUNNING: \"cat ./makefile.local\""
write_echo "--"
if [[ -z "$L_FLAG" ]]; then
# tee -a -- "$LOGFILE" < makefile.local
< makefile.local tee -a -- "$LOGFILE"
else
cat makefile.local >> "$LOGFILE"
fi
write_echo "--"
else
write_echo "### Warning: found unreadable \"makefile.local\""
fi
else
write_echo "# \"Makefile\" has no overriding \"makefile.local\""
fi
write_echo ""

# now do the same for subdirectories
for d in $SUBDIRS; do
if [[ -e "$d/makefile.local" ]]; then
if [[ -r "$d/makefile.local" ]]; then
write_echo "### Warning: found \"$d/Makefile\" overriding file \"$d/makefile.local\":"
write_echo "--"
if [[ -z "$L_FLAG" ]]; then
# tee -a -- "$LOGFILE" < makefile.local
< "$d/makefile.local" tee -a -- "$LOGFILE"
else
cat "$d/makefile.local" >> "$LOGFILE"
fi
write_echo "--"
else
write_echo "### Warning: found unreadable \"$d/makefile.local\""
fi
else
write_echo "# \"$d/Makefile\" has no overriding \"$d/makefile.local\""
fi
done
write_echo ""


# check if there are any local modifications to the code
#
# NOTE: We don't use run_check for this because if git does not exist for some
Expand Down
18 changes: 0 additions & 18 deletions test_jparse/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -303,24 +303,6 @@ ALL_OTHER_TARGETS= ${SH_TARGETS} extern_everything
#
TARGETS= ${PROG_TARGETS}


############################################################
# User specific configurations - override Makefile values #
############################################################

# The directive below retrieves any user specific configurations from makefile.local.
#
# The - before include means it's not an error if the file does not exist.
#
# We put this directive just before the first all rule so that you may override
# or modify any of the above Makefile variables. To override a value, use := symbols.
# For example:
#
# CC:= gcc
#
-include makefile.local


######################################
# all - default rule - must be first #
######################################
Expand Down
2 changes: 1 addition & 1 deletion version.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
*
* NOTE: this should match the latest Release string in CHANGES.md
*/
#define JPARSE_REPO_VERSION "2.1.3 2024-11-18" /* format: major.minor YYYY-MM-DD */
#define JPARSE_REPO_VERSION "2.1.4 2024-11-19" /* format: major.minor YYYY-MM-DD */

/*
* official jparse version
Expand Down

0 comments on commit ef45fa8

Please sign in to comment.