Skip to content
Snippets Groups Projects
Commit 7302d240 authored by jay's avatar jay
Browse files

Adds conda build

parent 00623986
No related branches found
No related tags found
No related merge requests found
language: generic
os:
- linux
- osx
install:
# Install a supported cmake version (>= 3.10)
- |
if [ "$TRAVIS_OS_NAME" == "linux" ]; then
wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh;
else
curl -o miniconda.sh https://repo.continuum.io/miniconda/Miniconda3-latest-MacOSX-x86_64.sh;
fi
- bash miniconda.sh -b -p $HOME/miniconda
- export PATH="$HOME/miniconda/bin:$PATH"
- conda install -y -c usgs-astrogeology libcsm
- conda install -y -c conda-forge cmake pytest
script:
- .run_build.sh
- pytest tests
......@@ -7,8 +7,11 @@ set(CMAKE_SWIG_FLAGS "")
set_source_files_properties(../csmapi.i
PROPERTIES CPLUSPLUS ON)
find_path(CSM_INCLUDE_DIR NAMES csm.h PATH_SUFFIXES csm)
find_library(CSM_LIBRARY NAMES csmapi)
find_path(CSM_INCLUDE_DIR NAMES csm.h
PATH_SUFFIXES csm
PATHS $ENV{CONDA_PREFIX}/include)
find_library(CSM_LIBRARY NAMES csmapi
PATHS $ENV{CONDA_PREFIX}/lib)
include_directories(${CSM_INCLUDE_DIR})
......
source activate base
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=$PREFIX ..
make
python python/setup.py install
\ No newline at end of file
package:
name: csmwrapper
version: "0.1.0"
source:
git_url: https://github.com/USGS-Astrogeology/CSM-Swig.git
requirements:
build:
- {{ compiler('cxx') }}
- cmake >=3.10
- libcsm
test:
commands:
- import csmapi
- import csmapi.Isd
about:
home: https://github.com/USGS-Astrogeology/CSM-Swig
license: None
summary: "SWIG Wrapper to generate bindings to the Community Sensor Model"
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment