From 1a44c8f85fb1209e5824c7c0fb024e5fcd884618 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Wed, 6 May 2020 11:16:38 +0200 Subject: [PATCH 01/17] test ci setup --- .gitlab-ci.yml | 15 ------------- .travis.yml | 57 ++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 57 insertions(+), 15 deletions(-) delete mode 100644 .gitlab-ci.yml create mode 100644 .travis.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml deleted file mode 100644 index 83edba2d1..000000000 --- a/.gitlab-ci.yml +++ /dev/null @@ -1,15 +0,0 @@ -# Install dependencies -before_script: - - conda list -n gitlab-ci || conda env create -f environment.yml -n gitlab-ci - - conda activate gitlab-ci - - pip install coverage nose pytest pytest-cov - -# Install package -Install: - script: python setup.py test - -allow_failure: true - -# Remove conda env -# after_script: -# - conda remove -n gitlab-ci --all -y diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 000000000..4ba2003e6 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,57 @@ +language: python +sudo: required + +addons: + homebrew: + packages: &macos_packages + - cmake + - pkgconfig + - cfitsio + - libomp + update: true + +matrix: + include: + - os: linux + dist: xenial + python: 3.6 + name: "Linux Xenial Python 3.6" + - os: linux + dist: xenial + python: 3.7 + name: "Linux Xenial Python 3.7" + - os: linux + dist: xenial + python: 3.8 + name: "Linux Xenial Python 3.8" + - os: osx + osx_image: xcode11.3 + language: shell + env: PYTHON_VERSION=3.8 + name: "macOS 10.14 Python 3.8" + addons: + homebrew: + packages: + - *macos_packages + +before_install: + - if [ $TRAVIS_OS_NAME = 'linux' ]; then sudo apt-get update; fi + - if [ $TRAVIS_OS_NAME = 'osx' ]; + then curl https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-x86_64.sh -o miniconda.sh; + else wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh; + fi + - chmod +x miniconda.sh + - ./miniconda.sh -b -p $HOME/miniconda + - export PATH=$HOME/miniconda/bin:$PATH + - conda update --all -y; + - conda info -a + +install: + - ./install_shapepipe --develop + - source activate shapepipe + +script: + - python setup.py test + +after_success: + - coveralls From 8b6edbf37d4139b3ad848327d56c780d6aa3e915 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Wed, 6 May 2020 11:41:06 +0200 Subject: [PATCH 02/17] updated readme --- README.rst | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/README.rst b/README.rst index 4703b27e5..69b86706f 100644 --- a/README.rst +++ b/README.rst @@ -1,17 +1,20 @@ ShapePipe ========= -|gitlab-ci| |python35| |python36| |python37| +|travis| |python35| |python36| |python37| .. |gitlab-ci| image:: https://drf-gitlab.cea.fr/cosmostat/ShapePipe/badges/master/pipeline.svg :target: https://drf-gitlab.cea.fr/cosmostat/ShapePipe/tree/master +.. |travis| image:: https://travis-ci.org/CosmoStat/shapepipe.svg?branch=master + :target: https://travis-ci.org/CosmoStat/shapepipe + .. |python35| image:: https://img.shields.io/badge/python-3.5-yellow.svg :target: https://www.python.org/ .. |python36| image:: https://img.shields.io/badge/python-3.6-yellow.svg :target: https://www.python.org/ - + .. |python37| image:: https://img.shields.io/badge/python-3.7-yellow.svg :target: https://www.python.org/ From 62ad8c63be5a4b191d93bbe6edbd54db6bb4236f Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Wed, 6 May 2020 12:07:17 +0200 Subject: [PATCH 03/17] test adding libopenblas --- .travis.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/.travis.yml b/.travis.yml index 4ba2003e6..c7804582e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,6 +2,9 @@ language: python sudo: required addons: + apt: + packages: $linux_packages + - libopenblas-dev homebrew: packages: &macos_packages - cmake @@ -16,14 +19,26 @@ matrix: dist: xenial python: 3.6 name: "Linux Xenial Python 3.6" + addons: + apt: + packages: + - *linux_packages - os: linux dist: xenial python: 3.7 name: "Linux Xenial Python 3.7" + addons: + apt: + packages: + - *linux_packages - os: linux dist: xenial python: 3.8 name: "Linux Xenial Python 3.8" + addons: + apt: + packages: + - *linux_packages - os: osx osx_image: xcode11.3 language: shell From de2c0be47f741fbaa7a80ebccda16d23e2f792ff Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Wed, 6 May 2020 14:36:51 +0200 Subject: [PATCH 04/17] check openblas libs --- .travis.yml | 7 ------- install_shapepipe | 2 ++ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/.travis.yml b/.travis.yml index c7804582e..2b8c51c80 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,9 +2,6 @@ language: python sudo: required addons: - apt: - packages: $linux_packages - - libopenblas-dev homebrew: packages: &macos_packages - cmake @@ -19,10 +16,6 @@ matrix: dist: xenial python: 3.6 name: "Linux Xenial Python 3.6" - addons: - apt: - packages: - - *linux_packages - os: linux dist: xenial python: 3.7 diff --git a/install_shapepipe b/install_shapepipe index 03f7f126b..b1711deff 100755 --- a/install_shapepipe +++ b/install_shapepipe @@ -223,7 +223,9 @@ astromatic_setup() { echo 'ATLAS Include Path:' $ATLAS_INC else echo 'OpenBLAS Library Path:' $BLAS_LIB + ls $BLAS_LIB echo 'OpenBLAS Include Path:' $BLAS_INC + ls $BLAS_INC fi echo '' } From aa4857518e56987e66d8a6b99dce1571c9231921 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Wed, 6 May 2020 16:15:48 +0200 Subject: [PATCH 05/17] test with new install script --- install_shapepipe | 99 +++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 82 insertions(+), 17 deletions(-) diff --git a/install_shapepipe b/install_shapepipe index b1711deff..44d3436b5 100755 --- a/install_shapepipe +++ b/install_shapepipe @@ -9,7 +9,7 @@ LC_CTYPE=en_US.utf8 # ############################################################################## -version="1.1" +version="1.2" ############################################################################## # EXTERNAL PACKAGE VERSIONS @@ -20,34 +20,46 @@ sex_url="https://github.com/astromatic/sextractor/archive/2.25.0.tar.gz" sex_tar="2.25.0.tar.gz" sex_dir="sextractor-2.25.0" sex_bin="sex" +sex_version=TRUE # PSFEx Package psfex_url="https://github.com/astromatic/psfex/archive/3.21.1.tar.gz" psfex_tar="3.21.1.tar.gz" psfex_dir="psfex-3.21.1" psfex_bin="psfex" +psfex_version=TRUE # WeightWatcher Package ww_url="https://www.astromatic.net/download/weightwatcher/weightwatcher-1.12.tar.gz" ww_tar="weightwatcher-1.12.tar.gz" ww_dir="weightwatcher-1.12" ww_bin="ww" +ww_version=TRUE # CDSclient Package (need Findgsc2.2) cdsclient_url="http://cdsarc.u-strasbg.fr/ftp/pub/sw/cdsclient.tar.gz" cdscleint_tar="cdsclient.tar.gz" cdsclient_dir="cdsclient-3.84" cdsclient_bin="findgsc2.2" +cdsclient_version=FALSE # mpi4py Package mpi_url="https://github.com/mpi4py/mpi4py/archive/3.0.2.tar.gz" mpi_tar="3.0.2.tar.gz" mpi_dir="mpi4py-3.0.2" mpi_bin="mpiexec" +mpi_version=TRUE # Divider line line="########################################################################" +# Text colours +RED='\033[0;31m' +GREEN='\033[0;32m' +CYAN='\033[0;36m' +YELLOW='\033[1;33m' +NC='\033[0m' + ############################################################################## # SCRIPT FUNCTIONS ############################################################################## @@ -128,13 +140,14 @@ build_standard() { make install } +# Function to build mpi4pi using preinstalled MPI libraries build_mpi(){ cd $BUILD_DIR/$1 python setup.py build --mpicc=$MPI_ROOT python setup.py install } -# Check if a binary executable is already installed in the conda environment +# Check the conda executable is available check_conda() { if ! type -t "conda" > /dev/null then @@ -157,23 +170,34 @@ check_binary() { # Check if a binary executable is already installed in the conda environment check_binary2() { - if type -t $1 > /dev/null + if type -t "$CONDA_PREFIX/bin/$1" > /dev/null then - echo -ne "$2:\t SUCCESS\n" + echo -ne "$2: ${GREEN}INSTALLED${NC}\n" + if $3 + then + "$CONDA_PREFIX/bin/$1" --version | head -n 1 + fi else - echo -ne "$2:\t FAIL\n" + if $4 + then + echo -ne "$2: ${RED}NOT INSTALLED${NC}\n" + else + echo -ne "$2: ${YELLOW}NOT INSTALLED${NC}\n" + fi fi + echo "" } # Function to report progress report_progress() { echo '' echo $line - echo 'Installing' $1 + echo -e "${CYAN}Installing $1${NC}" echo $line echo '' } +# Function to start the script start() { echo '' echo $line @@ -186,21 +210,39 @@ start() { echo '' } +# Function to report package versions +packages() { + check_binary2 $sex_bin "SExtractor" $sex_version $INSTALL_SEX + check_binary2 $psfex_bin "PSFEx" $psf_version $INSTALL_PSFEX + check_binary2 $ww_bin "WeightWatcher" $ww_version $INSTALL_WW + check_binary2 $cdsclient_bin "CDSclient" $cdsclient_version $INSTALL_CDSCLIENT + check_binary2 $mpi_bin "MPI" $mpi_version $USE_MPI + check_binary2 "shapepipe_run" "ShapePipe" TRUE TRUE +} + +# Function to report package versions +package_report() { + start + echo 'Package Report' + echo '' + packages + pip list + echo '' +} + + +# Function to end the script finish() { echo '' echo $line echo 'Installation Complete!' - if [ "$INSTALL_SEX" == TRUE ]; then check_binary2 $sex_bin "SExtractor"; fi - if [ "$INSTALL_PSFEX" == TRUE ]; then check_binary2 $psfex_bin "PSFEx"; fi - if [ "$INSTALL_WW" == TRUE ]; then check_binary2 $ww_bin "WeightWatcher"; fi - if [ "$INSTALL_CDSCLIENT" == TRUE ]; then check_binary2 $cdsclient_bin "CDSclient"; fi - if [ "$USE_MPI" == TRUE ]; then check_binary2 $mpi_bin "MPI"; fi - sp_ver=$(shapepipe_run -v) - echo 'Version:' $sp_ver + echo '' + packages echo $line echo '' } +# Function to show the installation setup setup() { echo 'Operating System:' $SYSOS echo 'Build Conda Environment:' $BUILD_ENV @@ -214,6 +256,7 @@ setup() { echo '' } +# Function to show the astromatic setup astromatic_setup() { echo 'FFTW Library Path:' $FFTW_LIB echo 'FFTW Include Path:' $FFTW_INC @@ -223,9 +266,7 @@ astromatic_setup() { echo 'ATLAS Include Path:' $ATLAS_INC else echo 'OpenBLAS Library Path:' $BLAS_LIB - ls $BLAS_LIB echo 'OpenBLAS Include Path:' $BLAS_INC - ls $BLAS_INC fi echo '' } @@ -239,6 +280,7 @@ PIPE_DIR=$PWD BUILD_DIR=$PIPE_DIR/build BUILD_ENV=TRUE DEVELOP=FALSE +VOS=FALSE INSTALL_SEX=TRUE INSTALL_PSFEX=TRUE INSTALL_WW=TRUE @@ -251,9 +293,11 @@ help="$(basename "$0") [OPTIONS]\n\n Options:\n \t-h,--help\t show this help message and exit\n \t-v,--version\t print script version and exit\n +\t-p,--packages\t print status of installed packages\n \t--pipe-dir\t set the path to the ShapePipe base directory (default is PWD)\n \t--build-dir\t set the path to the ShapePipe build (default is PWD/build)\n \t--develop\t option to install additional development packages\n +\t--vos\t\t option to install virtual observatory software\n \t--no-env\t do not build Conda environment\n \t--no-sex\t do not build SExtractor\n \t--no-psfex\t do not build PSFEx\n @@ -271,8 +315,8 @@ Executable Build Options:\n \t--atlas-search\t search system path for ATLAS directories\n MPI Build Options:\n -\t--no_mpi\t do not use MPI\n -\t--mpi_root\t path to MPI installation\n\n +\t--no-mpi\t do not use MPI\n +\t--mpi-root\t path to MPI installation\n\n " @@ -291,6 +335,11 @@ case $i in shift exit ;; + -p|--packages) + package_report + shift + exit + ;; --pipe-dir=*) PIPE_DIR="${i#*=}" shift @@ -303,6 +352,10 @@ case $i in DEVELOP=TRUE shift ;; + --vos) + VOS=TRUE + shift + ;; --no-env) BUILD_ENV=FALSE shift @@ -438,6 +491,17 @@ then pip install numpydoc pytest pytest-cov pytest-codestyle sphinx sphinx-rtd-theme fi +############################################################################## +# INSTALL THE VOS LIBRARY +############################################################################## + +# Install the vos library +if [ "$VOS" == TRUE ] +then + report_progress 'vos' + pip install vos +fi + ############################################################################## # INSTALL MACOS REQUIRMENTS ############################################################################## @@ -450,6 +514,7 @@ then conda install -n shapepipe automake autoconf libtool -y export C_INCLUDE_PATH=$CONDA_PREFIX/include export CFLAGS="-Wl,-rpath,$CONDA_PREFIX/lib" + export CPPFLAGS="-Wno-everything" fi ############################################################################## From ac361effabc29de550fd7aba22ad884f0c3b0db2 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Wed, 6 May 2020 18:21:02 +0200 Subject: [PATCH 06/17] test exit code --- install_shapepipe | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/install_shapepipe b/install_shapepipe index 44d3436b5..744743209 100755 --- a/install_shapepipe +++ b/install_shapepipe @@ -60,6 +60,9 @@ CYAN='\033[0;36m' YELLOW='\033[1;33m' NC='\033[0m' +# Error check +ERROR=FALSE + ############################################################################## # SCRIPT FUNCTIONS ############################################################################## @@ -181,6 +184,7 @@ check_binary2() { if $4 then echo -ne "$2: ${RED}NOT INSTALLED${NC}\n" + ERROR=TRUE else echo -ne "$2: ${YELLOW}NOT INSTALLED${NC}\n" fi @@ -230,7 +234,6 @@ package_report() { echo '' } - # Function to end the script finish() { echo '' @@ -240,6 +243,12 @@ finish() { packages echo $line echo '' + if $ERROR + then + exit 1 + else + exit 0 + fi } # Function to show the installation setup @@ -468,6 +477,7 @@ setup if [ "$BUILD_ENV" == TRUE ] then report_progress 'ShapePipe Environment' + source activate base conda env create -f environment.yml fi From 2abb423e3297ca7e0fdf2377be2c91f56121fe32 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Wed, 6 May 2020 18:29:07 +0200 Subject: [PATCH 07/17] exit code test 2 --- .travis.yml | 1 + install_shapepipe | 18 ++++++++++++------ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/.travis.yml b/.travis.yml index 2b8c51c80..ac0fc050b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -60,6 +60,7 @@ install: script: - python setup.py test + - ./install_shapepipe -p after_success: - coveralls diff --git a/install_shapepipe b/install_shapepipe index 744743209..3f8ab1940 100755 --- a/install_shapepipe +++ b/install_shapepipe @@ -224,6 +224,16 @@ packages() { check_binary2 "shapepipe_run" "ShapePipe" TRUE TRUE } +# Function to return exit code +exit_code() { + if $ERROR + then + exit 1 + else + exit 0 + fi +} + # Function to report package versions package_report() { start @@ -232,6 +242,7 @@ package_report() { packages pip list echo '' + exit_code } # Function to end the script @@ -243,12 +254,7 @@ finish() { packages echo $line echo '' - if $ERROR - then - exit 1 - else - exit 0 - fi + exit_code } # Function to show the installation setup From 628ed132dc9b93af341f5939db4d599cb8d13e16 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Wed, 6 May 2020 19:06:19 +0200 Subject: [PATCH 08/17] improved if statements --- install_shapepipe | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/install_shapepipe b/install_shapepipe index 3f8ab1940..fe9636ff0 100755 --- a/install_shapepipe +++ b/install_shapepipe @@ -176,12 +176,12 @@ check_binary2() { if type -t "$CONDA_PREFIX/bin/$1" > /dev/null then echo -ne "$2: ${GREEN}INSTALLED${NC}\n" - if $3 + if [ "$3" == TRUE ] then "$CONDA_PREFIX/bin/$1" --version | head -n 1 fi else - if $4 + if [ "$4" == TRUE ] then echo -ne "$2: ${RED}NOT INSTALLED${NC}\n" ERROR=TRUE @@ -226,7 +226,7 @@ packages() { # Function to return exit code exit_code() { - if $ERROR + if [ "$ERROR" == TRUE ] then exit 1 else From 60a9b645acad14f7129ec96c465a7925c9d13c03 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Wed, 6 May 2020 19:33:00 +0200 Subject: [PATCH 09/17] fixed bugs --- .travis.yml | 1 - install_shapepipe | 33 ++++++++++++++++----------------- 2 files changed, 16 insertions(+), 18 deletions(-) diff --git a/.travis.yml b/.travis.yml index ac0fc050b..2b8c51c80 100644 --- a/.travis.yml +++ b/.travis.yml @@ -60,7 +60,6 @@ install: script: - python setup.py test - - ./install_shapepipe -p after_success: - coveralls diff --git a/install_shapepipe b/install_shapepipe index fe9636ff0..8b63e2436 100755 --- a/install_shapepipe +++ b/install_shapepipe @@ -60,7 +60,19 @@ CYAN='\033[0;36m' YELLOW='\033[1;33m' NC='\033[0m' -# Error check +# Set variable defaults +PIPE_DIR=$PWD +BUILD_DIR=$PIPE_DIR/build +BUILD_ENV=TRUE +DEVELOP=FALSE +VOS=FALSE +INSTALL_SEX=TRUE +INSTALL_PSFEX=TRUE +INSTALL_WW=TRUE +INSTALL_CDSCLIENT=TRUE +ATLAS_SEARCH=FALSE +use_atlas=FALSE +USE_MPI=TRUE ERROR=FALSE ############################################################################## @@ -183,7 +195,7 @@ check_binary2() { else if [ "$4" == TRUE ] then - echo -ne "$2: ${RED}NOT INSTALLED${NC}\n" + echo -ne "$2: ${RED}INSTALLATION FAILED${NC}\n" ERROR=TRUE else echo -ne "$2: ${YELLOW}NOT INSTALLED${NC}\n" @@ -217,7 +229,7 @@ start() { # Function to report package versions packages() { check_binary2 $sex_bin "SExtractor" $sex_version $INSTALL_SEX - check_binary2 $psfex_bin "PSFEx" $psf_version $INSTALL_PSFEX + check_binary2 $psfex_bin "PSFEx" $psfex_version $INSTALL_PSFEX check_binary2 $ww_bin "WeightWatcher" $ww_version $INSTALL_WW check_binary2 $cdsclient_bin "CDSclient" $cdsclient_version $INSTALL_CDSCLIENT check_binary2 $mpi_bin "MPI" $mpi_version $USE_MPI @@ -228,6 +240,7 @@ packages() { exit_code() { if [ "$ERROR" == TRUE ] then + echo "Installation failed as some packages were not properly installed." exit 1 else exit 0 @@ -290,20 +303,6 @@ astromatic_setup() { # SCRIPT OPTIONS ############################################################################## -# Set variable defaults -PIPE_DIR=$PWD -BUILD_DIR=$PIPE_DIR/build -BUILD_ENV=TRUE -DEVELOP=FALSE -VOS=FALSE -INSTALL_SEX=TRUE -INSTALL_PSFEX=TRUE -INSTALL_WW=TRUE -INSTALL_CDSCLIENT=TRUE -ATLAS_SEARCH=FALSE -use_atlas=FALSE -USE_MPI=TRUE - help="$(basename "$0") [OPTIONS]\n\n Options:\n \t-h,--help\t show this help message and exit\n From ee2699262f1f1a57b48de4f07b09c2aa87a25bcc Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Thu, 7 May 2020 14:18:57 +0200 Subject: [PATCH 10/17] added option to uninstall --- install_shapepipe | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/install_shapepipe b/install_shapepipe index 8b63e2436..dc6c5f110 100755 --- a/install_shapepipe +++ b/install_shapepipe @@ -240,7 +240,7 @@ packages() { exit_code() { if [ "$ERROR" == TRUE ] then - echo "Installation failed as some packages were not properly installed." + echo "ShapePipe installation failed as some packages were not properly installed." exit 1 else exit 0 @@ -249,6 +249,11 @@ exit_code() { # Function to report package versions package_report() { + INSTALL_SEX=FALSE + INSTALL_PSFEX=FALSE + INSTALL_WW=FALSE + INSTALL_CDSCLIENT=FALSE + USE_MPI=FALSE start echo 'Package Report' echo '' @@ -299,6 +304,12 @@ astromatic_setup() { echo '' } +uninstall() { + rm -r build dist shapepipe.egg-info .eggs + source deactivate + conda remove -n shapepipe --all -y +} + ############################################################################## # SCRIPT OPTIONS ############################################################################## @@ -308,6 +319,7 @@ Options:\n \t-h,--help\t show this help message and exit\n \t-v,--version\t print script version and exit\n \t-p,--packages\t print status of installed packages\n +\t--uninstall\t uninstall ShapePipe\n \t--pipe-dir\t set the path to the ShapePipe base directory (default is PWD)\n \t--build-dir\t set the path to the ShapePipe build (default is PWD/build)\n \t--develop\t option to install additional development packages\n @@ -354,6 +366,11 @@ case $i in shift exit ;; + --uninstall) + uninstall + shift + exit + ;; --pipe-dir=*) PIPE_DIR="${i#*=}" shift From ddd10221e49a430e17b19fc7adcfcb1924fd1900 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Thu, 7 May 2020 14:58:11 +0200 Subject: [PATCH 11/17] test with apt openblas --- .travis.yml | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) diff --git a/.travis.yml b/.travis.yml index 2b8c51c80..d5cee16f7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,8 +2,12 @@ language: python sudo: required addons: + apt: + update: true + packages: + - libopenblas-dev homebrew: - packages: &macos_packages + packages: - cmake - pkgconfig - cfitsio @@ -20,27 +24,15 @@ matrix: dist: xenial python: 3.7 name: "Linux Xenial Python 3.7" - addons: - apt: - packages: - - *linux_packages - os: linux dist: xenial python: 3.8 name: "Linux Xenial Python 3.8" - addons: - apt: - packages: - - *linux_packages - os: osx osx_image: xcode11.3 language: shell env: PYTHON_VERSION=3.8 name: "macOS 10.14 Python 3.8" - addons: - homebrew: - packages: - - *macos_packages before_install: - if [ $TRAVIS_OS_NAME = 'linux' ]; then sudo apt-get update; fi @@ -55,7 +47,10 @@ before_install: - conda info -a install: - - ./install_shapepipe --develop + - if [ $TRAVIS_OS_NAME = 'linux' ]; + then ./install_shapepipe --develop --blas-lib=/usr/lib --blas-inc=/usr/include; + else ./install_shapepipe --develop; + fi - source activate shapepipe script: From b6feb48c5b41da0d46831183c4b1ebd021e7bc21 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Thu, 7 May 2020 15:07:59 +0200 Subject: [PATCH 12/17] test with atlas --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index d5cee16f7..45e0e406d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,7 +5,7 @@ addons: apt: update: true packages: - - libopenblas-dev + - libatlas-dev homebrew: packages: - cmake @@ -48,7 +48,7 @@ before_install: install: - if [ $TRAVIS_OS_NAME = 'linux' ]; - then ./install_shapepipe --develop --blas-lib=/usr/lib --blas-inc=/usr/include; + then ./install_shapepipe --develop --atlas-lib=/usr/lib --atlas-inc=/usr/include; else ./install_shapepipe --develop; fi - source activate shapepipe From 97d7b6075458362774f5162c23b31d5b06ed2259 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Thu, 7 May 2020 15:15:51 +0200 Subject: [PATCH 13/17] try atlas search option --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 45e0e406d..8a267ee2f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -48,7 +48,7 @@ before_install: install: - if [ $TRAVIS_OS_NAME = 'linux' ]; - then ./install_shapepipe --develop --atlas-lib=/usr/lib --atlas-inc=/usr/include; + then ./install_shapepipe --develop --atlas-search; else ./install_shapepipe --develop; fi - source activate shapepipe From 94486e18e2e7d41c8056c5211b0ce65177bfe412 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Thu, 7 May 2020 15:26:56 +0200 Subject: [PATCH 14/17] revert to standard installation --- .travis.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 8a267ee2f..a8aeeba4c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,7 +5,7 @@ addons: apt: update: true packages: - - libatlas-dev + - libopenblas-dev homebrew: packages: - cmake @@ -47,10 +47,7 @@ before_install: - conda info -a install: - - if [ $TRAVIS_OS_NAME = 'linux' ]; - then ./install_shapepipe --develop --atlas-search; - else ./install_shapepipe --develop; - fi + - ./install_shapepipe --develop; - source activate shapepipe script: From 43d4ff43f1acbb4ab1f4bb1bcd6515c72fae79a8 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Thu, 7 May 2020 17:26:03 +0200 Subject: [PATCH 15/17] minor fix to text --- install_shapepipe | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install_shapepipe b/install_shapepipe index dc6c5f110..fe5e8f548 100755 --- a/install_shapepipe +++ b/install_shapepipe @@ -338,7 +338,7 @@ Executable Build Options:\n \t--blas-inc\t path to OpenBLAS include directory\n \t--atlas-lib\t path to ATLAS library directory\n \t--atlas-inc\t path to ATLAS include directory\n -\t--atlas-search\t search system path for ATLAS directories\n +\t--atlas-search\t search system path for ATLAS directories\n\n MPI Build Options:\n \t--no-mpi\t do not use MPI\n From 45a4cbd8c0a027744c8d105c6489665c057f40c9 Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Thu, 7 May 2020 20:13:41 +0200 Subject: [PATCH 16/17] try with LD_LIBRARY_PATH --- install_shapepipe | 1 + 1 file changed, 1 insertion(+) diff --git a/install_shapepipe b/install_shapepipe index fe5e8f548..c61fe7b40 100755 --- a/install_shapepipe +++ b/install_shapepipe @@ -506,6 +506,7 @@ fi # Activate conda environment source activate shapepipe echo "Activating Conda environment" $CONDA_PREFIX +export LD_LIBRARY_PATH=$CONDA_PREFIX/lib if [ -z "$FFTW_LIB" ]; then FFTW_LIB=$CONDA_PREFIX/lib; fi if [ -z "$FFTW_INC" ]; then FFTW_INC=$CONDA_PREFIX/include; fi From f0f3ec8055a16db5c4c49d2abc81c02a37c4e29d Mon Sep 17 00:00:00 2001 From: Samuel Farrens Date: Thu, 7 May 2020 20:34:23 +0200 Subject: [PATCH 17/17] test option to hide warnings on linux --- install_shapepipe | 2 ++ 1 file changed, 2 insertions(+) diff --git a/install_shapepipe b/install_shapepipe index c61fe7b40..78bcf5339 100755 --- a/install_shapepipe +++ b/install_shapepipe @@ -548,6 +548,8 @@ then export C_INCLUDE_PATH=$CONDA_PREFIX/include export CFLAGS="-Wl,-rpath,$CONDA_PREFIX/lib" export CPPFLAGS="-Wno-everything" +else + export CPPFLAGS="-w" fi ##############################################################################