{% set name = "aws-sdk-cpp" %}
{% set version = "1.8.157" %}

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

source:
  url: https://github.com/aws/{{ name }}/archive/{{ version }}.tar.gz
  sha256: d262f30f42712158970b3cd487e8d9868bdbf4eed0164e85fd1b721a98757677
  patches:
    # Pass CMAKE_INSTALL_LIBDIR to dependencies as well
    - 0001-fix-libdir-for-deps.patch
    - 0002-force-openssl-use.patch  # [unix]

build:
  number: 0
  run_exports:
    - {{ pin_subpackage("aws-sdk-cpp", max_pin="x.x.x") }}

requirements:
  build:
    - cmake >=3.2
    - {{ compiler('c') }}
    - {{ compiler('cxx') }}
    - ninja
    - make  # [unix]
  host:
    - aws-c-common
    - aws-c-event-stream
    - libcurl
    # Force all platforms except win to use OpenSSL, rather than OS-supplied APIs.
    # Note that OpenSSL is implictly pulled in as a libcurl dependency, but we
    # explicitly list it as a host requirement so our run_exports are correct.
    - openssl  # [unix]

test:
  files:
    - test.cpp
    - CMakeLists.txt
  requires:
    - cmake
    - {{ compiler('c') }}
    - {{ compiler('cxx') }}
    - ninja
    - make  # [unix]
  commands:

about:
  home: https://github.com/aws/aws-sdk-cpp
  license: Apache-2.0
  license_family: Apache
  license_file: LICENSE
  summary: C++ library that makes it easy to integrate C++ applications with AWS services
  description: |
    The AWS SDK for C++ provides a modern C++ (version C++ 11 or later) interface for Amazon Web Services (AWS).
    It is meant to be performant and fully functioning with low- and high-level SDKs,
    while minimizing dependencies and providing platform portability (Windows, OSX, Linux, and mobile).
  doc_url: https://aws.amazon.com/documentation/sdk-for-cpp/
  dev_url: https://github.com/aws/aws-sdk-cpp

extra:
  recipe-maintainers:
    - jakebolewski
    - pitrou
    - ihnorton
    - xhochy
