diff --git a/util/build_prep/macosx/prep.sh.in b/util/build_prep/macosx/prep.sh.in deleted file mode 100644 index df0d32f3..00000000 --- a/util/build_prep/macosx/prep.sh.in +++ /dev/null @@ -1,130 +0,0 @@ -#! /usr/bin/env bash - -macosx_version='10.11' - -# -----BEGIN COMMON.SH----- -# -----END COMMON.SH----- - -# Ensure we have a new enough CMake -if ! have cmake; then - brew install cmake || exit 1 - brew link cmake || exit 1 -fi - -if ! have cmake; then - echo "Unable to install cmake" >&2 - - exit 1 -fi - -if ! version_min 'cmake --version' 3.3.999; then - echo "cmake version too low (3.4+ required)" >&2 - - exit 1 -fi - -# Install a native "xz" command, in case it is later needed -if ! have xz; then - brew install xz -fi - -# Setup compiler wrappers to specify the minimum -# Mac OS X version and SDK -## XXX:TODO: Find this SDK directory -macosx_sdk_directory="/Library/Developer/CommandLineTools/SDKs/MacOSX${macosx_version}.sdk" -wrap_compilers_add_options=(-mmacosx-version-min="${macosx_version}" -isysroot "${macosx_sdk_directory}") -wrap_compilers - -# Ensure we have a new enough Boost -if ! have boost; then - BOOST_ROOT="${KEEP_AROUND_DIRECTORY}/boost" - - if ! have boost; then - bootstrap_boost -m -c -s - fi -fi - -if ! have boost; then - echo "Unable to install boost" >&2 - - exit 1 -fi - -if ! version_min 'boost --version' 1.69.999; then - echo "boost version too low (1.70.0+ required)" >&2 - - exit 1 -fi -boost_dir="$(boost --install-prefix)" - -# Ensure we have a new enough Qt5 -PATH="${PATH}:/usr/local/opt/qt/bin:${KEEP_AROUND_DIRECTORY}/qt/bin" -export PATH -if ! have qtpaths; then - ( - qt5_version='5.11.2' - qt5_url="https://download.qt.io/archive/qt/$(echo "${qt5_version}" | cut -f 1-2 -d .)/${qt5_version}/single/qt-everywhere-src-${qt5_version}.tar.xz" - qt5_sha256='c6104b840b6caee596fa9a35bc5f57f67ed5a99d6a36497b6fe66f990a53ca81' - qt5_archive="qt5-${qt5_version}.tar.xz" - qt5_dir="qt-everywhere-src-${qt5_version}" - - cd "${KEEP_AROUND_DIRECTORY}" || exit 1 - - rm -rf "${qt5_dir}" - - if [ ! -f "${qt5_archive}" ]; then - rm -f "${qt5_archive}.new" - wget -O "${qt5_archive}.new" "${qt5_url}" || rm -f "${qt5_archive}.new" - qt5_download_sha256="$(openssl dgst -sha256 "${qt5_archive}.new" | sed 's@^.*= *@@')" - if [ "${qt5_download_sha256}" != "${qt5_sha256}" ]; then - echo "Failed to download Qt5. Got SHA256 ${qt5_download_sha256}, expected ${qt5_sha256}" >&2 - - exit 1 - fi - - mv "${qt5_archive}.new" "${qt5_archive}" || exit 1 - fi - - xz -dc "${qt5_archive}" | tar -xf - || exit 1 - - ( - cd "${qt5_dir}" || exit 1 - - CC="$(type -p clang)" - CXX="$(type -p clang++)" - QMAKE_CC="${CC}" - QMAKE_CXX="${CXX}" - export CC CXX QMAKE_CC QMAKE_CXX - - yes | ./configure -verbose -opensource -rpath -framework -prefix "${KEEP_AROUND_DIRECTORY}/qt" || exit 1 - make || exit 1 - make install || exit 1 - ) || exit 1 - - rm -rf "${qt5_dir}" - ) -fi - -if ! have qtpaths; then - echo "Unable to install qt5" >&2 - - exit 1 -fi - -if ! version_min 'qtpaths --qt-version' 5.8.999 5.11.999; then - echo "qt5 version not in range (version range: [5.9+, 5.12-))" >&2 - - exit 1 -fi -qt5_dir="$(qtpaths --install-prefix)/lib/cmake/Qt5" - -echo "All verified." -echo "" -echo "Next steps:" -echo " CC='${CC:-cc} ${wrap_compilers_add_options[*]}'" -echo " CXX='${CXX:-c++} ${wrap_compilers_add_options[*]}'" -echo " export CC CXX" -echo " cmake -DBOOST_ROOT=${boost_dir} -DNANO_GUI=ON -DQt5_DIR=${qt5_dir} " -echo " cpack -G \"DragNDrop\"" - -exit 0 diff --git a/util/build_prep/ubuntu/prep.sh.in b/util/build_prep/ubuntu/prep.sh.in deleted file mode 100644 index 6697a65a..00000000 --- a/util/build_prep/ubuntu/prep.sh.in +++ /dev/null @@ -1,70 +0,0 @@ -#! /usr/bin/env bash - -# -----BEGIN COMMON.SH----- -# -----END COMMON.SH----- - -export DEBIAN_FRONTEND=noninteractive - -set -euo pipefail - -apt-get update --yes -apt-get --yes install git cmake ninja-build autotools-dev \ -build-essential g++ clang python-dev \ -libicu-dev libbz2-dev \ -locales wget curl apt-utils \ -lsb-release -apt-get --yes install xorg xvfb xauth xfonts-100dpi xfonts-75dpi xfonts-scalable xfonts-cyrillic -apt-get --yes install libqt5gui5 libqt5core5a libqt5dbus5 qttools5-dev qttools5-dev-tools libprotobuf-dev protobuf-compiler -apt remove --yes libboost-all-dev -apt autoremove --yes - -# Ensure we have a new enough Boost -if ! have boost; then - bootstrap_boost -m -s -fi - -if ! have boost; then - echo "Unable to install boost" >&2 - - exit 1 -fi - -if ! version_min 'boost --version' 1.69.999; then - echo "boost version too low (1.70.0+ required)" >&2 - exit 1 -fi -boost_dir="$(boost --install-prefix)" - -# Ensure we have a new enough Qt5 -if ! have qtpaths; then - echo "Unable to install qt5" >&2 - - exit 1 -fi - -if ! version_min 'qtpaths --qt-version 2>/dev/null' 5.2.999 5.8.999; then - if ! version_min 'qtpaths -- --qt-version' 5.2.999 5.8.999; then - echo "qt5 version not in range (version range: [5.3+, 5.9-))" >&2 - - exit 1 - fi -fi -qt5_dir="$(qtpaths --install-prefix)/lib/cmake/Qt5" - -if [ ! -d "${qt5_dir}" ]; then - qt5_dir='' -fi - -# Determine how to call cmake -cmake_add='' -if [ -n "${qt5_dir}" ]; then - cmake_add="${cmake_add} -DQt5_DIR=${qt5_dir}" -fi - -echo "All verified." -echo "" -echo "Next steps:" -echo " cmake -DBOOST_ROOT=${boost_dir} -DNANO_GUI=ON ${cmake_add} " -echo " cpack -G \"TBZ2\"" - -exit 0