From b9e00b7efe0c08cffebf8fb2fa83d09cf928b6f3 Mon Sep 17 00:00:00 2001 From: julianuspfeuffer Date: Wed, 10 Apr 2024 13:53:49 +0200 Subject: [PATCH 1/9] Add windows build and remove all fortran deps --- recipe/bld.bat | 11 +++++++++++ recipe/build.sh | 44 +++++++++++++++++++++----------------------- recipe/meta.yaml | 30 +++++++++++++++++------------- 3 files changed, 49 insertions(+), 36 deletions(-) create mode 100644 recipe/bld.bat diff --git a/recipe/bld.bat b/recipe/bld.bat new file mode 100644 index 0000000..b526205 --- /dev/null +++ b/recipe/bld.bat @@ -0,0 +1,11 @@ +copy "%RECIPE_DIR%\build.sh" . +set PREFIX=%PREFIX:\=/% +set LIBRARY_PREFIX=%LIBRARY_PREFIX:\=/% +set SRC_DIR=%SRC_DIR:\=/% +set MSYSTEM=MINGW%ARCH% +set MSYS2_PATH_TYPE=inherit +set CHERE_INVOKING=1 +set BUILD_PLATFORM=win-64 + + +bash -lc "./build.sh" diff --git a/recipe/build.sh b/recipe/build.sh index 88e404d..a5d9e0c 100644 --- a/recipe/build.sh +++ b/recipe/build.sh @@ -1,32 +1,30 @@ #!/usr/bin/env bash -# Get an updated config.sub and config.guess -cp $BUILD_PREFIX/share/gnuconfig/config.* ./CoinUtils -cp $BUILD_PREFIX/share/gnuconfig/config.* . -set -e -UNAME="$(uname)" -export CFLAGS="${CFLAGS} -O3" -export CXXFLAGS="${CXXFLAGS} -O3" -export CXXFLAGS="${CXXFLAGS//-std=c++17/-std=c++11}" +set -e -if [ "${UNAME}" == "Linux" ]; then - export FLIBS="-lgcc_s -lgcc -lstdc++ -lm" +if [[ "${target_platform}" == win-* ]]; then + EXTRA_FLAGS="--enable-msvc" +else + # Get an updated config.sub and config.guess (for mac arm and lnx aarch64) + cp $BUILD_PREFIX/share/gnuconfig/config.* ./CoinUtils + cp $BUILD_PREFIX/share/gnuconfig/config.* . fi -# Use only 1 thread with OpenBLAS to avoid timeouts on CIs. -# This should have no other affect on the build. A user -# should still be able to set this (or not) to a different -# value at run-time to get the expected amount of parallelism. -export OPENBLAS_NUM_THREADS=1 - -WITH_BLAS_LIB="-L${PREFIX}/lib -lblas" -WITH_LAPACK_LIB="-L${PREFIX}/lib -llapack" +if [ ! -z ${LIBRARY_PREFIX+x} ]; then + USE_PREFIX=$LIBRARY_PREFIX +else + USE_PREFIX=$PREFIX +fi ./configure \ - --prefix="${PREFIX}" \ - --exec-prefix="${PREFIX}" \ - --with-blas-lib="${WITH_BLAS_LIB}" \ - --with-lapack-lib="${WITH_LAPACK_LIB}" \ + --prefix="${USE_PREFIX}" \ + --exec-prefix="${USE_PREFIX}" \ + ${EXTRA_FLAGS} || cat CoinUtils/config.log make -j "${CPU_COUNT}" -make install \ No newline at end of file + +if [[ "$CONDA_BUILD_CROSS_COMPILATION" != "1" ]]; then + make test +fi + +make install diff --git a/recipe/meta.yaml b/recipe/meta.yaml index 52c8c37..88b43d7 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -13,35 +13,38 @@ source: build: number: 0 - skip: true # [win] run_exports: - {{ pin_subpackage(name, min_pin='x.x', max_pin='x.x') }} requirements: build: - - gnuconfig # [unix] + - gnuconfig - {{ compiler('c') }} - {{ compiler('cxx') }} - - {{ compiler('fortran') }} - - pkg-config - - make # [unix] + - pkg-config # [unix] + - make # [unix] + - m2-make # [win] + - m2-pkg-config # [win] + - m2-grep # [win] + - m2-sed # [win] + - m2-bash # [win] + - m2-base # [win] + host: - zlib - bzip2 - - libblas - - libcblas - - liblapack - - liblapacke + run_constrained: - coincbc * *_metapackage test: commands: - - test -f $PREFIX/lib/libCoinUtils${SHLIB_EXT} - - test -f $PREFIX/include/coin/CoinSort.hpp - + - test -f $PREFIX/lib/libCoinUtils${SHLIB_EXT} # [unix] + - test -f $PREFIX/include/coin/CoinSort.hpp # [unix] + - if not exist %LIBRARY_LIB%/libCoinUtils.lib exit 1 # [win] + - if not exist %LIBRARY_INC%/coin/CoinSort.hpp exit 1 # [win] about: - home: https://projects.coin-or.org/CoinUtils + home: https://github.com/coin-or/CoinUtils dev_url: https://github.com/coin-or/CoinUtils license: EPL-2.0 license_family: OTHER @@ -65,3 +68,4 @@ extra: - wolfv - tkralphs - jschueller + - jpfeuffer From fd5500f3fd0d19c432cc0f99b4ed34fcd07ccf12 Mon Sep 17 00:00:00 2001 From: "conda-forge-webservices[bot]" <91080706+conda-forge-webservices[bot]@users.noreply.github.com> Date: Wed, 10 Apr 2024 12:03:41 +0000 Subject: [PATCH 2/9] MNT: Re-rendered with conda-build 24.3.0, conda-smithy 3.34.1, and conda-forge-pinning 2024.04.10.11.41.14 --- .azure-pipelines/azure-pipelines-win.yml | 52 ++++++++++ .ci_support/linux_64_.yaml | 13 --- .ci_support/linux_aarch64_.yaml | 13 --- .ci_support/linux_ppc64le_.yaml | 13 --- .ci_support/osx_64_.yaml | 13 --- .ci_support/osx_arm64_.yaml | 13 --- .ci_support/win_64_.yaml | 18 ++++ .github/CODEOWNERS | 2 +- .scripts/run_win_build.bat | 125 +++++++++++++++++++++++ README.md | 10 +- azure-pipelines.yml | 3 +- 11 files changed, 207 insertions(+), 68 deletions(-) create mode 100755 .azure-pipelines/azure-pipelines-win.yml create mode 100644 .ci_support/win_64_.yaml create mode 100755 .scripts/run_win_build.bat diff --git a/.azure-pipelines/azure-pipelines-win.yml b/.azure-pipelines/azure-pipelines-win.yml new file mode 100755 index 0000000..d609fcd --- /dev/null +++ b/.azure-pipelines/azure-pipelines-win.yml @@ -0,0 +1,52 @@ +# This file was generated automatically from conda-smithy. To update this configuration, +# update the conda-forge.yml and/or the recipe/meta.yaml. +# -*- mode: yaml -*- + +jobs: +- job: win + pool: + vmImage: windows-2022 + strategy: + matrix: + win_64_: + CONFIG: win_64_ + UPLOAD_PACKAGES: 'True' + timeoutInMinutes: 360 + variables: + CONDA_BLD_PATH: D:\\bld\\ + UPLOAD_TEMP: D:\\tmp + + steps: + + - task: PythonScript@0 + displayName: 'Download Miniforge' + inputs: + scriptSource: inline + script: | + import urllib.request + url = 'https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Windows-x86_64.exe' + path = r"$(Build.ArtifactStagingDirectory)/Miniforge.exe" + urllib.request.urlretrieve(url, path) + + - script: | + start /wait "" %BUILD_ARTIFACTSTAGINGDIRECTORY%\Miniforge.exe /InstallationType=JustMe /RegisterPython=0 /S /D=C:\Miniforge + displayName: Install Miniforge + + - powershell: Write-Host "##vso[task.prependpath]C:\Miniforge\Scripts" + displayName: Add conda to PATH + + - script: | + call ".scripts\run_win_build.bat" + displayName: Run Windows build + env: + PYTHONUNBUFFERED: 1 + CONFIG: $(CONFIG) + CI: azure + flow_run_id: azure_$(Build.BuildNumber).$(System.JobAttempt) + remote_url: $(Build.Repository.Uri) + sha: $(Build.SourceVersion) + UPLOAD_PACKAGES: $(UPLOAD_PACKAGES) + UPLOAD_TEMP: $(UPLOAD_TEMP) + BINSTAR_TOKEN: $(BINSTAR_TOKEN) + FEEDSTOCK_TOKEN: $(FEEDSTOCK_TOKEN) + STAGING_BINSTAR_TOKEN: $(STAGING_BINSTAR_TOKEN) \ No newline at end of file diff --git a/.ci_support/linux_64_.yaml b/.ci_support/linux_64_.yaml index 4ec3d8e..fff5136 100644 --- a/.ci_support/linux_64_.yaml +++ b/.ci_support/linux_64_.yaml @@ -20,24 +20,11 @@ cxx_compiler_version: - '12' docker_image: - quay.io/condaforge/linux-anvil-cos7-x86_64 -fortran_compiler: -- gfortran -fortran_compiler_version: -- '12' -libblas: -- 3.9 *netlib -libcblas: -- 3.9 *netlib -liblapack: -- 3.9 *netlib -liblapacke: -- 3.9 *netlib target_platform: - linux-64 zip_keys: - - c_compiler_version - cxx_compiler_version - - fortran_compiler_version - - c_stdlib_version - cdt_name zlib: diff --git a/.ci_support/linux_aarch64_.yaml b/.ci_support/linux_aarch64_.yaml index ac5ff2a..379ebd0 100644 --- a/.ci_support/linux_aarch64_.yaml +++ b/.ci_support/linux_aarch64_.yaml @@ -24,24 +24,11 @@ cxx_compiler_version: - '12' docker_image: - quay.io/condaforge/linux-anvil-aarch64 -fortran_compiler: -- gfortran -fortran_compiler_version: -- '12' -libblas: -- 3.9 *netlib -libcblas: -- 3.9 *netlib -liblapack: -- 3.9 *netlib -liblapacke: -- 3.9 *netlib target_platform: - linux-aarch64 zip_keys: - - c_compiler_version - cxx_compiler_version - - fortran_compiler_version - - c_stdlib_version - cdt_name zlib: diff --git a/.ci_support/linux_ppc64le_.yaml b/.ci_support/linux_ppc64le_.yaml index afad53a..f6f82de 100644 --- a/.ci_support/linux_ppc64le_.yaml +++ b/.ci_support/linux_ppc64le_.yaml @@ -20,24 +20,11 @@ cxx_compiler_version: - '12' docker_image: - quay.io/condaforge/linux-anvil-ppc64le -fortran_compiler: -- gfortran -fortran_compiler_version: -- '12' -libblas: -- 3.9 *netlib -libcblas: -- 3.9 *netlib -liblapack: -- 3.9 *netlib -liblapacke: -- 3.9 *netlib target_platform: - linux-ppc64le zip_keys: - - c_compiler_version - cxx_compiler_version - - fortran_compiler_version - - c_stdlib_version - cdt_name zlib: diff --git a/.ci_support/osx_64_.yaml b/.ci_support/osx_64_.yaml index 05952a9..5294afa 100644 --- a/.ci_support/osx_64_.yaml +++ b/.ci_support/osx_64_.yaml @@ -18,18 +18,6 @@ cxx_compiler: - clangxx cxx_compiler_version: - '16' -fortran_compiler: -- gfortran -fortran_compiler_version: -- '12' -libblas: -- 3.9 *netlib -libcblas: -- 3.9 *netlib -liblapack: -- 3.9 *netlib -liblapacke: -- 3.9 *netlib macos_machine: - x86_64-apple-darwin13.4.0 target_platform: @@ -37,6 +25,5 @@ target_platform: zip_keys: - - c_compiler_version - cxx_compiler_version - - fortran_compiler_version zlib: - '1.2' diff --git a/.ci_support/osx_arm64_.yaml b/.ci_support/osx_arm64_.yaml index 98c3645..dca9511 100644 --- a/.ci_support/osx_arm64_.yaml +++ b/.ci_support/osx_arm64_.yaml @@ -18,18 +18,6 @@ cxx_compiler: - clangxx cxx_compiler_version: - '16' -fortran_compiler: -- gfortran -fortran_compiler_version: -- '12' -libblas: -- 3.9 *netlib -libcblas: -- 3.9 *netlib -liblapack: -- 3.9 *netlib -liblapacke: -- 3.9 *netlib macos_machine: - arm64-apple-darwin20.0.0 target_platform: @@ -37,6 +25,5 @@ target_platform: zip_keys: - - c_compiler_version - cxx_compiler_version - - fortran_compiler_version zlib: - '1.2' diff --git a/.ci_support/win_64_.yaml b/.ci_support/win_64_.yaml new file mode 100644 index 0000000..dd07fe8 --- /dev/null +++ b/.ci_support/win_64_.yaml @@ -0,0 +1,18 @@ +bzip2: +- '1' +c_compiler: +- vs2019 +c_stdlib: +- vs +c_stdlib_version: +- '2019' +channel_sources: +- conda-forge +channel_targets: +- conda-forge main +cxx_compiler: +- vs2019 +target_platform: +- win-64 +zlib: +- '1.2' diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 59c7cdd..aef32ea 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -1 +1 @@ -* @jschueller @tkralphs @wolfv \ No newline at end of file +* @jpfeuffer @jschueller @tkralphs @wolfv \ No newline at end of file diff --git a/.scripts/run_win_build.bat b/.scripts/run_win_build.bat new file mode 100755 index 0000000..6d54697 --- /dev/null +++ b/.scripts/run_win_build.bat @@ -0,0 +1,125 @@ +:: PLEASE NOTE: This script has been automatically generated by conda-smithy. Any changes here +:: will be lost next time ``conda smithy rerender`` is run. If you would like to make permanent +:: changes to this script, consider a proposal to conda-smithy so that other feedstocks can also +:: benefit from the improvement. + +:: Note: we assume a Miniforge installation is available + +:: INPUTS (required environment variables) +:: CONFIG: name of the .ci_support/*.yaml file for this job +:: CI: azure, github_actions, or unset +:: UPLOAD_PACKAGES: true or false +:: UPLOAD_ON_BRANCH: true or false + +setlocal enableextensions enabledelayedexpansion + +call :start_group "Configuring conda" + +:: Activate the base conda environment +call activate base +:: Configure the solver +set "CONDA_SOLVER=libmamba" +if !errorlevel! neq 0 exit /b !errorlevel! +set "CONDA_LIBMAMBA_SOLVER_NO_CHANNELS_FROM_INSTALLED=1" + +:: Provision the necessary dependencies to build the recipe later +echo Installing dependencies +mamba.exe install "python=3.10" pip mamba conda-build conda-forge-ci-setup=4 "conda-build>=24.1" -c conda-forge --strict-channel-priority --yes +if !errorlevel! neq 0 exit /b !errorlevel! + +:: Set basic configuration +echo Setting up configuration +setup_conda_rc .\ ".\recipe" .\.ci_support\%CONFIG%.yaml +if !errorlevel! neq 0 exit /b !errorlevel! +echo Running build setup +CALL run_conda_forge_build_setup + + +if !errorlevel! neq 0 exit /b !errorlevel! + +if EXIST LICENSE.txt ( + echo Copying feedstock license + copy LICENSE.txt "recipe\\recipe-scripts-license.txt" +) +if NOT [%HOST_PLATFORM%] == [%BUILD_PLATFORM%] ( + if [%CROSSCOMPILING_EMULATOR%] == [] ( + set "EXTRA_CB_OPTIONS=%EXTRA_CB_OPTIONS% --no-test" + ) +) + +if NOT [%flow_run_id%] == [] ( + set "EXTRA_CB_OPTIONS=%EXTRA_CB_OPTIONS% --extra-meta flow_run_id=%flow_run_id% remote_url=%remote_url% sha=%sha%" +) + +call :end_group + +:: Build the recipe +echo Building recipe +conda-build.exe "recipe" -m .ci_support\%CONFIG%.yaml --suppress-variables %EXTRA_CB_OPTIONS% +if !errorlevel! neq 0 exit /b !errorlevel! + +:: Prepare some environment variables for the upload step +if /i "%CI%" == "github_actions" ( + set "FEEDSTOCK_NAME=%GITHUB_REPOSITORY:*/=%" + set "GIT_BRANCH=%GITHUB_REF:refs/heads/=%" + if /i "%GITHUB_EVENT_NAME%" == "pull_request" ( + set "IS_PR_BUILD=True" + ) else ( + set "IS_PR_BUILD=False" + ) + set "TEMP=%RUNNER_TEMP%" +) +if /i "%CI%" == "azure" ( + set "FEEDSTOCK_NAME=%BUILD_REPOSITORY_NAME:*/=%" + set "GIT_BRANCH=%BUILD_SOURCEBRANCHNAME%" + if /i "%BUILD_REASON%" == "PullRequest" ( + set "IS_PR_BUILD=True" + ) else ( + set "IS_PR_BUILD=False" + ) + set "TEMP=%UPLOAD_TEMP%" +) + +:: Validate +call :start_group "Validating outputs" +validate_recipe_outputs "%FEEDSTOCK_NAME%" +if !errorlevel! neq 0 exit /b !errorlevel! +call :end_group + +if /i "%UPLOAD_PACKAGES%" == "true" ( + if /i "%IS_PR_BUILD%" == "false" ( + call :start_group "Uploading packages" + if not exist "%TEMP%\" md "%TEMP%" + set "TMP=%TEMP%" + upload_package --validate --feedstock-name="%FEEDSTOCK_NAME%" .\ ".\recipe" .ci_support\%CONFIG%.yaml + if !errorlevel! neq 0 exit /b !errorlevel! + call :end_group + ) +) + +exit + +:: Logging subroutines + +:start_group +if /i "%CI%" == "github_actions" ( + echo ::group::%~1 + exit /b +) +if /i "%CI%" == "azure" ( + echo ##[group]%~1 + exit /b +) +echo %~1 +exit /b + +:end_group +if /i "%CI%" == "github_actions" ( + echo ::endgroup:: + exit /b +) +if /i "%CI%" == "azure" ( + echo ##[endgroup] + exit /b +) +exit /b \ No newline at end of file diff --git a/README.md b/README.md index 81c673d..832817c 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ About coin-or-utils-feedstock Feedstock license: [BSD-3-Clause](https://github.com/conda-forge/coin-or-utils-feedstock/blob/main/LICENSE.txt) -Home: https://projects.coin-or.org/CoinUtils +Home: https://github.com/coin-or/CoinUtils Package license: EPL-2.0 @@ -83,6 +83,13 @@ Current build status variant + + win_64 + + + variant + + @@ -212,6 +219,7 @@ In order to produce a uniquely identifiable distribution: Feedstock Maintainers ===================== +* [@jpfeuffer](https://github.com/jpfeuffer/) * [@jschueller](https://github.com/jschueller/) * [@tkralphs](https://github.com/tkralphs/) * [@wolfv](https://github.com/wolfv/) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 33a441c..e5306da 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -4,4 +4,5 @@ jobs: - template: ./.azure-pipelines/azure-pipelines-linux.yml - - template: ./.azure-pipelines/azure-pipelines-osx.yml \ No newline at end of file + - template: ./.azure-pipelines/azure-pipelines-osx.yml + - template: ./.azure-pipelines/azure-pipelines-win.yml \ No newline at end of file From 2931d12583525607a3cc7abf39e29e80001ccd02 Mon Sep 17 00:00:00 2001 From: julianuspfeuffer Date: Wed, 10 Apr 2024 16:32:00 +0200 Subject: [PATCH 3/9] add back some things --- recipe/build.sh | 4 ++++ recipe/meta.yaml | 28 +++++++++++++++++----------- 2 files changed, 21 insertions(+), 11 deletions(-) diff --git a/recipe/build.sh b/recipe/build.sh index a5d9e0c..2e9d1a5 100644 --- a/recipe/build.sh +++ b/recipe/build.sh @@ -3,11 +3,15 @@ set -e if [[ "${target_platform}" == win-* ]]; then + ls -la ${LIBRARY_PREFIX}/lib/ EXTRA_FLAGS="--enable-msvc" + BLAS_LIB="--with-blas-lib=\"${LIBRARY_PREFIX}/lib/openblas.lib\"" else # Get an updated config.sub and config.guess (for mac arm and lnx aarch64) cp $BUILD_PREFIX/share/gnuconfig/config.* ./CoinUtils cp $BUILD_PREFIX/share/gnuconfig/config.* . + BLAS_LIB="--with-blas-lib=\"-L${PREFIX}/lib -lblas\"" + LAPACK_LIB="--with-lapack-lib=\"-L${PREFIX}/lib -llapack\"" fi if [ ! -z ${LIBRARY_PREFIX+x} ]; then diff --git a/recipe/meta.yaml b/recipe/meta.yaml index 88b43d7..33b47f1 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -21,16 +21,22 @@ requirements: - gnuconfig - {{ compiler('c') }} - {{ compiler('cxx') }} - - pkg-config # [unix] - - make # [unix] - - m2-make # [win] - - m2-pkg-config # [win] - - m2-grep # [win] - - m2-sed # [win] - - m2-bash # [win] - - m2-base # [win] + - {{ compiler('fortran') }} # [unix] + - pkg-config # [unix] + - make # [unix] + - m2-make # [win] + - m2-pkg-config # [win] + - m2-grep # [win] + - m2-sed # [win] + - m2-bash # [win] + - m2-base # [win] host: + - blas-devel + - libblas # [unix] + - libcblas + - liblapack # [unix] + - liblapacke # [unix] - zlib - bzip2 @@ -39,9 +45,9 @@ requirements: test: commands: - - test -f $PREFIX/lib/libCoinUtils${SHLIB_EXT} # [unix] - - test -f $PREFIX/include/coin/CoinSort.hpp # [unix] - - if not exist %LIBRARY_LIB%/libCoinUtils.lib exit 1 # [win] + - test -f $PREFIX/lib/libCoinUtils${SHLIB_EXT} # [unix] + - test -f $PREFIX/include/coin/CoinSort.hpp # [unix] + - if not exist %LIBRARY_LIB%/libCoinUtils.lib exit 1 # [win] - if not exist %LIBRARY_INC%/coin/CoinSort.hpp exit 1 # [win] about: home: https://github.com/coin-or/CoinUtils From 497063579559b8b21381768d614de10c7c0ae13a Mon Sep 17 00:00:00 2001 From: julianuspfeuffer Date: Wed, 10 Apr 2024 16:49:55 +0200 Subject: [PATCH 4/9] forgot to add vars to make --- recipe/meta.yaml | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/recipe/meta.yaml b/recipe/meta.yaml index 33b47f1..cb73155 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -21,22 +21,22 @@ requirements: - gnuconfig - {{ compiler('c') }} - {{ compiler('cxx') }} - - {{ compiler('fortran') }} # [unix] - - pkg-config # [unix] - - make # [unix] - - m2-make # [win] - - m2-pkg-config # [win] - - m2-grep # [win] - - m2-sed # [win] - - m2-bash # [win] - - m2-base # [win] + - {{ compiler('fortran') }} # [unix] + - pkg-config # [unix] + - make # [unix] + - m2-make # [win] + - m2-pkg-config # [win] + - m2-grep # [win] + - m2-sed # [win] + - m2-bash # [win] + - m2-base # [win] host: - blas-devel - - libblas # [unix] + - libblas # [unix] - libcblas - - liblapack # [unix] - - liblapacke # [unix] + - liblapack # [unix] + - liblapacke # [unix] - zlib - bzip2 From c5ef1f5d46709909386ca1649792da7463a7b05a Mon Sep 17 00:00:00 2001 From: "conda-forge-webservices[bot]" <91080706+conda-forge-webservices[bot]@users.noreply.github.com> Date: Wed, 10 Apr 2024 14:57:49 +0000 Subject: [PATCH 5/9] MNT: Re-rendered with conda-build 24.3.0, conda-smithy 3.34.1, and conda-forge-pinning 2024.04.10.11.41.14 --- .ci_support/linux_64_.yaml | 13 +++++++++++++ .ci_support/linux_aarch64_.yaml | 13 +++++++++++++ .ci_support/linux_ppc64le_.yaml | 13 +++++++++++++ .ci_support/osx_64_.yaml | 13 +++++++++++++ .ci_support/osx_arm64_.yaml | 13 +++++++++++++ .ci_support/win_64_.yaml | 2 ++ 6 files changed, 67 insertions(+) diff --git a/.ci_support/linux_64_.yaml b/.ci_support/linux_64_.yaml index fff5136..4ec3d8e 100644 --- a/.ci_support/linux_64_.yaml +++ b/.ci_support/linux_64_.yaml @@ -20,11 +20,24 @@ cxx_compiler_version: - '12' docker_image: - quay.io/condaforge/linux-anvil-cos7-x86_64 +fortran_compiler: +- gfortran +fortran_compiler_version: +- '12' +libblas: +- 3.9 *netlib +libcblas: +- 3.9 *netlib +liblapack: +- 3.9 *netlib +liblapacke: +- 3.9 *netlib target_platform: - linux-64 zip_keys: - - c_compiler_version - cxx_compiler_version + - fortran_compiler_version - - c_stdlib_version - cdt_name zlib: diff --git a/.ci_support/linux_aarch64_.yaml b/.ci_support/linux_aarch64_.yaml index 379ebd0..ac5ff2a 100644 --- a/.ci_support/linux_aarch64_.yaml +++ b/.ci_support/linux_aarch64_.yaml @@ -24,11 +24,24 @@ cxx_compiler_version: - '12' docker_image: - quay.io/condaforge/linux-anvil-aarch64 +fortran_compiler: +- gfortran +fortran_compiler_version: +- '12' +libblas: +- 3.9 *netlib +libcblas: +- 3.9 *netlib +liblapack: +- 3.9 *netlib +liblapacke: +- 3.9 *netlib target_platform: - linux-aarch64 zip_keys: - - c_compiler_version - cxx_compiler_version + - fortran_compiler_version - - c_stdlib_version - cdt_name zlib: diff --git a/.ci_support/linux_ppc64le_.yaml b/.ci_support/linux_ppc64le_.yaml index f6f82de..afad53a 100644 --- a/.ci_support/linux_ppc64le_.yaml +++ b/.ci_support/linux_ppc64le_.yaml @@ -20,11 +20,24 @@ cxx_compiler_version: - '12' docker_image: - quay.io/condaforge/linux-anvil-ppc64le +fortran_compiler: +- gfortran +fortran_compiler_version: +- '12' +libblas: +- 3.9 *netlib +libcblas: +- 3.9 *netlib +liblapack: +- 3.9 *netlib +liblapacke: +- 3.9 *netlib target_platform: - linux-ppc64le zip_keys: - - c_compiler_version - cxx_compiler_version + - fortran_compiler_version - - c_stdlib_version - cdt_name zlib: diff --git a/.ci_support/osx_64_.yaml b/.ci_support/osx_64_.yaml index 5294afa..05952a9 100644 --- a/.ci_support/osx_64_.yaml +++ b/.ci_support/osx_64_.yaml @@ -18,6 +18,18 @@ cxx_compiler: - clangxx cxx_compiler_version: - '16' +fortran_compiler: +- gfortran +fortran_compiler_version: +- '12' +libblas: +- 3.9 *netlib +libcblas: +- 3.9 *netlib +liblapack: +- 3.9 *netlib +liblapacke: +- 3.9 *netlib macos_machine: - x86_64-apple-darwin13.4.0 target_platform: @@ -25,5 +37,6 @@ target_platform: zip_keys: - - c_compiler_version - cxx_compiler_version + - fortran_compiler_version zlib: - '1.2' diff --git a/.ci_support/osx_arm64_.yaml b/.ci_support/osx_arm64_.yaml index dca9511..98c3645 100644 --- a/.ci_support/osx_arm64_.yaml +++ b/.ci_support/osx_arm64_.yaml @@ -18,6 +18,18 @@ cxx_compiler: - clangxx cxx_compiler_version: - '16' +fortran_compiler: +- gfortran +fortran_compiler_version: +- '12' +libblas: +- 3.9 *netlib +libcblas: +- 3.9 *netlib +liblapack: +- 3.9 *netlib +liblapacke: +- 3.9 *netlib macos_machine: - arm64-apple-darwin20.0.0 target_platform: @@ -25,5 +37,6 @@ target_platform: zip_keys: - - c_compiler_version - cxx_compiler_version + - fortran_compiler_version zlib: - '1.2' diff --git a/.ci_support/win_64_.yaml b/.ci_support/win_64_.yaml index dd07fe8..7764528 100644 --- a/.ci_support/win_64_.yaml +++ b/.ci_support/win_64_.yaml @@ -12,6 +12,8 @@ channel_targets: - conda-forge main cxx_compiler: - vs2019 +libcblas: +- 3.9 *netlib target_platform: - win-64 zlib: From ce4c38ec9870ece7d42a8b73706225b9febd6e2b Mon Sep 17 00:00:00 2001 From: julianuspfeuffer Date: Wed, 10 Apr 2024 17:09:11 +0200 Subject: [PATCH 6/9] netlib cblas during build on win --- recipe/build.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/recipe/build.sh b/recipe/build.sh index 2e9d1a5..a132982 100644 --- a/recipe/build.sh +++ b/recipe/build.sh @@ -5,7 +5,7 @@ set -e if [[ "${target_platform}" == win-* ]]; then ls -la ${LIBRARY_PREFIX}/lib/ EXTRA_FLAGS="--enable-msvc" - BLAS_LIB="--with-blas-lib=\"${LIBRARY_PREFIX}/lib/openblas.lib\"" + BLAS_LIB="--with-blas-lib=\"${LIBRARY_PREFIX}/lib/cblas.lib\"" else # Get an updated config.sub and config.guess (for mac arm and lnx aarch64) cp $BUILD_PREFIX/share/gnuconfig/config.* ./CoinUtils @@ -23,6 +23,8 @@ fi ./configure \ --prefix="${USE_PREFIX}" \ --exec-prefix="${USE_PREFIX}" \ + ${BLAS_LIB} \ + ${LAPACK_LIB} \ ${EXTRA_FLAGS} || cat CoinUtils/config.log make -j "${CPU_COUNT}" From a60d62d16b4e00f4865449989e875aa89e08dd3e Mon Sep 17 00:00:00 2001 From: julianuspfeuffer Date: Wed, 10 Apr 2024 17:36:39 +0200 Subject: [PATCH 7/9] annoying bash quotes --- recipe/build.sh | 32 +++++++++++++++++++------------- 1 file changed, 19 insertions(+), 13 deletions(-) diff --git a/recipe/build.sh b/recipe/build.sh index a132982..8eeef74 100644 --- a/recipe/build.sh +++ b/recipe/build.sh @@ -2,30 +2,36 @@ set -e +if [ ! -z ${LIBRARY_PREFIX+x} ]; then + USE_PREFIX=$LIBRARY_PREFIX +else + USE_PREFIX=$PREFIX +fi + if [[ "${target_platform}" == win-* ]]; then ls -la ${LIBRARY_PREFIX}/lib/ EXTRA_FLAGS="--enable-msvc" - BLAS_LIB="--with-blas-lib=\"${LIBRARY_PREFIX}/lib/cblas.lib\"" + BLAS_LIB="${LIBRARY_PREFIX}/lib/cblas.lib" + + ./configure \ + --prefix="${USE_PREFIX}" \ + --exec-prefix="${USE_PREFIX}" \ + --with-blas-lib="${BLAS_LIB}" \ + ${EXTRA_FLAGS} || cat CoinUtils/config.log else # Get an updated config.sub and config.guess (for mac arm and lnx aarch64) cp $BUILD_PREFIX/share/gnuconfig/config.* ./CoinUtils cp $BUILD_PREFIX/share/gnuconfig/config.* . - BLAS_LIB="--with-blas-lib=\"-L${PREFIX}/lib -lblas\"" - LAPACK_LIB="--with-lapack-lib=\"-L${PREFIX}/lib -llapack\"" -fi + BLAS_LIB="-L${PREFIX}/lib -lblas" + LAPACK_LIB="-L${PREFIX}/lib -llapack" -if [ ! -z ${LIBRARY_PREFIX+x} ]; then - USE_PREFIX=$LIBRARY_PREFIX -else - USE_PREFIX=$PREFIX -fi - -./configure \ + ./configure \ --prefix="${USE_PREFIX}" \ --exec-prefix="${USE_PREFIX}" \ - ${BLAS_LIB} \ - ${LAPACK_LIB} \ + --with-blas-lib="${BLAS_LIB}" \ + --with-lapack-lib="${LAPACK_LIB}" \ ${EXTRA_FLAGS} || cat CoinUtils/config.log +fi make -j "${CPU_COUNT}" From be37221f16a18eb095b01ed143201870ffc15517 Mon Sep 17 00:00:00 2001 From: Ted Ralphs Date: Thu, 11 Apr 2024 10:10:38 -0400 Subject: [PATCH 8/9] Link Lapack on Windows --- recipe/build.sh | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) diff --git a/recipe/build.sh b/recipe/build.sh index 8eeef74..a136ac4 100644 --- a/recipe/build.sh +++ b/recipe/build.sh @@ -9,30 +9,24 @@ else fi if [[ "${target_platform}" == win-* ]]; then - ls -la ${LIBRARY_PREFIX}/lib/ EXTRA_FLAGS="--enable-msvc" BLAS_LIB="${LIBRARY_PREFIX}/lib/cblas.lib" - - ./configure \ - --prefix="${USE_PREFIX}" \ - --exec-prefix="${USE_PREFIX}" \ - --with-blas-lib="${BLAS_LIB}" \ - ${EXTRA_FLAGS} || cat CoinUtils/config.log + LAPACK_LIB="${LIBRARY_PREFIX}/lib/lapack.lib" else # Get an updated config.sub and config.guess (for mac arm and lnx aarch64) cp $BUILD_PREFIX/share/gnuconfig/config.* ./CoinUtils cp $BUILD_PREFIX/share/gnuconfig/config.* . BLAS_LIB="-L${PREFIX}/lib -lblas" LAPACK_LIB="-L${PREFIX}/lib -llapack" - - ./configure \ - --prefix="${USE_PREFIX}" \ - --exec-prefix="${USE_PREFIX}" \ - --with-blas-lib="${BLAS_LIB}" \ - --with-lapack-lib="${LAPACK_LIB}" \ - ${EXTRA_FLAGS} || cat CoinUtils/config.log fi +./configure \ + --prefix="${USE_PREFIX}" \ + --exec-prefix="${USE_PREFIX}" \ + --with-blas-lib="${BLAS_LIB}" \ + --with-lapack-lib="${LAPACK_LIB}" \ + ${EXTRA_FLAGS} || cat CoinUtils/config.log + make -j "${CPU_COUNT}" if [[ "$CONDA_BUILD_CROSS_COMPILATION" != "1" ]]; then From 024151f2bba2fdf87a1126e7aa70b6cf24774ad0 Mon Sep 17 00:00:00 2001 From: Julianus Pfeuffer Date: Thu, 11 Apr 2024 16:38:47 +0200 Subject: [PATCH 9/9] add lapack to win in meta.yml --- recipe/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipe/meta.yaml b/recipe/meta.yaml index cb73155..721b1c0 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -35,7 +35,7 @@ requirements: - blas-devel - libblas # [unix] - libcblas - - liblapack # [unix] + - liblapack - liblapacke # [unix] - zlib - bzip2