
package:
  name: sls_detector_software
  version: {{ environ.get('GIT_DESCRIBE_TAG', '') }}

source:
  - path: ..

build:
  number: 0
  binary_relocation: True
  rpaths:
    - lib/

requirements:
  build:
    - {{ compiler('c') }}
    - {{compiler('cxx')}}
    - cmake
    - qwt 6.*
    - qt 4.8.*
    - zeromq
    - xorg-libx11
    - xorg-libice
    - xorg-libxext
    - xorg-libsm
    - xorg-libxau
    - xorg-libxrender
    - xorg-libxfixes
    - {{ cdt('mesa-libgl-devel') }}      # [linux]
    - {{ cdt('mesa-libegl-devel') }}     # [linux]
    - {{ cdt('mesa-dri-drivers') }}      # [linux]
    - {{ cdt('libselinux') }}            # [linux]
    - {{ cdt('libxdamage') }}            # [linux]
    - {{ cdt('libxxf86vm') }}            # [linux]
    - expat

  host:
    - libstdcxx-ng
    - libgcc-ng
    - zeromq
    - xorg-libx11
    - xorg-libice
    - xorg-libxext
    - xorg-libsm
    - xorg-libxau
    - xorg-libxrender
    - xorg-libxfixes
    - expat

  run:
    - zeromq
    - libstdcxx-ng
    - libgcc-ng 


outputs:
  - name: slsdetlib
    script: copy_lib.sh

    requirements:
      build:
        - {{ compiler('c') }}
        - {{compiler('cxx')}}
        - libstdcxx-ng
        - libgcc-ng
        - zeromq

      host:
        - zeromq

      run: 
        - libstdcxx-ng
        - libgcc-ng
        - zeromq

  - name: slsdet

    script: build_pylib.sh

    requirements:
      build:
        - python
        - {{ compiler('c') }}
        - {{compiler('cxx')}}
        - {{ pin_subpackage('slsdetlib', exact=True) }}
        - setuptools

      host:
        - python
        - {{ pin_subpackage('slsdetlib', exact=True) }}


      run:
        - libstdcxx-ng
        - libgcc-ng
        - python
        - numpy
        - {{ pin_subpackage('slsdetlib', exact=True) }}


    test:
      imports:
        - slsdet

  - name: slsdetgui
    script: copy_gui.sh
    requirements:

      build:
        - {{ compiler('c') }}
        - {{compiler('cxx')}}
        - {{ pin_subpackage('slsdetlib', exact=True) }}
        - qwt 6.*

      run:
        - {{ pin_subpackage('slsdetlib', exact=True) }}
        - qwt 6.*
        - qt 4.8.*
        - expat

  - name: moenchzmq
    script: copy_moench.sh
    requirements:

      build:
        - {{ compiler('c') }}
        - {{compiler('cxx')}}
        - {{ pin_subpackage('slsdetlib', exact=True) }}


      run:
        - {{ pin_subpackage('slsdetlib', exact=True) }}
        - expat
