{% set version = "9d" %}

package:
  name: jpeg
  version: {{ version }}

source:
  url: http://www.ijg.org/files/jpegsrc.v{{ version }}.tar.gz
  sha256: 99cb50e48a4556bc571dadd27931955ff458aae32f68c4d9c39d624693f69c32 
  patches:
    - CMakeLists.txt.patch  # [win]

build:
  number: 0
  run_exports:
    # compatible within major version numbers
    # https://abi-laboratory.pro/tracker/timeline/libjpeg/
    - {{ pin_subpackage('jpeg') }}

requirements:
  build:
    - cmake  # [win]
    - libtool  # [unix]
    - {{ compiler('c') }}
    - make

test:
  files:
    - testorig.jpg
  commands:
    - djpeg -dct int -ppm -outfile testout.ppm testorig.jpg

about:
  home: http://www.ijg.org/
  license: IJG
  license_file: {{ RECIPE_DIR }}/LICENSE.txt
  summary: read/write jpeg COM, EXIF, IPTC medata

extra:
  recipe-maintainers:
    - ocefpaf
    - gillins
    - jakirkham
    - msarahan
