symbols. If this flag is set,
the debug symbols will remain
embedded in the executables.
-ENABLE_SHARED Dynamically link Ceph libs. False
+ENABLE_SHARED Dynamically link Ceph libs. ON
================= =============================== ===============================
The following command will build the binaries and add them to a zip archive
SCRIPT_DIR="$(dirname "$BASH_SOURCE")"
SCRIPT_DIR="$(realpath "$SCRIPT_DIR")"
+MINGW_CMAKE_FILE=${MINGW_CMAKE_FILE:-}
+MINGW_POSIX_FLAGS=${MINGW_POSIX_FLAGS:-}
+
if [[ -n $USE_MINGW_LLVM ]]; then
MINGW_LLVM_DIR=${MINGW_LLVM_DIR:-"$SCRIPT_DIR/build.deps/mingw-llvm"}
fi
;;
esac
fi
-export OS="$OS"
# The main advantages of mingw-llvm:
# * not affected by the libstdc++/winpthread rw lock bugs
case "$TOOLCHAIN" in
mingw-llvm)
echo "Using mingw-llvm."
- export USE_MINGW_LLVM=1
+ USE_MINGW_LLVM=1
;;
mingw-gcc)
echo "Using mingw-gcc"
CMAKE_BUILD_TYPE=Release
fi
-# Some tests can't use shared libraries yet due to unspecified dependencies.
-# We'll do a static build by default for now.
-ENABLE_SHARED=${ENABLE_SHARED:-OFF}
+ENABLE_SHARED=${ENABLE_SHARED:-ON}
binDir="$BUILD_DIR/bin"
strippedBinDir="$BUILD_DIR/bin_stripped"
if [[ ! -f ${depsToolsetDir}/completed ]]; then
echo "Preparing dependencies: $DEPS_DIR. Log: ${BUILD_DIR}/build_deps.log"
- NUM_WORKERS=$NUM_WORKERS DEPS_DIR=$DEPS_DIR OS="$OS"\
- "$SCRIPT_DIR/win32_deps_build.sh" | tee "${BUILD_DIR}/build_deps.log"
+ NUM_WORKERS=$NUM_WORKERS \
+ DEPS_DIR=$DEPS_DIR \
+ OS="$OS" \
+ ENABLE_SHARED=$ENABLE_SHARED \
+ USE_MINGW_LLVM=$USE_MINGW_LLVM \
+ "$SCRIPT_DIR/win32_deps_build.sh" | tee "${BUILD_DIR}/build_deps.log"
fi
# Due to distribution specific mingw settings, the mingw.cmake file
#!/usr/bin/env bash
-set -e
+set -eu
SCRIPT_DIR="$(dirname "$BASH_SOURCE")"
SCRIPT_DIR="$(realpath "$SCRIPT_DIR")"
-USE_MINGW_LLVM=${USE_MINGW_LLVM:-}
-ENABLE_SHARED=${ENABLE_SHARED:-OFF}
-
-num_vcpus=$(nproc)
-NUM_WORKERS=${NUM_WORKERS:-$num_vcpus}
-
-DEPS_DIR="${DEPS_DIR:-$SCRIPT_DIR/build.deps}"
depsSrcDir="$DEPS_DIR/src"
depsToolsetDir="$DEPS_DIR/mingw"
mingwLlvmSha256Sum="bc97745e702fb9e8f2a16f7d09dd5061ceeef16554dd12e542f619ce937e8d7a"
mingwLlvmDir="${DEPS_DIR}/mingw-llvm"
-# Allow for OS specific customizations through the OS flag (normally
-# passed through from win32_build).
-# Valid options are currently "ubuntu", "rhel", and "suse".
-OS=${OS:-"ubuntu"}
-
function _make() {
make -j $NUM_WORKERS $@
}