Make library test work on both linux/macOS
Inspired by the CGAL recipe (https://github.com/conda-forge/cgal-feedstock/blob/master/recipe/meta.yaml)
* Use the `SHLIB_EXT`environment variable instead of .so (linux) or .dylib (macOS)
* Add `conda inspect` commands
@@ -23,7 +23,9 @@ test:
commands:
# library
- test -f $PREFIX/lib/lib{{ name }}{{ version[0] }}.a # [unix]
- - test -f $PREFIX/lib/lib{{ name }}{{ version[0] }}.so # [unix]
+ - test -f $PREFIX/lib/lib{{ name }}{{ version[0] }}${SHLIB_EXT} # [unix]
+ - conda inspect linkages $PKG_NAME # [unix]
+ - conda inspect objects $PKG_NAME # [osx]
# header (too many .hpp files, so only test for the directory)
- test -d $PREFIX/include/{{ name }} # [unix]
