Skip to content

Commit 2338fc6

Browse files
committed
do_cmake.sh: update build type warning
also, use printf instead of cat<< Signed-off-by: Matan Breizman <[email protected]> (cherry picked from commit fc7597d)
1 parent d0b4ff4 commit 2338fc6

File tree

1 file changed

+12
-5
lines changed

1 file changed

+12
-5
lines changed

do_cmake.sh

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -105,13 +105,20 @@ EOF
105105
echo done.
106106

107107
if [[ ! "$ARGS $@" =~ "-DCMAKE_BUILD_TYPE" ]]; then
108-
cat <<EOF
109-
108+
if [ -d ../.git ]; then
109+
printf "
110110
****
111-
WARNING: do_cmake.sh now creates debug builds by default. Performance
112-
may be severely affected. Please use -DCMAKE_BUILD_TYPE=RelWithDebInfo
111+
WARNING: do_cmake.sh now creates debug builds by default if .git exists.
112+
Performance may be severely affected. Please use -DCMAKE_BUILD_TYPE=RelWithDebInfo
113113
if a performance sensitive build is required.
114114
****
115-
EOF
115+
"
116+
else
117+
printf "
118+
****
119+
WARNING: do_cmake.sh now creates RelWithDebInfo builds by default when .git is absent.
120+
****
121+
"
122+
fi
116123
fi
117124

0 commit comments

Comments
 (0)