From 717dc0b9f619400e332b80b85ee874ba3d1e680f Mon Sep 17 00:00:00 2001 From: Michael Adams Date: Wed, 31 Jan 2024 13:43:11 -0800 Subject: [PATCH] Removed the obsolete my_build script. --- build/make_dist | 1 - build/make_release | 1 - build/my_build | 229 --------------------------------------------- 3 files changed, 231 deletions(-) delete mode 100755 build/my_build diff --git a/build/make_dist b/build/make_dist index d1eeb52c..667309b2 100755 --- a/build/make_dist +++ b/build/make_dist @@ -104,7 +104,6 @@ mv "$build_dir/doc/latex/refman.pdf" "$source_dir/doc/manual.pdf" || \ panic "cannot generate changelog" remove_list=() -remove_list+=(build/my_build) remove_list+=(build/appveyor) remove_list+=(build/travis) remove_list+=(build/make_dist) diff --git a/build/make_release b/build/make_release index fc7b1a16..00ac862e 100755 --- a/build/make_release +++ b/build/make_release @@ -229,7 +229,6 @@ remove_list+=(build/extract_release_notes) remove_list+=(build/github) remove_list+=(build/make_dist) remove_list+=(build/make_release) -remove_list+=(build/my_build) remove_list+=(build/travis) remove_list+=(data/test/bad/1_crash.jpg) diff --git a/build/my_build b/build/my_build deleted file mode 100755 index 839b7414..00000000 --- a/build/my_build +++ /dev/null @@ -1,229 +0,0 @@ -#! /bin/bash - -panic() -{ - echo "ERROR: $@" - exit 1 -} - -cmd_dir=$(dirname "$0") || exit 1 -abs_cmd_dir=$(readlink -f "$cmd_dir") || panic - -usage() -{ - echo "bad usage: $@" - exit 2 -} - -enable=1 -enable_install=0 -enable_debug=0 -do_make_test=0 -verbose=0 -enable_asan=0 -enable_lsan=0 -enable_ubsan=0 -enable_tsan=0 -enable_shared=1 -sde_top_dir= -configure_only=0 -enable_doc=0 -use_pthread=0 - -while getopts m:PE:AULTditvCDnS: opt; do - case $opt in - S) - enable_shared="$OPTARG";; - P) - use_pthread=1;; - n) - enable=0;; - m) - case "$OPTARG" in - tsan) - enable_tsan=1 - enable_asan=0 - enable_lsan=0 - enable_ubsan=1 - enable_doc=0 - enable_debug=1 - enable_install=1 - use_pthread=1 - ;; - debug) - enable_tsan=0 - enable_asan=1 - enable_lsan=1 - enable_ubsan=1 - enable_doc=0 - enable_debug=1 - enable_install=1 - ;; - release) - enable_tsan=0 - enable_asan=1 - enable_lsan=1 - enable_ubsan=1 - enable_doc=0 - enable_debug=0 - enable_install=1 - ;; - *) - usage - ;; - esac - ;; - A) - enable_asan=1;; - L) - enable_lsan=1;; - U) - enable_ubsan=1;; - T) - enable_tsan=1;; - C) - configure_only=1;; - D) - enable_doc=1;; - i) - enable_install=1;; - d) - enable_debug=1;; - t) - do_make_test=1;; - v) - verbose=1;; - E) - sde_top_dir="$OPTARG";; - \?) - usage - break;; - esac -done -shift $((OPTIND - 1)) - -#if [ "$enable_debug" -ne 0 ]; then -# enable_asan=1 -# enable_lsan=1 -# enable_ubsan=1 -#fi - -source_dir="$abs_cmd_dir/.." -tmp_dir="$source_dir/tmp_cmake" -build_dir="$tmp_dir/build" -install_dir="$tmp_dir/install" - -echo "source directory $source_dir" -echo "build directory $build_dir" -echo "install directory $install_dir" -if [ -n "$CC" ]; then - echo "C compiler $CC" -fi - -if [ -n "$sde_top_dir" ]; then - #sde_gcc="$sde_top_dir/bin/gcc" - sde_setup="$sde_top_dir/bin/sde_make_setup" - eval $("$sde_setup") || panic "setup failed" -fi - -if [ -e "$tmp_dir" ]; then - echo "Removing $tmp_dir" - rm -rf "$tmp_dir" || panic "cannot remove directory $tmp_dir" -fi - -configure_opts=() -configure_opts+=(-B"$build_dir") -configure_opts+=(-H"$source_dir") -#if [ -n "$sde_top_dir" ]; then -# configure_opts+=("-DCMAKE_C_COMPILER=$sde_gcc") -#fi -configure_opts+=("-DCMAKE_INSTALL_PREFIX=$install_dir") -if [ "$enable_debug" -ne 0 ]; then - configure_opts+=("-DCMAKE_BUILD_TYPE=Debug") -else - configure_opts+=("-DCMAKE_BUILD_TYPE=Release") -fi -if [ "$enable_shared" -ne 0 ]; then - configure_opts+=("-DJAS_ENABLE_SHARED=true") -else - configure_opts+=("-DJAS_ENABLE_SHARED=false") -fi -if [ "$enable_asan" -ne 0 ]; then - configure_opts+=("-DJAS_ENABLE_ASAN=true") -fi -if [ "$enable_tsan" -ne 0 ]; then - configure_opts+=("-DJAS_ENABLE_TSAN=true") -fi -if [ "$enable_lsan" -ne 0 ]; then - configure_opts+=("-DJAS_ENABLE_LSAN=true") -fi -if [ "$enable_ubsan" -ne 0 ]; then - configure_opts+=("-DJAS_ENABLE_UBSAN=true") -fi -configure_opts+=("-DJAS_ENABLE_DANGEROUS_INTERNAL_TESTING_MODE=true") -if [ "$enable_doc" -ne 0 ]; then - configure_opts+=("-DJAS_ENABLE_DOC=true") -else - configure_opts+=("-DJAS_ENABLE_DOC=false") -fi -configure_opts+=("-DCMAKE_VERBOSE_MAKEFILE=true") -if [ "$use_pthread" -ne 0 ]; then - configure_opts+=("-DJAS_PREFER_PTHREAD=true") -fi -configure_opts+=("$@") -command=(cmake "${configure_opts[@]}") -echo "============================================================" -echo "RUNNING: ${command[@]}" -echo "============================================================" -if [ "$enable" -ne 0 ]; then - "${command[@]}" || panic "cmake failed" -fi - -if [ "$configure_only" -ne 0 ]; then - exit -fi - -build_opts=() -install_opts=() -if [ "$verbose" -ne 0 ]; then - build_opts+=(--verbose) - install_opts+=(--verbose) -fi -command=(cmake) -command+=(--build "$build_dir") -command+=(--clean-first) -command+=("${build_opts[@]}") -echo "============================================================" -echo "RUNNING: ${command[@]}" -echo "============================================================" -if [ "$enable" -ne 0 ]; then - "${command[@]}" || \ - panic "cmake build failed" -fi - -if [ "$enable_install" -ne 0 ]; then - command=(cmake) - command+=(--build "$build_dir") - command+=(--target install) - command+=("${install_opts[@]}") - echo "============================================================" - echo "RUNNING: ${command[@]}" - echo "============================================================" - if [ "$enable" -ne 0 ]; then - "${command[@]}" || \ - panic "cmake install failed" - fi -fi - -test_opts=() -test_opts+=(--output-on-failure) -command=(ctest "${test_opts[@]}") -if [ "$do_make_test" -ne 0 ]; then - echo "============================================================" - echo "Testing" - echo "RUNNING: ${command[@]}" - echo "============================================================" - if [ "$enable" -ne 0 ]; then - (cd "$build_dir" && "${command[@]}") || panic "ctest failed" - fi -fi