From 8de8737157649f805928c0f49f5016e7c6ad36cc Mon Sep 17 00:00:00 2001 From: "H. Vetinari" Date: Sun, 26 Apr 2020 13:41:41 +0200 Subject: [PATCH 01/14] update blis to 0.7.0 --- recipe/meta.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipe/meta.yaml b/recipe/meta.yaml index d4dbaed7..da0e1be8 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -47,7 +47,7 @@ outputs: - libopenblas 0.3.9 # [blas_impl == 'openblas'] - mkl 2020.0 # [not win and blas_impl == 'mkl'] - mkl 2020.* # [win and blas_impl == 'mkl'] - - blis 0.6.1 # [blas_impl == 'blis'] + - blis 0.7.0 # [blas_impl == 'blis'] run: - {{ pin_compatible("libopenblas", max_pin="x.x.x", exact=win) }} # [blas_impl == 'openblas'] - {{ pin_compatible("mkl", max_pin="x", exact=win) }} # [blas_impl == 'mkl'] @@ -191,7 +191,7 @@ outputs: - {{ pin_subpackage("libcblas", exact=True) }} - {{ pin_subpackage("libblas", exact=True) }} {% else %} - - blis 0.6.1 + - blis 0.7.0 {% endif %} run: - {{ pin_subpackage("liblapack", exact=True) }} # [blas_impl != 'blis'] From 59ac1a3ec2bfb655d1ea95ec20696155078e647f Mon Sep 17 00:00:00 2001 From: "H. Vetinari" Date: Sun, 26 Apr 2020 14:38:07 +0200 Subject: [PATCH 02/14] correctly abort bld.bat if there's an error. --- recipe/bld.bat | 2 +- recipe/build.sh | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/recipe/bld.bat b/recipe/bld.bat index cab8f04e..70e7ade2 100644 --- a/recipe/bld.bat +++ b/recipe/bld.bat @@ -13,5 +13,5 @@ set MSYS2_PATH_TYPE=inherit set CHERE_INVOKING=1 set "SHLIB_PREFIX=" bash -x "./build.sh" -if errorlevel 1 exit 1 +IF %ERRORLEVEL% NEQ 0 exit 1 exit 0 diff --git a/recipe/build.sh b/recipe/build.sh index 80499915..50dcfc57 100644 --- a/recipe/build.sh +++ b/recipe/build.sh @@ -13,6 +13,8 @@ if [[ "$target_platform" == linux* || "$target_platform" == osx* ]]; then else export LIBRARY_PREFIX=$NEW_ENV/Library export EXE_SUFFIX=".exe" + # necessary to escalate errors to calling bld.bat script correctly + set -e fi export CPATH="${LIBRARY_PREFIX}/include" From b96ee4ad3e3b068e636cf169bc2d4aa3968b9a6e Mon Sep 17 00:00:00 2001 From: "H. Vetinari" Date: Sun, 26 Apr 2020 20:28:33 +0200 Subject: [PATCH 03/14] add explanatory comment about dependency on netlib build --- recipe/meta.yaml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/recipe/meta.yaml b/recipe/meta.yaml index da0e1be8..d1fa1d72 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -31,6 +31,18 @@ requirements: - m2-make # [win] - make # [not win] - posix # [win] + # The following are actual build dependencies of this recipe; however, they + # only get installed by the build scripts, since they must be installed in a + # different environment (otherwise there'd be a variant collision)! The build + # script will link to those netlib libraries and set up the netlib test suite. + # For the different blas variants, build_pkg.{sh|bat} will then point those + # links to the respective libraries of the desired variant, and *then* run + # the test suite (in test_blas.{sh|bat}) to see that everything works correctly. + # Note: These libraries are built in the lapack-feedstock. + # - libblas {{ version }} *netlib + # - libcblas {{ version }} *netlib + # - liblapack {{ version }} *netlib + # - liblapacke {{ version }} *netlib outputs: - name: libblas From a218012aea2ab0040c0cb9b0e25ef4fd00bd0398 Mon Sep 17 00:00:00 2001 From: "H. Vetinari" Date: Mon, 27 Apr 2020 22:35:36 +0200 Subject: [PATCH 04/14] turn more_testing into patch; delete empty file --- recipe/m | 0 recipe/meta.yaml | 2 +- recipe/more_testing.diff | 13 ---------- ...AS-and-LAPACKE-in-addition-to-LAPACK.patch | 25 +++++++++++++++++++ 4 files changed, 26 insertions(+), 14 deletions(-) delete mode 100644 recipe/m delete mode 100644 recipe/more_testing.diff create mode 100644 recipe/patches/0001-Test-BLAS-and-LAPACKE-in-addition-to-LAPACK.patch diff --git a/recipe/m b/recipe/m deleted file mode 100644 index e69de29b..00000000 diff --git a/recipe/meta.yaml b/recipe/meta.yaml index d1fa1d72..3b9d84e8 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -16,7 +16,7 @@ source: sha256: deb22cc4a6120bff72621155a9917f485f96ef8319ac074a7afbc68aab88bcf6 patches: # Test BLAS and LAPACKE in addition to LAPACK - - more_testing.diff + - patches/0001-Test-BLAS-and-LAPACKE-in-addition-to-LAPACK.patch build: number: "{{ build_num }}" diff --git a/recipe/more_testing.diff b/recipe/more_testing.diff deleted file mode 100644 index c752b7c6..00000000 --- a/recipe/more_testing.diff +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index caa0e710..5d67b09e 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -279,6 +279,8 @@ endif() - - if(BUILD_TESTING) - add_subdirectory(TESTING) -+ add_subdirectory(BLAS/TESTING) -+ add_subdirectory(LAPACKE/example) - endif() - - # -------------------------------------------------- diff --git a/recipe/patches/0001-Test-BLAS-and-LAPACKE-in-addition-to-LAPACK.patch b/recipe/patches/0001-Test-BLAS-and-LAPACKE-in-addition-to-LAPACK.patch new file mode 100644 index 00000000..91c5b4b3 --- /dev/null +++ b/recipe/patches/0001-Test-BLAS-and-LAPACKE-in-addition-to-LAPACK.patch @@ -0,0 +1,25 @@ +From edbf3225c76685d753715d1f0055e56c89dda2d1 Mon Sep 17 00:00:00 2001 +From: Isuru Fernando +Date: Mon, 7 Jan 2019 00:23:59 -0600 +Subject: [PATCH] Test BLAS and LAPACKE in addition to LAPACK + +--- + CMakeLists.txt | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index d9dbf974..dabab4c0 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -295,6 +295,8 @@ endif() + + if(BUILD_TESTING) + add_subdirectory(TESTING) ++ add_subdirectory(BLAS/TESTING) ++ add_subdirectory(LAPACKE/example) + endif() + + # -------------------------------------------------- +-- +2.26.2.windows.1 + From c98fad4a3c9bb26387995b3c16c4c52219f30c45 Mon Sep 17 00:00:00 2001 From: "H. Vetinari" Date: Sat, 27 Jun 2020 10:48:27 +0200 Subject: [PATCH 05/14] bump openblas to 0.3.10 --- recipe/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipe/meta.yaml b/recipe/meta.yaml index 3b9d84e8..b78c730e 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -56,7 +56,7 @@ outputs: - blas_{{ blas_impl }} # [blas_impl != blas_default_impl] requirements: host: - - libopenblas 0.3.9 # [blas_impl == 'openblas'] + - libopenblas 0.3.10 # [blas_impl == 'openblas'] - mkl 2020.0 # [not win and blas_impl == 'mkl'] - mkl 2020.* # [win and blas_impl == 'mkl'] - blis 0.7.0 # [blas_impl == 'blis'] From 567ca3406f4adc6c584cd5d70fdebde736b54f23 Mon Sep 17 00:00:00 2001 From: "H. Vetinari" Date: Sat, 27 Jun 2020 10:48:46 +0200 Subject: [PATCH 06/14] bump build number --- recipe/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipe/meta.yaml b/recipe/meta.yaml index b78c730e..a6d67239 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -1,5 +1,5 @@ {% set version = "3.8.0" %} -{% set build_num = 15 %} +{% set build_num = 16 %} {% if blas_impl == 'openblas' %} {% set build_num = build_num + 1 %} {% endif %} From a46b1c69f2496129f4cd1cb7bd676e0113a77aef Mon Sep 17 00:00:00 2001 From: conda-forge-linter Date: Sat, 27 Jun 2020 08:54:28 +0000 Subject: [PATCH 07/14] MNT: Re-rendered with conda-build 3.19.2, conda-smithy 3.7.3, and conda-forge-pinning 2020.06.24.16.31.11 --- .azure-pipelines/azure-pipelines-linux.yml | 17 +++--- .azure-pipelines/azure-pipelines-osx.yml | 68 ++++------------------ .azure-pipelines/azure-pipelines-win.yml | 50 ++++++++-------- .drone.yml | 6 +- .gitattributes | 2 +- .scripts/build_steps.sh | 5 +- .scripts/run_docker_build.sh | 8 ++- .scripts/run_osx_build.sh | 56 ++++++++++++++++++ README.md | 2 +- 9 files changed, 119 insertions(+), 95 deletions(-) create mode 100755 .scripts/run_osx_build.sh diff --git a/.azure-pipelines/azure-pipelines-linux.yml b/.azure-pipelines/azure-pipelines-linux.yml index d2ef039a..a722a522 100755 --- a/.azure-pipelines/azure-pipelines-linux.yml +++ b/.azure-pipelines/azure-pipelines-linux.yml @@ -6,26 +6,27 @@ jobs: - job: linux pool: vmImage: ubuntu-16.04 - timeoutInMinutes: 360 strategy: - maxParallel: 8 matrix: linux_blas_implblisblas_impl_liblibblis.so.3: CONFIG: linux_blas_implblisblas_impl_liblibblis.so.3 - UPLOAD_PACKAGES: True + UPLOAD_PACKAGES: 'True' DOCKER_IMAGE: condaforge/linux-anvil-comp7 linux_blas_implmklblas_impl_liblibmkl_rt.so: CONFIG: linux_blas_implmklblas_impl_liblibmkl_rt.so - UPLOAD_PACKAGES: True + UPLOAD_PACKAGES: 'True' DOCKER_IMAGE: condaforge/linux-anvil-comp7 linux_blas_implopenblasblas_impl_liblibopenblas.so.0: CONFIG: linux_blas_implopenblasblas_impl_liblibopenblas.so.0 - UPLOAD_PACKAGES: True + UPLOAD_PACKAGES: 'True' DOCKER_IMAGE: condaforge/linux-anvil-comp7 linux_ppc64le_: CONFIG: linux_ppc64le_ - UPLOAD_PACKAGES: True + UPLOAD_PACKAGES: 'True' DOCKER_IMAGE: condaforge/linux-anvil-ppc64le + maxParallel: 8 + timeoutInMinutes: 360 + steps: # configure qemu binfmt-misc running. This allows us to run docker containers # embedded qemu-static @@ -41,4 +42,6 @@ jobs: .scripts/run_docker_build.sh displayName: Run docker build env: - BINSTAR_TOKEN: $(BINSTAR_TOKEN) \ No newline at end of file + BINSTAR_TOKEN: $(BINSTAR_TOKEN) + FEEDSTOCK_TOKEN: $(FEEDSTOCK_TOKEN) + STAGING_BINSTAR_TOKEN: $(STAGING_BINSTAR_TOKEN) \ No newline at end of file diff --git a/.azure-pipelines/azure-pipelines-osx.yml b/.azure-pipelines/azure-pipelines-osx.yml index 1cc08d39..b9d57135 100755 --- a/.azure-pipelines/azure-pipelines-osx.yml +++ b/.azure-pipelines/azure-pipelines-osx.yml @@ -6,77 +6,29 @@ jobs: - job: osx pool: vmImage: macOS-10.14 - timeoutInMinutes: 360 strategy: - maxParallel: 8 matrix: osx_blas_implblisblas_impl_liblibblis.3.dylib: CONFIG: osx_blas_implblisblas_impl_liblibblis.3.dylib - UPLOAD_PACKAGES: True + UPLOAD_PACKAGES: 'True' osx_blas_implmklblas_impl_liblibmkl_rt.dylib: CONFIG: osx_blas_implmklblas_impl_liblibmkl_rt.dylib - UPLOAD_PACKAGES: True + UPLOAD_PACKAGES: 'True' osx_blas_implopenblasblas_impl_liblibopenblas.0.dylib: CONFIG: osx_blas_implopenblasblas_impl_liblibopenblas.0.dylib - UPLOAD_PACKAGES: True + UPLOAD_PACKAGES: 'True' + maxParallel: 8 + timeoutInMinutes: 360 steps: # TODO: Fast finish on azure pipelines? - script: | - echo "Fast Finish" - - - - script: | - echo "Removing homebrew from Azure to avoid conflicts." - curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall > ~/uninstall_homebrew - chmod +x ~/uninstall_homebrew - ~/uninstall_homebrew -fq - rm ~/uninstall_homebrew - displayName: Remove homebrew - - - bash: | - echo "##vso[task.prependpath]$CONDA/bin" - sudo chown -R $USER $CONDA - displayName: Add conda to PATH - - - script: | - source activate base - conda install -n base -c conda-forge --quiet --yes conda-forge-ci-setup=2 conda-build - displayName: 'Add conda-forge-ci-setup=2' - - - script: | - source activate base - echo "Configuring conda." - - setup_conda_rc ./ ./recipe ./.ci_support/${CONFIG}.yaml export CI=azure - source run_conda_forge_build_setup - conda update --yes --quiet --override-channels -c conda-forge -c defaults --all - env: { - OSX_FORCE_SDK_DOWNLOAD: "1" - } - displayName: Configure conda and conda-build - - - script: | - source activate base - mangle_compiler ./ ./recipe ./.ci_support/${CONFIG}.yaml - displayName: Mangle compiler - - - script: | - source activate base - make_build_number ./ ./recipe ./.ci_support/${CONFIG}.yaml - displayName: Generate build number clobber file - - - script: | - source activate base - conda build ./recipe -m ./.ci_support/${CONFIG}.yaml --clobber-file ./.ci_support/clobber_${CONFIG}.yaml - displayName: Build recipe - - - script: | - source activate base + export OSX_FORCE_SDK_DOWNLOAD="1" export GIT_BRANCH=$BUILD_SOURCEBRANCHNAME - upload_package ./ ./recipe ./.ci_support/${CONFIG}.yaml - displayName: Upload package + ./.scripts/run_osx_build.sh + displayName: Run OSX build env: BINSTAR_TOKEN: $(BINSTAR_TOKEN) - condition: and(succeeded(), not(eq(variables['UPLOAD_PACKAGES'], 'False'))) \ No newline at end of file + FEEDSTOCK_TOKEN: $(FEEDSTOCK_TOKEN) + STAGING_BINSTAR_TOKEN: $(STAGING_BINSTAR_TOKEN) \ No newline at end of file diff --git a/.azure-pipelines/azure-pipelines-win.yml b/.azure-pipelines/azure-pipelines-win.yml index 359e454e..cbfddd7a 100755 --- a/.azure-pipelines/azure-pipelines-win.yml +++ b/.azure-pipelines/azure-pipelines-win.yml @@ -6,28 +6,23 @@ jobs: - job: win pool: vmImage: vs2017-win2016 - timeoutInMinutes: 360 strategy: - maxParallel: 4 matrix: win_blas_implblisblas_impl_liblibblis.3.dll: CONFIG: win_blas_implblisblas_impl_liblibblis.3.dll - CONDA_BLD_PATH: D:\\bld\\ - UPLOAD_PACKAGES: True + UPLOAD_PACKAGES: 'True' win_blas_implmklblas_impl_libmkl_rt.dll: CONFIG: win_blas_implmklblas_impl_libmkl_rt.dll - CONDA_BLD_PATH: D:\\bld\\ - UPLOAD_PACKAGES: True + UPLOAD_PACKAGES: 'True' win_blas_implopenblasblas_impl_libopenblas.dll: CONFIG: win_blas_implopenblasblas_impl_libopenblas.dll - CONDA_BLD_PATH: D:\\bld\\ - UPLOAD_PACKAGES: True - steps: - # TODO: Fast finish on azure pipelines? - - script: | - ECHO ON - + UPLOAD_PACKAGES: 'True' + maxParallel: 4 + timeoutInMinutes: 360 + variables: + CONDA_BLD_PATH: D:\\bld\\ + steps: - script: | choco install vcpython27 -fdv -y --debug condition: contains(variables['CONFIG'], 'vs2008') @@ -64,31 +59,32 @@ jobs: - task: CondaEnvironment@1 inputs: - packageSpecs: 'python=3.6 conda-build conda conda-forge::conda-forge-ci-setup=2' # Optional + packageSpecs: 'python=3.6 conda-build conda conda-forge::conda-forge-ci-setup=3 pip' # Optional installOptions: "-c conda-forge" updateConda: true displayName: Install conda-build and activate environment - script: set PYTHONUNBUFFERED=1 + displayName: Set PYTHONUNBUFFERED # Configure the VM - - script: setup_conda_rc .\ .\recipe .\.ci_support\%CONFIG%.yaml + - script: | + call activate base + setup_conda_rc .\ ".\recipe" .\.ci_support\%CONFIG%.yaml + displayName: conda-forge CI setup # Configure the VM. - script: | set "CI=azure" + call activate base run_conda_forge_build_setup displayName: conda-forge build setup - - script: | - rmdir C:\strawberry /s /q - continueOnError: true - displayName: remove strawberryperl - # Special cased version setting some more things! - script: | - conda.exe build recipe -m .ci_support\%CONFIG%.yaml + call activate base + conda.exe build "recipe" -m .ci_support\%CONFIG%.yaml displayName: Build recipe (vs2008) env: VS90COMNTOOLS: "C:\\Program Files (x86)\\Common Files\\Microsoft\\Visual C++ for Python\\9.0\\VC\\bin" @@ -96,16 +92,24 @@ jobs: condition: contains(variables['CONFIG'], 'vs2008') - script: | - conda.exe build recipe -m .ci_support\%CONFIG%.yaml + call activate base + conda.exe build "recipe" -m .ci_support\%CONFIG%.yaml displayName: Build recipe env: PYTHONUNBUFFERED: 1 condition: not(contains(variables['CONFIG'], 'vs2008')) + - script: | + call activate base + validate_recipe_outputs "blas-feedstock" + displayName: Validate Recipe Outputs - script: | set "GIT_BRANCH=%BUILD_SOURCEBRANCHNAME%" - upload_package .\ .\recipe .ci_support\%CONFIG%.yaml + call activate base + upload_package --validate --feedstock-name="blas-feedstock" .\ ".\recipe" .ci_support\%CONFIG%.yaml displayName: Upload package env: BINSTAR_TOKEN: $(BINSTAR_TOKEN) + FEEDSTOCK_TOKEN: $(FEEDSTOCK_TOKEN) + STAGING_BINSTAR_TOKEN: $(STAGING_BINSTAR_TOKEN) condition: and(succeeded(), not(eq(variables['UPLOAD_PACKAGES'], 'False'))) \ No newline at end of file diff --git a/.drone.yml b/.drone.yml index 8dd281ee..93b121fb 100644 --- a/.drone.yml +++ b/.drone.yml @@ -13,8 +13,12 @@ steps: CONFIG: linux_aarch64_ UPLOAD_PACKAGES: True PLATFORM: linux-aarch64 - BINSTAR_TOKEN: + BINSTAR_TOKEN: from_secret: BINSTAR_TOKEN + FEEDSTOCK_TOKEN: + from_secret: FEEDSTOCK_TOKEN + STAGING_BINSTAR_TOKEN: + from_secret: STAGING_BINSTAR_TOKEN commands: - export FEEDSTOCK_ROOT="$DRONE_WORKSPACE" - export RECIPE_ROOT="$FEEDSTOCK_ROOT/recipe" diff --git a/.gitattributes b/.gitattributes index ac943c18..9060b272 100644 --- a/.gitattributes +++ b/.gitattributes @@ -17,7 +17,7 @@ bld.bat text eol=crlf .gitattributes linguist-generated=true .gitignore linguist-generated=true .travis.yml linguist-generated=true -.scripts linguist-generated=true +.scripts/* linguist-generated=true LICENSE.txt linguist-generated=true README.md linguist-generated=true azure-pipelines.yml linguist-generated=true diff --git a/.scripts/build_steps.sh b/.scripts/build_steps.sh index 8a4af44f..750ba254 100755 --- a/.scripts/build_steps.sh +++ b/.scripts/build_steps.sh @@ -19,7 +19,7 @@ conda-build: CONDARC -conda install --yes --quiet conda-forge-ci-setup=2 conda-build -c conda-forge +conda install --yes --quiet conda-forge-ci-setup=3 conda-build pip -c conda-forge # set up the condarc setup_conda_rc "${FEEDSTOCK_ROOT}" "${RECIPE_ROOT}" "${CONFIG_FILE}" @@ -31,9 +31,10 @@ make_build_number "${FEEDSTOCK_ROOT}" "${RECIPE_ROOT}" "${CONFIG_FILE}" conda build "${RECIPE_ROOT}" -m "${CI_SUPPORT}/${CONFIG}.yaml" \ --clobber-file "${CI_SUPPORT}/clobber_${CONFIG}.yaml" +validate_recipe_outputs "blas-feedstock" if [[ "${UPLOAD_PACKAGES}" != "False" ]]; then - upload_package "${FEEDSTOCK_ROOT}" "${RECIPE_ROOT}" "${CONFIG_FILE}" + upload_package --validate --feedstock-name="blas-feedstock" "${FEEDSTOCK_ROOT}" "${RECIPE_ROOT}" "${CONFIG_FILE}" fi touch "${FEEDSTOCK_ROOT}/build_artifacts/conda-forge-build-done-${CONFIG}" \ No newline at end of file diff --git a/.scripts/run_docker_build.sh b/.scripts/run_docker_build.sh index 066a8575..360fc69c 100755 --- a/.scripts/run_docker_build.sh +++ b/.scripts/run_docker_build.sh @@ -52,13 +52,15 @@ mkdir -p "$ARTIFACTS" DONE_CANARY="$ARTIFACTS/conda-forge-build-done-${CONFIG}" rm -f "$DONE_CANARY" +# Allow people to specify extra default arguments to `docker run` (e.g. `--rm`) +DOCKER_RUN_ARGS="${CONDA_FORGE_DOCKER_RUN_ARGS}" if [ -z "${CI}" ]; then - DOCKER_RUN_ARGS="-it " + DOCKER_RUN_ARGS="-it ${DOCKER_RUN_ARGS}" fi export UPLOAD_PACKAGES="${UPLOAD_PACKAGES:-True}" docker run ${DOCKER_RUN_ARGS} \ - -v "${RECIPE_ROOT}":/home/conda/recipe_root:ro,z \ + -v "${RECIPE_ROOT}":/home/conda/recipe_root:rw,z \ -v "${FEEDSTOCK_ROOT}":/home/conda/feedstock_root:rw,z \ -e CONFIG \ -e BINSTAR_TOKEN \ @@ -67,6 +69,8 @@ docker run ${DOCKER_RUN_ARGS} \ -e GIT_BRANCH \ -e UPLOAD_ON_BRANCH \ -e CI \ + -e FEEDSTOCK_TOKEN \ + -e STAGING_BINSTAR_TOKEN \ $DOCKER_IMAGE \ bash \ /home/conda/feedstock_root/${PROVIDER_DIR}/build_steps.sh diff --git a/.scripts/run_osx_build.sh b/.scripts/run_osx_build.sh new file mode 100755 index 00000000..1e25b4fa --- /dev/null +++ b/.scripts/run_osx_build.sh @@ -0,0 +1,56 @@ +#!/usr/bin/env bash + +set -x + +echo -e "\n\nInstalling a fresh version of Miniforge." +if [[ ${CI} == "travis" ]]; then + echo -en 'travis_fold:start:install_miniforge\\r' +fi +MINIFORGE_URL="https://github.com/conda-forge/miniforge/releases/latest/download" +MINIFORGE_FILE="Miniforge3-MacOSX-x86_64.sh" +curl -L -O "${MINIFORGE_URL}/${MINIFORGE_FILE}" +bash $MINIFORGE_FILE -b +if [[ ${CI} == "travis" ]]; then + echo -en 'travis_fold:end:install_miniforge\\r' +fi + +echo -e "\n\nConfiguring conda." +if [[ ${CI} == "travis" ]]; then + echo -en 'travis_fold:start:configure_conda\\r' +fi + +source ${HOME}/miniforge3/etc/profile.d/conda.sh +conda activate base + +echo -e "\n\nInstalling conda-forge-ci-setup=3 and conda-build." +conda install -n base --quiet --yes conda-forge-ci-setup=3 conda-build pip + + + +echo -e "\n\nSetting up the condarc and mangling the compiler." +setup_conda_rc ./ ./recipe ./.ci_support/${CONFIG}.yaml +mangle_compiler ./ ./recipe .ci_support/${CONFIG}.yaml + +echo -e "\n\nMangling homebrew in the CI to avoid conflicts." +/usr/bin/sudo mangle_homebrew +/usr/bin/sudo -k + +echo -e "\n\nRunning the build setup script." +source run_conda_forge_build_setup + + +if [[ ${CI} == "travis" ]]; then + echo -en 'travis_fold:end:configure_conda\\r' +fi + +set -e + +echo -e "\n\nMaking the build clobber file and running the build." +make_build_number ./ ./recipe ./.ci_support/${CONFIG}.yaml +conda build ./recipe -m ./.ci_support/${CONFIG}.yaml --clobber-file ./.ci_support/clobber_${CONFIG}.yaml +validate_recipe_outputs "blas-feedstock" + +if [[ "${UPLOAD_PACKAGES}" != "False" ]]; then + echo -e "\n\nUploading the packages." + upload_package --validate --feedstock-name="blas-feedstock" ./ ./recipe ./.ci_support/${CONFIG}.yaml +fi \ No newline at end of file diff --git a/README.md b/README.md index 296fa2ea..f7cc8563 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ Current build status Drone - linux + linux From 248231a3da8b1bd6beea5c9d2f017c8663fe2184 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sat, 27 Jun 2020 11:50:01 -0500 Subject: [PATCH 08/14] Set fortran_compiler --- recipe/bld.bat | 2 ++ 1 file changed, 2 insertions(+) diff --git a/recipe/bld.bat b/recipe/bld.bat index 70e7ade2..2db22be7 100644 --- a/recipe/bld.bat +++ b/recipe/bld.bat @@ -12,6 +12,8 @@ set MSYSTEM=MINGW%ARCH% set MSYS2_PATH_TYPE=inherit set CHERE_INVOKING=1 set "SHLIB_PREFIX=" +set "fortran_compiler=m2w64-toolchain" +set "fortran_compiler_version=2" bash -x "./build.sh" IF %ERRORLEVEL% NEQ 0 exit 1 exit 0 From 2eb59e12b3990f1a96c3594a4fe61a5987441a2f Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sat, 27 Jun 2020 12:51:51 -0500 Subject: [PATCH 09/14] Need cmake --- recipe/build.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/recipe/build.sh b/recipe/build.sh index 50dcfc57..13bb839f 100644 --- a/recipe/build.sh +++ b/recipe/build.sh @@ -27,7 +27,9 @@ conda${EXE_SUFFIX} create -p ${NEW_ENV} -c conda-forge --yes --quiet \ libblas=${PKG_VERSION}=*netlib \ libcblas=${PKG_VERSION}=*netlib \ liblapack=${PKG_VERSION}=*netlib \ - liblapacke=${PKG_VERSION}=*netlib ${fortran_compiler}_${target_platform}=${fortran_compiler_version} + liblapacke=${PKG_VERSION}=*netlib \ + ${fortran_compiler}_${target_platform}=${fortran_compiler_version} \ + cmake # Link against the netlib libraries cmake -G "${CMAKE_GENERATOR}" .. \ From ac7c160f58201bb073705031e4315c24e297de02 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sat, 27 Jun 2020 13:06:45 -0500 Subject: [PATCH 10/14] Add to path --- recipe/build.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/recipe/build.sh b/recipe/build.sh index 13bb839f..22da0b8b 100644 --- a/recipe/build.sh +++ b/recipe/build.sh @@ -31,6 +31,8 @@ conda${EXE_SUFFIX} create -p ${NEW_ENV} -c conda-forge --yes --quiet \ ${fortran_compiler}_${target_platform}=${fortran_compiler_version} \ cmake +export PATH="$PATH:${LIBRARY_PREFIX}/bin" + # Link against the netlib libraries cmake -G "${CMAKE_GENERATOR}" .. \ "-DBLAS_LIBRARIES=${SHLIB_PREFIX}blas${SHLIB_EXT};${SHLIB_PREFIX}cblas${SHLIB_EXT}" \ From e609efb70c57fb0b9817143038e734f69f9cc1fc Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sat, 27 Jun 2020 13:35:46 -0500 Subject: [PATCH 11/14] ctest path --- recipe/test_blas.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/recipe/test_blas.sh b/recipe/test_blas.sh index caa0441a..00a1790f 100644 --- a/recipe/test_blas.sh +++ b/recipe/test_blas.sh @@ -48,4 +48,9 @@ if [[ ! "$(uname -m)" == "x86_64" ]]; then SKIP_TESTS="${SKIP_TESTS}|LAPACK-xeigtstz" fi -ctest --output-on-failure -E "${SKIP_TESTS}" + +if [[ "$target_platform" == "win-64" ]]; then + ${BUILD_PREFIX}/Library/bin/ctest --output-on-failure -E "${SKIP_TESTS}" +else + ctest --output-on-failure -E "${SKIP_TESTS}" +fi From b3a5ad8267513356868f09a59fe7cfb418f96a79 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sat, 27 Jun 2020 13:36:32 -0500 Subject: [PATCH 12/14] FIx BUILD_PREFIX path --- recipe/test_blas.bat | 1 + 1 file changed, 1 insertion(+) diff --git a/recipe/test_blas.bat b/recipe/test_blas.bat index 24682dab..72231056 100644 --- a/recipe/test_blas.bat +++ b/recipe/test_blas.bat @@ -5,6 +5,7 @@ set "MSYS2_ARG_CONV_EXCL=/AI;/AL;/OUT;/out" :: to be Unix-y rather than Windows-y, though. copy "%RECIPE_DIR%\test_blas.sh" . FOR /F "delims=" %%i IN ('cygpath.exe -u -p "%PATH%"') DO set "PATH_OVERRIDE=%%i" +FOR /F "delims=" %%i in ('cygpath.exe -u "%BUILD_PREFIX%"') DO set "BUILD_PREFIX=%%i" set MSYSTEM=MINGW%ARCH% set MSYS2_PATH_TYPE=inherit set CHERE_INVOKING=1 From 4d09409cfc572df91a4b34c79e71ea217afd0b62 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sat, 27 Jun 2020 14:01:07 -0500 Subject: [PATCH 13/14] Update bld.bat --- recipe/bld.bat | 1 + 1 file changed, 1 insertion(+) diff --git a/recipe/bld.bat b/recipe/bld.bat index 2db22be7..a04d0574 100644 --- a/recipe/bld.bat +++ b/recipe/bld.bat @@ -6,6 +6,7 @@ set "MSYS2_ARG_CONV_EXCL=/AI;/AL;/OUT;/out" copy "%RECIPE_DIR%\build.sh" . FOR /F "delims=" %%i IN ('cygpath.exe -u -p "%PATH%"') DO set "PATH_OVERRIDE=%%i" FOR /F "delims=" %%i IN ('cygpath.exe -u "%LIBRARY_PREFIX%"') DO set "PREFIX=%%i" +FOR /F "delims=" %%i in ('cygpath.exe -u "%BUILD_PREFIX%"') DO set "BUILD_PREFIX=%%i" set "SHLIB_EXT=.lib" set "CMAKE_GENERATOR=MSYS Makefiles" set MSYSTEM=MINGW%ARCH% From ea0708957478d4e73c21ce27d9ca4c09d2c65e7b Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sat, 27 Jun 2020 14:02:09 -0500 Subject: [PATCH 14/14] Fix cmake path --- recipe/build.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipe/build.sh b/recipe/build.sh index 22da0b8b..fb69414a 100644 --- a/recipe/build.sh +++ b/recipe/build.sh @@ -13,6 +13,8 @@ if [[ "$target_platform" == linux* || "$target_platform" == osx* ]]; then else export LIBRARY_PREFIX=$NEW_ENV/Library export EXE_SUFFIX=".exe" + # For finding cmake + export PATH="$PATH:${BUILD_PREFIX}/Library/bin" # necessary to escalate errors to calling bld.bat script correctly set -e fi @@ -28,10 +30,8 @@ conda${EXE_SUFFIX} create -p ${NEW_ENV} -c conda-forge --yes --quiet \ libcblas=${PKG_VERSION}=*netlib \ liblapack=${PKG_VERSION}=*netlib \ liblapacke=${PKG_VERSION}=*netlib \ - ${fortran_compiler}_${target_platform}=${fortran_compiler_version} \ - cmake + ${fortran_compiler}_${target_platform}=${fortran_compiler_version} -export PATH="$PATH:${LIBRARY_PREFIX}/bin" # Link against the netlib libraries cmake -G "${CMAKE_GENERATOR}" .. \