summaryrefslogtreecommitdiffstats
path: root/bootstrap
diff options
context:
space:
mode:
authorKyle Edwards <kyle.edwards@kitware.com>2023-07-21 16:01:01 (GMT)
committerKyle Edwards <kyle.edwards@kitware.com>2023-07-26 14:07:38 (GMT)
commit93ed53790cb1e2d5f25f26156ee5c6590b0d3150 (patch)
tree7171d8558870456485ac3d2be589952c23febccc /bootstrap
parent8129bf85edea4ab6646b14687134b5a7dc5b23a5 (diff)
downloadCMake-93ed53790cb1e2d5f25f26156ee5c6590b0d3150.zip
CMake-93ed53790cb1e2d5f25f26156ee5c6590b0d3150.tar.gz
CMake-93ed53790cb1e2d5f25f26156ee5c6590b0d3150.tar.bz2
bootstrap: Unconditionally build libjsoncpp
Diffstat (limited to 'bootstrap')
-rwxr-xr-xbootstrap55
1 files changed, 24 insertions, 31 deletions
diff --git a/bootstrap b/bootstrap
index cc60425..82c5957 100755
--- a/bootstrap
+++ b/bootstrap
@@ -414,6 +414,7 @@ CMAKE_CXX_SOURCES="\
cmInstallTargetGenerator \
cmInstallTargetsCommand \
cmInstalledFile \
+ cmJSONState \
cmLDConfigLDConfigTool \
cmLDConfigTool \
cmLinkDirectoriesCommand \
@@ -588,6 +589,12 @@ LIBRHASH_C_SOURCES="\
librhash/sha512.c \
"
+JSONCPP_CXX_SOURCES="\
+ src/lib_json/json_reader.cpp \
+ src/lib_json/json_value.cpp \
+ src/lib_json/json_writer.cpp \
+ "
+
if ${cmake_system_mingw}; then
LIBUV_C_SOURCES="\
src/fs-poll.c \
@@ -1091,12 +1098,6 @@ if test "${cmake_bootstrap_generator}" = "Ninja"; then
cmFortranLexer \
cmFortranParser \
"
-
- JSONCPP_CXX_SOURCES="\
- src/lib_json/json_reader.cpp \
- src/lib_json/json_value.cpp \
- src/lib_json/json_writer.cpp \
- "
else
CMAKE_CXX_SOURCES="${CMAKE_CXX_SOURCES} \
cmDepends \
@@ -1110,8 +1111,6 @@ else
cmMakefileUtilityTargetGenerator \
cmProcessTools \
"
-
- JSONCPP_CXX_SOURCES=
fi
# Add Cygwin-specific flags
@@ -1725,12 +1724,10 @@ if test "x${bootstrap_system_librhash}" = "x"; then
objs="${objs} rhash-`cmake_obj ${a}`"
done
fi
-if test "${cmake_bootstrap_generator}" = "Ninja"; then
- if test "x${bootstrap_system_jsoncpp}" = "x"; then
- for a in ${JSONCPP_CXX_SOURCES}; do
- objs="${objs} jsoncpp-`cmake_obj ${a}`"
- done
- fi
+if test "x${bootstrap_system_jsoncpp}" = "x"; then
+ for a in ${JSONCPP_CXX_SOURCES}; do
+ objs="${objs} jsoncpp-`cmake_obj ${a}`"
+ done
fi
libs=""
@@ -1799,17 +1796,15 @@ if test "x${bootstrap_system_librhash}" != "x"; then
libs="${libs} -lrhash"
fi
-if test "${cmake_bootstrap_generator}" = "Ninja"; then
- jsoncpp_cxx_flags=
- if test "x${bootstrap_system_jsoncpp}" = "x"; then
- jsoncpp_cxx_flags="${jsoncpp_cxx_flags} `cmake_escape_shell "-I${cmake_source_dir}/Utilities/cmjsoncpp/include"`"
- else
- if test `which pkg-config`; then
- use_jsoncpp_flags="`pkg-config --cflags jsoncpp`"
- cmake_cxx_flags="${cmake_cxx_flags} ${use_jsoncpp_flags}"
- fi
- libs="${libs} -ljsoncpp"
+jsoncpp_cxx_flags=
+if test "x${bootstrap_system_jsoncpp}" = "x"; then
+ jsoncpp_cxx_flags="${jsoncpp_cxx_flags} `cmake_escape_shell "-I${cmake_source_dir}/Utilities/cmjsoncpp/include"`"
+else
+ if test `which pkg-config`; then
+ use_jsoncpp_flags="`pkg-config --cflags jsoncpp`"
+ cmake_cxx_flags="${cmake_cxx_flags} ${use_jsoncpp_flags}"
fi
+ libs="${libs} -ljsoncpp"
fi
if test "x${cmake_ansi_cxx_flags}" != "x"; then
@@ -1949,13 +1944,11 @@ if test "x${bootstrap_system_librhash}" = "x"; then
write_source_rule "c" "rhash-`cmake_obj ${a}`" "${src}" ""
done
fi
-if test "${cmake_bootstrap_generator}" = "Ninja"; then
- if test "x${bootstrap_system_jsoncpp}" = "x"; then
- for a in ${JSONCPP_CXX_SOURCES}; do
- src=`cmake_escape_artifact "${cmake_source_dir}/Utilities/cmjsoncpp/${a}"`
- write_source_rule "cxx" "jsoncpp-`cmake_obj ${a}`" "${src}" "${jsoncpp_cxx_flags}"
- done
- fi
+if test "x${bootstrap_system_jsoncpp}" = "x"; then
+ for a in ${JSONCPP_CXX_SOURCES}; do
+ src=`cmake_escape_artifact "${cmake_source_dir}/Utilities/cmjsoncpp/${a}"`
+ write_source_rule "cxx" "jsoncpp-`cmake_obj ${a}`" "${src}" "${jsoncpp_cxx_flags}"
+ done
fi
if test "${cmake_bootstrap_generator}" = "Ninja"; then
echo "