From 5a0a8c64c27d0059d20a61fbf1b3957cbb753ffd Mon Sep 17 00:00:00 2001 From: Ted Kisner Date: Tue, 2 Apr 2024 14:01:30 -0700 Subject: [PATCH 1/8] Fix OpenMP dynamic linking across the environment --- .github/workflows/test.yml | 3 +++ pkgs/libactpol/meta.yaml | 16 ++++++++++------ pkgs/libactpol_deps/meta.yaml | 4 ++-- pkgs/moby2/meta.yaml | 15 ++++++++------- pkgs/pixell/meta.yaml | 13 +++++++------ pkgs/qpoint/meta.yaml | 13 +++++++------ pkgs/so3g/build.sh | 2 +- pkgs/so3g/meta.yaml | 13 +++++++------ pkgs/toast/meta.yaml | 19 +++++++++---------- 9 files changed, 54 insertions(+), 44 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e4e63e7..a0da4a0 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -70,6 +70,9 @@ jobs: export OMP_NUM_THREADS=2 && export MPI_DISABLE=1 && export CI=1 && + python3 -c 'import scipy; import toast' && + python3 -c 'import so3g; from spt3g import core' && + python3 -c 'from sotodlib import core' && python3 -c 'import toast.tests; toast.tests.run()' && git clone --depth=1 --single-branch --branch=master https://github.com/simonsobs/sotodlib.git && pushd sotodlib && diff --git a/pkgs/libactpol/meta.yaml b/pkgs/libactpol/meta.yaml index e7aea91..6fb8643 100644 --- a/pkgs/libactpol/meta.yaml +++ b/pkgs/libactpol/meta.yaml @@ -27,10 +27,11 @@ requirements: - m4 - libtool host: - - llvm-openmp - - _openmp_mutex * *_llvm - - libopenblas * openmp_* - - openblas * openmp_* + - llvm-openmp # [osx] + - libgomp # [linux] + - libopenblas * *openmp* + - libblas * *openblas + - liblapack # This constraint is to force compatibility with the healpy package. # remove once healpy is building with cfitsio-4.4.x. - cfitsio <4.4.0 @@ -41,9 +42,12 @@ requirements: - libxcrypt1 # [linux] run: - llvm-openmp # [osx] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas + - liblapack - {{ pin_compatible("cfitsio") }} + - {{ pin_compatible("libblas") }} + - {{ pin_compatible("liblapack") }} - {{ pin_compatible("libactpol_deps") }} - {{ pin_compatible("wcslib") }} diff --git a/pkgs/libactpol_deps/meta.yaml b/pkgs/libactpol_deps/meta.yaml index 98da880..d66adfb 100644 --- a/pkgs/libactpol_deps/meta.yaml +++ b/pkgs/libactpol_deps/meta.yaml @@ -30,8 +30,8 @@ requirements: host: - llvm-openmp # [osx] - libgomp # [linux] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas - liblapack - zziplib run: diff --git a/pkgs/moby2/meta.yaml b/pkgs/moby2/meta.yaml index 61c3821..9b9cd0b 100644 --- a/pkgs/moby2/meta.yaml +++ b/pkgs/moby2/meta.yaml @@ -11,7 +11,7 @@ source: url: https://github.com/ACTCollaboration/moby2/archive/{{ version }}.tar.gz sha256: {{ sha256 }} patches: - - dep_names.patch + # - dep_names.patch - np_bool.patch build: @@ -25,8 +25,8 @@ requirements: host: - llvm-openmp # [osx] - libgomp # [linux] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas - liblapack - python - fftw @@ -40,16 +40,17 @@ requirements: - numba run: - llvm-openmp # [osx] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas + - liblapack - {{ pin_compatible("numpy") }} + - {{ pin_compatible("scipy") }} - {{ pin_compatible("fftw") }} + - {{ pin_compatible("libblas") }} - {{ pin_compatible("liblapack") }} - {{ pin_compatible("gsl") }} - {{ pin_compatible("libactpol") }} - python - - numpy - - scipy - future - matplotlib - astropy diff --git a/pkgs/pixell/meta.yaml b/pkgs/pixell/meta.yaml index a0aa11a..9df2567 100644 --- a/pkgs/pixell/meta.yaml +++ b/pkgs/pixell/meta.yaml @@ -29,8 +29,8 @@ requirements: host: - llvm-openmp # [osx] - libgomp # [linux] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas - liblapack - python - cython @@ -48,13 +48,14 @@ requirements: - libxcrypt1 # [linux] run: - llvm-openmp # [osx] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas + - liblapack - {{ pin_compatible("numpy") }} + - {{ pin_compatible("scipy") }} + - {{ pin_compatible("libblas") }} - {{ pin_compatible("liblapack") }} - python - - numpy - - scipy - astropy - healpy - matplotlib diff --git a/pkgs/qpoint/meta.yaml b/pkgs/qpoint/meta.yaml index 8bbcd65..cd72dda 100644 --- a/pkgs/qpoint/meta.yaml +++ b/pkgs/qpoint/meta.yaml @@ -24,8 +24,8 @@ requirements: host: - llvm-openmp # [osx] - libgomp # [linux] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas - liblapack - python - setuptools @@ -39,13 +39,14 @@ requirements: - astropy run: - llvm-openmp # [osx] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas + - liblapack - {{ pin_compatible("numpy") }} + - {{ pin_compatible("scipy") }} + - {{ pin_compatible("libblas") }} - {{ pin_compatible("liblapack") }} - python - - numpy - - scipy - astropy test: diff --git a/pkgs/so3g/build.sh b/pkgs/so3g/build.sh index f51159f..22b93a8 100755 --- a/pkgs/so3g/build.sh +++ b/pkgs/so3g/build.sh @@ -2,7 +2,7 @@ set -e set -x -CFLAGS="-O3 -g -fPIC" \ +CFLAGS="-O3 -g -fPIC -I${PREFIX}/include" \ CXXFLAGS='-O3 -g -fPIC -std=c++14' \ BOOST_ROOT="${PREFIX}" \ FLAC_ROOT="${PREFIX}" \ diff --git a/pkgs/so3g/meta.yaml b/pkgs/so3g/meta.yaml index c83c850..17c60a8 100644 --- a/pkgs/so3g/meta.yaml +++ b/pkgs/so3g/meta.yaml @@ -31,8 +31,8 @@ requirements: host: - llvm-openmp # [osx] - libgomp # [linux] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas - liblapack - python - numpy >=1.26 @@ -47,16 +47,17 @@ requirements: - numba run: - llvm-openmp # [osx] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas + - liblapack - {{ pin_compatible("numpy") }} + - {{ pin_compatible("scipy") }} + - {{ pin_compatible("libblas") }} - {{ pin_compatible("liblapack") }} - {{ pin_compatible("libboost-python") }} - {{ pin_compatible("libboost") }} - {{ pin_compatible("libflac") }} - python - - numpy - - scipy - astropy - qpoint - matplotlib diff --git a/pkgs/toast/meta.yaml b/pkgs/toast/meta.yaml index 75ba162..58f828f 100644 --- a/pkgs/toast/meta.yaml +++ b/pkgs/toast/meta.yaml @@ -11,8 +11,8 @@ package: source: url: https://github.com/hpc4cmb/toast/archive/refs/tags/{{ version }}.tar.gz sha256: {{ sha256 }} - patches: - - openmp_linking.patch + #patches: + # - openmp_linking.patch # - debug_lapack.patch build: @@ -31,9 +31,8 @@ requirements: host: - llvm-openmp # [osx] - libgomp # [linux] - - openblas * openmp_* - - libopenblas * openmp_* - - libblas + - libopenblas * *openmp* + - libblas * *openblas - liblapack - python - numpy >=1.26 @@ -44,9 +43,11 @@ requirements: - libflac run: - llvm-openmp # [osx] - - openblas * openmp_* - - libopenblas * openmp_* + - libopenblas * *openmp* + - libblas * *openblas + - liblapack - {{ pin_compatible("numpy") }} + - {{ pin_compatible("scipy") }} - {{ pin_compatible("fftw") }} - {{ pin_compatible("libblas") }} - {{ pin_compatible("liblapack") }} @@ -54,8 +55,6 @@ requirements: - {{ pin_compatible("libaatm") }} - {{ pin_compatible("libflac") }} - python - - numpy - - scipy - ruamel.yaml - matplotlib - astropy @@ -65,7 +64,7 @@ requirements: - tomlkit - traitlets>=5.0 - psutil - - pshmem>=1.0.4 + - pshmem>=1.1.0 test: imports: From 6585639fb3ae17004641d274912d580c9ae6b9a6 Mon Sep 17 00:00:00 2001 From: Ted Kisner Date: Tue, 2 Apr 2024 14:20:06 -0700 Subject: [PATCH 2/8] Bump so3g version, add include directory to cxxflags --- pkgs/so3g/build.sh | 2 +- pkgs/so3g/meta.yaml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/so3g/build.sh b/pkgs/so3g/build.sh index 22b93a8..440d2cf 100755 --- a/pkgs/so3g/build.sh +++ b/pkgs/so3g/build.sh @@ -3,7 +3,7 @@ set -e set -x CFLAGS="-O3 -g -fPIC -I${PREFIX}/include" \ -CXXFLAGS='-O3 -g -fPIC -std=c++14' \ +CXXFLAGS="-O3 -g -fPIC -std=c++14 -I${PREFIX}/include" \ BOOST_ROOT="${PREFIX}" \ FLAC_ROOT="${PREFIX}" \ python -m pip install -vvv --ignore-installed --no-deps --prefix "${PREFIX}" . diff --git a/pkgs/so3g/meta.yaml b/pkgs/so3g/meta.yaml index 17c60a8..8c1ba2f 100644 --- a/pkgs/so3g/meta.yaml +++ b/pkgs/so3g/meta.yaml @@ -1,5 +1,5 @@ -{% set version = "0.1.12" %} -{% set sha256 = "7028a87fc6b4b85b1c18bc7cfbb24da90506e84c7a13186fa4d32b93855d6b41" %} +{% set version = "0.1.13" %} +{% set sha256 = "468b1a813fa1baf1134f7041898380b0552fe3a02f0fdbe450ac1e452bbae349" %} {% set build = 0 %} From 2b95a47531f588c7c038aaff51755290a8657e61 Mon Sep 17 00:00:00 2001 From: Ted Kisner Date: Wed, 3 Apr 2024 20:45:04 -0700 Subject: [PATCH 3/8] Additional work on openmp conflicts --- config/common.txt | 4 ---- pkgs/libactpol/meta.yaml | 16 +++++++--------- pkgs/libactpol_deps/meta.yaml | 6 ++---- pkgs/moby2/meta.yaml | 8 ++++---- pkgs/pixell/meta.yaml | 7 ++----- pkgs/qpoint/meta.yaml | 8 ++++---- pkgs/so3g/build.sh | 4 ++-- pkgs/so3g/meta.yaml | 13 ++++++------- pkgs/so3g/parallel.patch | 17 +++++++++++++++++ pkgs/toast/meta.yaml | 8 ++++---- 10 files changed, 48 insertions(+), 43 deletions(-) create mode 100644 pkgs/so3g/parallel.patch diff --git a/config/common.txt b/config/common.txt index 296623c..2f1bf59 100644 --- a/config/common.txt +++ b/config/common.txt @@ -13,12 +13,8 @@ packaging # # Require the OpenBLAS + OpenMP flavor of linear algebra packages # -openblas=*=openmp_* libopenblas=*=openmp_* libblas=*=*openblas -libcblas=*=*openblas -liblapack=*=*openblas -liblapacke=*=*openblas # # Install requirements of our local and pip packages # diff --git a/pkgs/libactpol/meta.yaml b/pkgs/libactpol/meta.yaml index 6fb8643..c379071 100644 --- a/pkgs/libactpol/meta.yaml +++ b/pkgs/libactpol/meta.yaml @@ -14,12 +14,15 @@ source: build: number: {{ build }} skip: true # [win] - run_exports: - - libactpol + # run_exports: + # - libactpol requirements: build: - {{ compiler('c') }} + # This is required to ensure consistent use of libgfortran + # across the stack. + - {{ compiler('fortran') }} - llvm-openmp # [osx] - make - automake @@ -28,13 +31,9 @@ requirements: - libtool host: - llvm-openmp # [osx] - - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - - liblapack - # This constraint is to force compatibility with the healpy package. - # remove once healpy is building with cfitsio-4.4.x. - - cfitsio <4.4.0 + - cfitsio - wcslib - libactpol_deps # Remove until this perl bug is fixed @@ -44,10 +43,9 @@ requirements: - llvm-openmp # [osx] - libopenblas * *openmp* - libblas * *openblas - - liblapack - {{ pin_compatible("cfitsio") }} + - {{ pin_compatible("libopenblas") }} - {{ pin_compatible("libblas") }} - - {{ pin_compatible("liblapack") }} - {{ pin_compatible("libactpol_deps") }} - {{ pin_compatible("wcslib") }} diff --git a/pkgs/libactpol_deps/meta.yaml b/pkgs/libactpol_deps/meta.yaml index d66adfb..7961991 100644 --- a/pkgs/libactpol_deps/meta.yaml +++ b/pkgs/libactpol_deps/meta.yaml @@ -14,8 +14,8 @@ source: build: number: {{ build }} skip: true # [win] - run_exports: - - libactpol_deps + # run_exports: + # - libactpol_deps requirements: build: @@ -29,10 +29,8 @@ requirements: - make host: - llvm-openmp # [osx] - - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - - liblapack - zziplib run: diff --git a/pkgs/moby2/meta.yaml b/pkgs/moby2/meta.yaml index 9b9cd0b..1027d35 100644 --- a/pkgs/moby2/meta.yaml +++ b/pkgs/moby2/meta.yaml @@ -21,13 +21,14 @@ build: requirements: build: - {{ compiler('c') }} + # This is required to ensure consistent use of libgfortran + # across the stack. + - {{ compiler('fortran') }} - llvm-openmp # [osx] host: - llvm-openmp # [osx] - - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - - liblapack - python - fftw - gsl @@ -42,12 +43,11 @@ requirements: - llvm-openmp # [osx] - libopenblas * *openmp* - libblas * *openblas - - liblapack - {{ pin_compatible("numpy") }} - {{ pin_compatible("scipy") }} - {{ pin_compatible("fftw") }} + - {{ pin_compatible("libopenblas") }} - {{ pin_compatible("libblas") }} - - {{ pin_compatible("liblapack") }} - {{ pin_compatible("gsl") }} - {{ pin_compatible("libactpol") }} - python diff --git a/pkgs/pixell/meta.yaml b/pkgs/pixell/meta.yaml index 9df2567..37e6f95 100644 --- a/pkgs/pixell/meta.yaml +++ b/pkgs/pixell/meta.yaml @@ -1,5 +1,5 @@ {% set version = "0.23.8" %} -{% set sha256 = "1f9f89193550892e8e90b95d7fccfaf57d47ff5e99b45854e95231eb5a919a4f" %} +{% set sha256 = "b50dbc38b26543a36e8ab0f62876fcd25d573c2b78ea58e9e16b51f61ae50107" %} {% set build = 0 %} @@ -28,10 +28,8 @@ requirements: - make host: - llvm-openmp # [osx] - - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - - liblapack - python - cython - numpy >=1.26 @@ -50,11 +48,10 @@ requirements: - llvm-openmp # [osx] - libopenblas * *openmp* - libblas * *openblas - - liblapack - {{ pin_compatible("numpy") }} - {{ pin_compatible("scipy") }} + - {{ pin_compatible("libopenblas") }} - {{ pin_compatible("libblas") }} - - {{ pin_compatible("liblapack") }} - python - astropy - healpy diff --git a/pkgs/qpoint/meta.yaml b/pkgs/qpoint/meta.yaml index cd72dda..3f283ab 100644 --- a/pkgs/qpoint/meta.yaml +++ b/pkgs/qpoint/meta.yaml @@ -20,13 +20,14 @@ build: requirements: build: - {{ compiler('c') }} + # This is required to ensure consistent use of libgfortran + # across the stack. + - {{ compiler('fortran') }} - llvm-openmp # [osx] host: - llvm-openmp # [osx] - - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - - liblapack - python - setuptools - numpy >=1.26 @@ -41,11 +42,10 @@ requirements: - llvm-openmp # [osx] - libopenblas * *openmp* - libblas * *openblas - - liblapack - {{ pin_compatible("numpy") }} - {{ pin_compatible("scipy") }} + - {{ pin_compatible("libopenblas") }} - {{ pin_compatible("libblas") }} - - {{ pin_compatible("liblapack") }} - python - astropy diff --git a/pkgs/so3g/build.sh b/pkgs/so3g/build.sh index 440d2cf..632bb41 100755 --- a/pkgs/so3g/build.sh +++ b/pkgs/so3g/build.sh @@ -2,8 +2,8 @@ set -e set -x -CFLAGS="-O3 -g -fPIC -I${PREFIX}/include" \ -CXXFLAGS="-O3 -g -fPIC -std=c++14 -I${PREFIX}/include" \ +CFLAGS="-Wno-error -O3 -g -fPIC -I${PREFIX}/include" \ +CXXFLAGS="-Wno-error -O3 -g -fPIC -std=c++14 -I${PREFIX}/include" \ BOOST_ROOT="${PREFIX}" \ FLAC_ROOT="${PREFIX}" \ python -m pip install -vvv --ignore-installed --no-deps --prefix "${PREFIX}" . diff --git a/pkgs/so3g/meta.yaml b/pkgs/so3g/meta.yaml index 8c1ba2f..784f35f 100644 --- a/pkgs/so3g/meta.yaml +++ b/pkgs/so3g/meta.yaml @@ -13,27 +13,27 @@ source: patches: - setup_requires.patch - cxx_werror.patch + - parallel.patch build: number: {{ build }} skip: true # [win] - script_env: - - CFLAGS=-Wno-error -O3 -g -fPIC - - CXXFLAGS=-Wno-error -O3 -g -fPIC -std=c++14 requirements: build: - {{ compiler('c') }} - {{ compiler('cxx') }} + # This is required to ensure consistent use of libgfortran + # across the stack. + - {{ compiler('fortran') }} - cmake - make - llvm-openmp # [osx] host: - llvm-openmp # [osx] - - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - - liblapack + - openblas * *openmp* - python - numpy >=1.26 - scipy @@ -49,11 +49,10 @@ requirements: - llvm-openmp # [osx] - libopenblas * *openmp* - libblas * *openblas - - liblapack - {{ pin_compatible("numpy") }} - {{ pin_compatible("scipy") }} + - {{ pin_compatible("libopenblas") }} - {{ pin_compatible("libblas") }} - - {{ pin_compatible("liblapack") }} - {{ pin_compatible("libboost-python") }} - {{ pin_compatible("libboost") }} - {{ pin_compatible("libflac") }} diff --git a/pkgs/so3g/parallel.patch b/pkgs/so3g/parallel.patch new file mode 100644 index 0000000..edf3f49 --- /dev/null +++ b/pkgs/so3g/parallel.patch @@ -0,0 +1,17 @@ +diff -urN so3g-0.1.13_orig/setup.py so3g-0.1.13/setup.py +--- so3g-0.1.13_orig/setup.py 2024-03-29 08:40:04.000000000 -0700 ++++ so3g-0.1.13/setup.py 2024-04-02 22:41:13.998376523 -0700 +@@ -152,7 +152,12 @@ + sp.check_call(["cmake", cmake_list_dir] + cmake_args, cwd=build_dir, env=env) + + print("-" * 10, "Building {}".format(pkg), "-" * 40) +- cmake_cmd = ["cmake", "--build", "."] + build_args + ["--", "-j2"] ++ if "CPU_COUNT" in os.environ: ++ # Running in conda-build ++ parallel_args = ["--parallel", os.environ["CPU_COUNT"]] ++ else: ++ parallel_args = ["--parallel", "2"] ++ cmake_cmd = ["cmake", "--build", "."] + build_args + parallel_args + sp.check_call(cmake_cmd, cwd=build_dir) + cmake_cmd = ["cmake", "--install", "."] + build_args + sp.check_call(cmake_cmd, cwd=build_dir) diff --git a/pkgs/toast/meta.yaml b/pkgs/toast/meta.yaml index 58f828f..73acbf0 100644 --- a/pkgs/toast/meta.yaml +++ b/pkgs/toast/meta.yaml @@ -25,15 +25,16 @@ requirements: build: - {{ compiler('c') }} - {{ compiler('cxx') }} + # This is required to ensure consistent use of libgfortran + # across the stack. + - {{ compiler('fortran') }} - cmake - make - llvm-openmp # [osx] host: - llvm-openmp # [osx] - - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - - liblapack - python - numpy >=1.26 - scipy @@ -45,12 +46,11 @@ requirements: - llvm-openmp # [osx] - libopenblas * *openmp* - libblas * *openblas - - liblapack - {{ pin_compatible("numpy") }} - {{ pin_compatible("scipy") }} - {{ pin_compatible("fftw") }} + - {{ pin_compatible("libopenblas") }} - {{ pin_compatible("libblas") }} - - {{ pin_compatible("liblapack") }} - {{ pin_compatible("suitesparse") }} - {{ pin_compatible("libaatm") }} - {{ pin_compatible("libflac") }} From 019c8828169979072ae7a03ace3bce6326e5822a Mon Sep 17 00:00:00 2001 From: Ted Kisner Date: Wed, 3 Apr 2024 23:43:35 -0700 Subject: [PATCH 4/8] Remove libtool la files and libarcher.so symlink --- pkgs/libactpol/build.sh | 2 ++ pkgs/libactpol/meta.yaml | 1 + pkgs/libactpol_deps/build.sh | 1 + pkgs/libactpol_deps/meta.yaml | 1 + pkgs/moby2/meta.yaml | 1 + pkgs/pixell/meta.yaml | 1 + pkgs/qpoint/meta.yaml | 1 + pkgs/so3g/meta.yaml | 1 + pkgs/toast/meta.yaml | 1 + 9 files changed, 10 insertions(+) diff --git a/pkgs/libactpol/build.sh b/pkgs/libactpol/build.sh index ed4e199..4078c59 100755 --- a/pkgs/libactpol/build.sh +++ b/pkgs/libactpol/build.sh @@ -11,3 +11,5 @@ CFLAGS="-O3 -g -fPIC" \ make make install +rm -f "${PREFIX}/lib/libactpol_deps*.la" +rm -f "${PREFIX}/lib/libarcher.so" diff --git a/pkgs/libactpol/meta.yaml b/pkgs/libactpol/meta.yaml index c379071..ac2423d 100644 --- a/pkgs/libactpol/meta.yaml +++ b/pkgs/libactpol/meta.yaml @@ -31,6 +31,7 @@ requirements: - libtool host: - llvm-openmp # [osx] + - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - cfitsio diff --git a/pkgs/libactpol_deps/build.sh b/pkgs/libactpol_deps/build.sh index a662d86..da242c2 100755 --- a/pkgs/libactpol_deps/build.sh +++ b/pkgs/libactpol_deps/build.sh @@ -18,4 +18,5 @@ CXXFLAGS="-O3 -g -fPIC" \ ./configure --prefix="${PREFIX}" --with-zzip make make install +rm -f "${PREFIX}/lib/libactpol_deps*.la" popd diff --git a/pkgs/libactpol_deps/meta.yaml b/pkgs/libactpol_deps/meta.yaml index 7961991..d9969bf 100644 --- a/pkgs/libactpol_deps/meta.yaml +++ b/pkgs/libactpol_deps/meta.yaml @@ -29,6 +29,7 @@ requirements: - make host: - llvm-openmp # [osx] + - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - zziplib diff --git a/pkgs/moby2/meta.yaml b/pkgs/moby2/meta.yaml index 1027d35..bbc641a 100644 --- a/pkgs/moby2/meta.yaml +++ b/pkgs/moby2/meta.yaml @@ -27,6 +27,7 @@ requirements: - llvm-openmp # [osx] host: - llvm-openmp # [osx] + - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - python diff --git a/pkgs/pixell/meta.yaml b/pkgs/pixell/meta.yaml index 37e6f95..1b64ee0 100644 --- a/pkgs/pixell/meta.yaml +++ b/pkgs/pixell/meta.yaml @@ -28,6 +28,7 @@ requirements: - make host: - llvm-openmp # [osx] + - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - python diff --git a/pkgs/qpoint/meta.yaml b/pkgs/qpoint/meta.yaml index 3f283ab..2f01e2b 100644 --- a/pkgs/qpoint/meta.yaml +++ b/pkgs/qpoint/meta.yaml @@ -26,6 +26,7 @@ requirements: - llvm-openmp # [osx] host: - llvm-openmp # [osx] + - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - python diff --git a/pkgs/so3g/meta.yaml b/pkgs/so3g/meta.yaml index 784f35f..9452afc 100644 --- a/pkgs/so3g/meta.yaml +++ b/pkgs/so3g/meta.yaml @@ -31,6 +31,7 @@ requirements: - llvm-openmp # [osx] host: - llvm-openmp # [osx] + - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - openblas * *openmp* diff --git a/pkgs/toast/meta.yaml b/pkgs/toast/meta.yaml index 73acbf0..e0bf2d5 100644 --- a/pkgs/toast/meta.yaml +++ b/pkgs/toast/meta.yaml @@ -33,6 +33,7 @@ requirements: - llvm-openmp # [osx] host: - llvm-openmp # [osx] + - libgomp # [linux] - libopenblas * *openmp* - libblas * *openblas - python From 2c4746850ab6023dd611e69519f3998ec99bf292 Mon Sep 17 00:00:00 2001 From: Ted Kisner Date: Thu, 4 Apr 2024 00:26:27 -0700 Subject: [PATCH 5/8] Remove change to recipes that was not needed --- pkgs/libactpol/meta.yaml | 3 --- pkgs/moby2/meta.yaml | 3 --- pkgs/qpoint/meta.yaml | 3 --- pkgs/so3g/meta.yaml | 3 --- pkgs/toast/meta.yaml | 3 --- 5 files changed, 15 deletions(-) diff --git a/pkgs/libactpol/meta.yaml b/pkgs/libactpol/meta.yaml index ac2423d..c86173e 100644 --- a/pkgs/libactpol/meta.yaml +++ b/pkgs/libactpol/meta.yaml @@ -20,9 +20,6 @@ build: requirements: build: - {{ compiler('c') }} - # This is required to ensure consistent use of libgfortran - # across the stack. - - {{ compiler('fortran') }} - llvm-openmp # [osx] - make - automake diff --git a/pkgs/moby2/meta.yaml b/pkgs/moby2/meta.yaml index bbc641a..b591659 100644 --- a/pkgs/moby2/meta.yaml +++ b/pkgs/moby2/meta.yaml @@ -21,9 +21,6 @@ build: requirements: build: - {{ compiler('c') }} - # This is required to ensure consistent use of libgfortran - # across the stack. - - {{ compiler('fortran') }} - llvm-openmp # [osx] host: - llvm-openmp # [osx] diff --git a/pkgs/qpoint/meta.yaml b/pkgs/qpoint/meta.yaml index 2f01e2b..6efc0ea 100644 --- a/pkgs/qpoint/meta.yaml +++ b/pkgs/qpoint/meta.yaml @@ -20,9 +20,6 @@ build: requirements: build: - {{ compiler('c') }} - # This is required to ensure consistent use of libgfortran - # across the stack. - - {{ compiler('fortran') }} - llvm-openmp # [osx] host: - llvm-openmp # [osx] diff --git a/pkgs/so3g/meta.yaml b/pkgs/so3g/meta.yaml index 9452afc..20d1900 100644 --- a/pkgs/so3g/meta.yaml +++ b/pkgs/so3g/meta.yaml @@ -23,9 +23,6 @@ requirements: build: - {{ compiler('c') }} - {{ compiler('cxx') }} - # This is required to ensure consistent use of libgfortran - # across the stack. - - {{ compiler('fortran') }} - cmake - make - llvm-openmp # [osx] diff --git a/pkgs/toast/meta.yaml b/pkgs/toast/meta.yaml index e0bf2d5..70eed78 100644 --- a/pkgs/toast/meta.yaml +++ b/pkgs/toast/meta.yaml @@ -25,9 +25,6 @@ requirements: build: - {{ compiler('c') }} - {{ compiler('cxx') }} - # This is required to ensure consistent use of libgfortran - # across the stack. - - {{ compiler('fortran') }} - cmake - make - llvm-openmp # [osx] From 8a6441ad420bff819636700f70158adbeaf56c4c Mon Sep 17 00:00:00 2001 From: Ted Kisner Date: Thu, 4 Apr 2024 00:29:35 -0700 Subject: [PATCH 6/8] More cleanup and add an extra import test --- .github/workflows/test.yml | 1 + pkgs/libactpol/meta.yaml | 2 -- pkgs/libactpol_deps/meta.yaml | 2 -- pkgs/moby2/meta.yaml | 2 +- 4 files changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index a0da4a0..2404593 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -73,6 +73,7 @@ jobs: python3 -c 'import scipy; import toast' && python3 -c 'import so3g; from spt3g import core' && python3 -c 'from sotodlib import core' && + python3 -c 'import moby2.analysis.socompat' && python3 -c 'import toast.tests; toast.tests.run()' && git clone --depth=1 --single-branch --branch=master https://github.com/simonsobs/sotodlib.git && pushd sotodlib && diff --git a/pkgs/libactpol/meta.yaml b/pkgs/libactpol/meta.yaml index c86173e..fe0f13f 100644 --- a/pkgs/libactpol/meta.yaml +++ b/pkgs/libactpol/meta.yaml @@ -14,8 +14,6 @@ source: build: number: {{ build }} skip: true # [win] - # run_exports: - # - libactpol requirements: build: diff --git a/pkgs/libactpol_deps/meta.yaml b/pkgs/libactpol_deps/meta.yaml index d9969bf..d3b6f8c 100644 --- a/pkgs/libactpol_deps/meta.yaml +++ b/pkgs/libactpol_deps/meta.yaml @@ -14,8 +14,6 @@ source: build: number: {{ build }} skip: true # [win] - # run_exports: - # - libactpol_deps requirements: build: diff --git a/pkgs/moby2/meta.yaml b/pkgs/moby2/meta.yaml index b591659..81149b7 100644 --- a/pkgs/moby2/meta.yaml +++ b/pkgs/moby2/meta.yaml @@ -11,7 +11,7 @@ source: url: https://github.com/ACTCollaboration/moby2/archive/{{ version }}.tar.gz sha256: {{ sha256 }} patches: - # - dep_names.patch + - dep_names.patch - np_bool.patch build: From 96ade90636533a18521c030219ea965a2ffe73b7 Mon Sep 17 00:00:00 2001 From: Ted Kisner Date: Thu, 4 Apr 2024 09:41:42 -0700 Subject: [PATCH 7/8] Restore normal lapack linking in moby2 --- pkgs/moby2/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/moby2/meta.yaml b/pkgs/moby2/meta.yaml index 81149b7..9a4f917 100644 --- a/pkgs/moby2/meta.yaml +++ b/pkgs/moby2/meta.yaml @@ -11,7 +11,7 @@ source: url: https://github.com/ACTCollaboration/moby2/archive/{{ version }}.tar.gz sha256: {{ sha256 }} patches: - - dep_names.patch + #- dep_names.patch - np_bool.patch build: From c3452361ade7088aeab0635b63ba02b558adf956 Mon Sep 17 00:00:00 2001 From: Ted Kisner Date: Thu, 4 Apr 2024 10:31:18 -0700 Subject: [PATCH 8/8] Remove moby test from github workflow, since it is not installed on macos. --- .github/workflows/test.yml | 1 - pkgs/moby2/dep_names.patch | 12 ------------ pkgs/moby2/meta.yaml | 1 - 3 files changed, 14 deletions(-) delete mode 100644 pkgs/moby2/dep_names.patch diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2404593..a0da4a0 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -73,7 +73,6 @@ jobs: python3 -c 'import scipy; import toast' && python3 -c 'import so3g; from spt3g import core' && python3 -c 'from sotodlib import core' && - python3 -c 'import moby2.analysis.socompat' && python3 -c 'import toast.tests; toast.tests.run()' && git clone --depth=1 --single-branch --branch=master https://github.com/simonsobs/sotodlib.git && pushd sotodlib && diff --git a/pkgs/moby2/dep_names.patch b/pkgs/moby2/dep_names.patch deleted file mode 100644 index 3cdfbb3..0000000 --- a/pkgs/moby2/dep_names.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -urN moby2-fd360a7352c88d3eb5195f5f0ea331ddc24e5e09/setup.py moby2_openblas/setup.py ---- moby2-fd360a7352c88d3eb5195f5f0ea331ddc24e5e09/setup.py 2021-09-09 07:55:34.000000000 -0700 -+++ moby2_openblas/setup.py 2022-03-25 19:10:38.758241651 -0700 -@@ -10,7 +10,7 @@ - import numpy - includes = [numpy.get_include()] - libdirs = [] --library = ['fftw3f', 'gslcblas', 'gsl', 'lapack', 'actpol'] -+library = ['fftw3f', 'gslcblas', 'gsl', 'openblas', 'actpol'] - - sources = glob.glob('src/*.c') - headers = glob.glob('src/*.h') diff --git a/pkgs/moby2/meta.yaml b/pkgs/moby2/meta.yaml index 9a4f917..cd53fb5 100644 --- a/pkgs/moby2/meta.yaml +++ b/pkgs/moby2/meta.yaml @@ -11,7 +11,6 @@ source: url: https://github.com/ACTCollaboration/moby2/archive/{{ version }}.tar.gz sha256: {{ sha256 }} patches: - #- dep_names.patch - np_bool.patch build: