{% set name = "ldas-tools-al-swig" %}
{% set version = "2.6.11" %}

package:
  name: {{ name|lower }}
  version: {{ version }}

source:
  url: file:///Users/efm/Sources/LDAS/ldas-tools/ldas-ticketU/ldastoolsal-swig/conda/ldas-tools-al-swig-2.6.11.tar.gz
  sha256: 56d4a0f4014f6e524cd29c5d99369159d9df9651544b0c1590532bf4a52b6c18

build:
  number: 0
  skip: True  # [py==311 or py==313]
  script:
    - echo "=== CPU_COUNT is set to ${CPU_COUNT} ==="
    - 'echo "=== Number of CPUs detected: $(nproc || sysctl -n hw.ncpu || echo unknown) ==="'
    - mkdir -p build
    - cd build
    - export CMAKE_PREFIX_FLAGS="-DCMAKE_INSTALL_PREFIX=${PREFIX} -DCMAKE_PREFIX_PATH=${BUILD_PREFIX};${PREFIX}"
    - export CMAKE_MODULE_FLAGS="-DCMAKE_MODULE_PATH=${BUILD_PREFIX}/share/igwn-cmake/cmake/Modules"
    - export CMAKE_IGWN_FLAGS="-DIGWNCMake_DIR=${BUILD_PREFIX}/share/igwn-cmake/cmake/Modules -DIGWN_CMAKE_MODULE_DIRS=${BUILD_PREFIX}/share/igwn-cmake/cmake/Modules"
    - cmake .. ${CMAKE_PREFIX_FLAGS} ${CMAKE_MODULE_FLAGS} ${CMAKE_IGWN_FLAGS}
    - 'echo "=== Running: cmake --build . --parallel ${CPU_COUNT} ==="'
    - cmake --build . --parallel ${CPU_COUNT}
    - cmake --build . --target install

requirements:
  build:
    - cmake >=3.16
    - make
    - pkg-config
    - gcc_linux-64 >=15  # [linux]
    - gxx_linux-64 >=15  # [linux]
    - {{ compiler('c') }}  # [not linux]
    - {{ compiler('cxx') }}  # [not linux]
    - swig >=3.0.7
    - python
    - numpy
    - ldas-tools-cmake >=1.3.1
    - ldas-tools-al >=2.7.0
    - libboost-devel >=1.67
  host:
    - ldas-tools-cmake >=1.3.1
    - ldas-tools-al >=2.7.0
    - libboost-devel >=1.67
    - python
    - numpy
  run:
    - ldas-tools-al >=2.7.0
    - python
    - numpy

test:
  imports:
    - LDAStools

about:
  home: 
  license: GPL-2+
  license_file: COPYING
  summary: SWIG bindings for LDAS Tools abstraction library
  description: |
    This provides the swig files for the LDAS Tools abstraction interface

extra:
  recipe-maintainers:
    - ed-maros
