Skip to content

Commit

Permalink
run-make-check,do_cmake: set BOOST_J if !WITH_SYSTEM_BOOS
Browse files Browse the repository at this point in the history
it's also more readable if we can set the number of make jobs
in a single place.

Signed-off-by: Kefu Chai <kchai@redhat.com>
  • Loading branch information
tchaikov committed Sep 11, 2018
1 parent 195470a commit 79b5547
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 1 addition & 2 deletions do_cmake.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,12 @@ fi

mkdir build
cd build
NPROC=${NPROC:-$(nproc)}
if type cmake3 > /dev/null 2>&1 ; then
CMAKE=cmake3
else
CMAKE=cmake
fi
${CMAKE} -DBOOST_J=$NPROC $ARGS "$@" .. || exit 1
${CMAKE} $ARGS "$@" .. || exit 1

# minimal config to find plugins
cat <<EOF > ceph.conf
Expand Down
2 changes: 2 additions & 0 deletions run-make-check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ function detect_ceph_dev_pkgs() {
local boost_root=/opt/ceph
if test -f $boost_root/include/boost/config.hpp; then
cmake_opts+=" -DWITH_SYSTEM_BOOST=ON -DBOOST_ROOT=$boost_root"
else
cmake_opts+=" -DBOOST_J=$(get_processors)"
fi
echo "$cmake_opts"
}
Expand Down

0 comments on commit 79b5547

Please sign in to comment.