diff --git a/ci/build_container/build_container.sh b/ci/build_container/build_container.sh index 012fa1883190a..2b7b3ad832a05 100755 --- a/ci/build_container/build_container.sh +++ b/ci/build_container/build_container.sh @@ -37,8 +37,18 @@ fi export THIRDPARTY_DEPS=/tmp export THIRDPARTY_SRC=/thirdparty -export THIRDPARTY_BUILD=/thirdparty_build DEPS=$(python <(cat target_recipes.bzl; \ echo "print ' '.join(\"${THIRDPARTY_DEPS}/%s.dep\" % r for r in set(TARGET_RECIPES.values()))")) -echo "Building deps ${DEPS}" + +# TODO(htuch): We build twice as a workaround for https://github.com/google/protobuf/issues/3322. +# Fix this. +export THIRDPARTY_BUILD=/thirdparty_build_opt +export CPPFLAGS="-DNDEBUG" +echo "Building opt deps ${DEPS}" +"$(dirname "$0")"/build_and_install_deps.sh ${DEPS} + +export THIRDPARTY_BUILD=/thirdparty_build_dbg +export CPPFLAGS="" +echo "Building dbg deps ${DEPS}" +rm -f /tmp/*.dep "$(dirname "$0")"/build_and_install_deps.sh ${DEPS}