{% set version = "1.14.0" %}
{% set commit = "6914bb41f0fb3c1ba500bae4e7d671da9536786f" %}

package:
  name: numpy
  version: {{ version }}

source:
  git_url: https://github.com/numpy/numpy
  git_tag: {{ commit }}
  patches:
    - 0001-use-mklfft-when-available.patch
    - 0002-simplify-arch-flags.patch
    - 0003-use-gfortran-from-env-variable.patch
    - 0004-fix-windows-case-sensitivity.patch   # [win]
    - 0005-intel-init-mkl.patch                 # [blas_impl == 'mkl' and vc>=14]
    - 0006-disable-memmap-filename-test-due-to-CI-link-confusio.patch  # [win]

build:
  number: 1
  skip: True  # [blas_impl == 'openblas' and win]
  # conda 4.4+ can use this
  requires_features:
    blas: {{ blas_impl }}
  # this is for conda 4.3 and below
  features:
    - nomkl    # [x86 and blas_impl != 'mkl']

requirements:
  build:
    - {{ compiler('c') }}
    - {{ compiler('fortran') }}
    # libgcc-ng should be a dependecy of libgfortran
    # until this is fixed add libgcc explicitly
    - libgcc-ng         # [linux and blas_impl == 'openblas']
  host:
    - cython
    - python
    - mkl-devel  {{ mkl }}  # [blas_impl == 'mkl']
    - openblas-devel {{ openblas }}  # [blas_impl == 'openblas']
    - setuptools
  run:
    - python
    # openblas or mkl runtime included with run_exports

test:
  requires:
    - nose
    - {{ compiler('c') }}
    - {{ compiler('fortran') }}
    - nomkl  # [x86 and blas_impl != 'mkl']
  commands:
    - f2py -h
    - python -c "import numpy; numpy.show_config()"
    - conda inspect linkages -p $PREFIX numpy  # [not win]
    - conda inspect objects -p $PREFIX numpy  # [osx]
  imports:
    - numpy
    - numpy.linalg.lapack_lite

about:
  home: http://numpy.scipy.org/
  license: BSD 3-Clause
  license_file: LICENSE.txt
  summary: 'Array processing for numbers, strings, records, and objects.'
  description: |
    NumPy is the fundamental package needed for scientific computing with Python.
  doc_url: https://docs.scipy.org/doc/numpy-1.14.0/reference/
  dev_url: https://github.com/numpy/numpy
  dev_source_url: https://github.com/numpy/numpy/tree/master/doc

extra:
  recipe-maintainers:
    - jakirkham
    - msarahan
    - pelson
    - rgommers
    - ocefpaf
