Commit c2c8a908 authored by Thomas Markwalder's avatar Thomas Markwalder
Browse files

[3929] pass input file path into mk_cfgrpt.sh

Added required input config report file parameter to
mk_cfgrpt.sh rather than having hard-coded by configure.

This allows cfgrpt/Makefile to pass in the pathname of
the report file it used in its "config_report.cc", as
the input report file.  In other words, we garuantee that
the file we used for change is the same file we generate
the source from.
parent 37a95664
...@@ -1495,7 +1495,6 @@ AC_CONFIG_FILES([compatcheck/Makefile ...@@ -1495,7 +1495,6 @@ AC_CONFIG_FILES([compatcheck/Makefile
src/lib/util/threads/tests/Makefile src/lib/util/threads/tests/Makefile
src/lib/util/unittests/Makefile src/lib/util/unittests/Makefile
tools/path_replacer.sh tools/path_replacer.sh
tools/mk_cfgrpt.sh
]) ])
AC_CONFIG_COMMANDS([permissions], [ AC_CONFIG_COMMANDS([permissions], [
...@@ -1514,7 +1513,6 @@ AC_CONFIG_FILES([compatcheck/Makefile ...@@ -1514,7 +1513,6 @@ AC_CONFIG_FILES([compatcheck/Makefile
chmod +x src/lib/util/python/gen_wiredata.py chmod +x src/lib/util/python/gen_wiredata.py
chmod +x src/lib/util/tests/process_spawn_app.sh chmod +x src/lib/util/tests/process_spawn_app.sh
chmod +x tools/path_replacer.sh chmod +x tools/path_replacer.sh
chmod +x tools/mk_cfgrpt.sh
]) ])
AC_OUTPUT AC_OUTPUT
......
...@@ -13,6 +13,9 @@ noinst_LTLIBRARIES = libcfgrpt.la ...@@ -13,6 +13,9 @@ noinst_LTLIBRARIES = libcfgrpt.la
nodist_libcfgrpt_la_SOURCES = config_report.cc nodist_libcfgrpt_la_SOURCES = config_report.cc
libcfgrpt_la_SOURCES = config_report.h cfgrpt.cc libcfgrpt_la_SOURCES = config_report.h cfgrpt.cc
# set pathname to the input configuration report
report_file = $(abs_top_builddir)/config.report
# Generate config_report.cc # Generate config_report.cc
config_report.cc: $(abs_top_builddir)/config.report config_report.cc: $(report_file)
$(abs_top_builddir)/tools/mk_cfgrpt.sh $(abs_top_builddir)/src/lib/cfgrpt/config_report.cc ${SHELL} $(top_srcdir)/tools/mk_cfgrpt.sh $(report_file) $(top_builddir)/src/lib/cfgrpt/config_report.cc
/path_replacer.sh /path_replacer.sh
/mk_cfgrpt.sh
...@@ -17,8 +17,8 @@ ...@@ -17,8 +17,8 @@
# Called by configure # Called by configure
# #
dest="$1" report_file="$1"
report_file="@abs_top_builddir@/config.report" dest="$2"
if [ -z ${report_file} ] if [ -z ${report_file} ]
then then
...@@ -36,7 +36,7 @@ fi ...@@ -36,7 +36,7 @@ fi
# Header # Header
cat >> $dest << END cat >> $dest << END
// config_report.cc. Generated from config.report by tools/mk_cfgrpt_header.sh // config_report.cc. Generated from config.report by tools/mk_cfgrpt.sh
namespace isc { namespace isc {
namespace detail { namespace detail {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment