Files
gr-foo/.conda/recipe/meta.yaml
T
2023-07-28 14:51:47 +02:00

89 lines
3.4 KiB
YAML

{% set oot_name = "foo" %}
{% set name = "gnuradio-" + oot_name %}
# Set package version from cleaned up git tags if possible,
# otherwise fall back to date-based version.
{% set tag_version = environ.get("GIT_DESCRIBE_TAG", "")|string|replace("-","_")|replace("v","")|replace("git","") %}
{% set post_commit = environ.get("GIT_DESCRIBE_NUMBER", 0)|string %}
{% set hash = environ.get("GIT_DESCRIBE_HASH", "local")|string %}
{% set fallback_version = "0.0.0.{0}.dev+g{1}".format(datetime.datetime.now().strftime("%Y%m%d"), environ.get("GIT_FULL_HASH", "local")[:9]) %}
{% set version = (tag_version if post_commit == "0" else "{0}.post{1}+{2}".format(tag_version, post_commit, hash)) if tag_version else fallback_version %}
package:
name: {{ name|lower }}
version: {{ version }}
source:
# use local path or git repository depending on if the build is local or done on CI
path: "../.." # [not os.environ.get("CI")]
git_url: {{ environ.get('FEEDSTOCK_ROOT', "../..") }} # [os.environ.get("CI")]
build:
number: 0
run_exports:
- {{ pin_subpackage('gnuradio-foo', max_pin='x.x.x') }}
requirements:
build:
- {{ compiler("c") }}
- {{ compiler("cxx") }}
- cmake
- git
- ninja
- pkg-config
# cross-compilation requirements
- python # [build_platform != target_platform]
- cross-python_{{ target_platform }} # [build_platform != target_platform]
- numpy # [build_platform != target_platform]
- pybind11 # [build_platform != target_platform]
host:
- boost-cpp
- gmp # [linux]
# the following two entries are for generating builds against specific GR versions
- gnuradio-core # [not gnuradio_extra_pin]
- gnuradio-core {{ gnuradio_extra_pin }}.* # [gnuradio_extra_pin]
- pip # [win]
- pybind11
- python
- numpy
- uhd
run:
- boost-cpp
- numpy
- python
test:
commands:
# verify that (some) headers get installed
- test -f $PREFIX/include/{{ oot_name }}/api.h # [not win]
- if not exist %PREFIX%\\Library\\include\\{{ oot_name }}\\api.h exit 1 # [win]
# verify that libraries get installed
- test -f $PREFIX/lib/lib{{ name }}${SHLIB_EXT} # [not win]
- if not exist %PREFIX%\\Library\\bin\\{{ name }}.dll exit 1 # [win]
- if not exist %PREFIX%\\Library\\lib\\{{ name }}.lib exit 1 # [win]
# verify that (some) GRC blocks get installed
{% set blocks = ["burst_tagger", "channel_model", "packet_dropper", "packet_pad", "packet_pad2", "pad_tagged_stream", "periodic_msg_source", "random_periodic_msg_source", "selector", "valve", "wireshark_connector"] %}
{% for block in blocks %}
- test -f $PREFIX/share/gnuradio/grc/blocks/{{ oot_name }}_{{ block }}.block.yml # [not win]
- if not exist %PREFIX%\\Library\\share\\gnuradio\\grc\\blocks\\{{ oot_name }}_{{ block }}.block.yml exit 1 # [win]
{% endfor %}
imports:
# verify that the python module imports
- {{ oot_name }}
about:
home: https://github.com/bastibl/gr-foo
license: GPL-3.0-or-later
license_file: LICENSE
summary: Collection of GNU Radio blocks useful to other modules
description: >
This is a collection of custom blocks that are not directly associated with
a project. For sample applications see:
* https://github.com/bastibl/gr-ieee802-11
* https://github.com/bastibl/gr-ieee802-15-4