Skip to content

Commit 3432762

Browse files
committed
Merge pull request #28 from tpaviot/review/travis-use-conda
Updated travis config file to use conda
2 parents 1de0cad + 2f55b74 commit 3432762

File tree

8 files changed

+107
-77
lines changed

8 files changed

+107
-77
lines changed

.travis.build.sh

Lines changed: 0 additions & 19 deletions
This file was deleted.

.travis.yml

Lines changed: 34 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,41 @@
1+
sudo: required
2+
13
language: cpp
4+
5+
os:
6+
- osx
7+
- linux
8+
29
compiler:
310
- gcc
411
- clang
5-
before_install:
6-
# following ppa contains oce-0.16.0
7-
- sudo apt-get install gfortran
8-
- sudo add-apt-repository "deb http://ppa.launchpad.net/freecad-maintainers/oce-release/ubuntu precise main" -y
9-
- sudo apt-get update -q
10-
- sudo apt-get install liboce-ocaf-dev oce-draw
11-
before_script:
12-
script: ./.travis.build.sh
13-
after_script:
12+
13+
14+
install:
15+
# We do this conditionally because it saves us some downloading if the
16+
# version is the same.
17+
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then
18+
sudo apt-get install gfortran;
19+
wget https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh -O miniconda.sh;
20+
else
21+
wget https://repo.continuum.io/miniconda/Miniconda3-latest-MacOSX-x86_64.sh -O miniconda.sh;
22+
fi
23+
- bash miniconda.sh -b -p $HOME/miniconda
24+
- export PATH="$HOME/miniconda/bin:$HOME/miniconda/lib:$PATH"
25+
- hash -r
26+
- conda config --set always_yes yes --set changeps1 no
27+
- conda update -q conda
28+
# Useful for debugging any issues with conda
29+
- conda info -a
30+
# download/install OCE from DLR-SC channel
31+
- conda config --add channels https://conda.anaconda.org/dlr-sc
32+
# install everything required to build the receipe
33+
- conda install conda-build anaconda-client
34+
35+
36+
script:
37+
- conda build ci/conda
38+
1439
branches:
1540
only:
1641
- master

ci/conda/bld.bat

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
mkdir build
2+
cd build
3+
4+
REM Configure step
5+
cmake -G "Ninja" -DCMAKE_INSTALL_PREFIX="%LIBRARY_PREFIX%" ^
6+
-DCMAKE_BUILD_TYPE=Release ^
7+
-DCMAKE_PREFIX_PATH="%LIBRARY_PREFIX%" ^
8+
-DCMAKE_SYSTEM_PREFIX_PATH="%LIBRARY_PREFIX%" ^
9+
..
10+
if errorlevel 1 exit 1
11+
12+
REM Build step
13+
ninja
14+
if errorlevel 1 exit 1
15+
16+
REM Install step
17+
ninja install
18+
if errorlevel 1 exit 1

ci/conda/build.sh

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Configure step
2+
cmake -DCMAKE_INSTALL_PREFIX=$PREFIX \
3+
-DCMAKE_BUILD_TYPE=Release \
4+
-DCMAKE_PREFIX_PATH=$PREFIX \
5+
-DCMAKE_SYSTEM_PREFIX_PATH=$PREFIX \
6+
-DSMESH_TESTING=ON \
7+
.
8+
9+
# Build step
10+
make -j 4
11+
12+
# test
13+
if [ `uname` == Linux ]; then
14+
make test
15+
fi
16+
17+
18+
# Install step
19+
# redirect stdout stream to a file because of many boost header files
20+
make install > installed_files.txt
21+

ci/conda/meta.yaml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
package:
2+
name: smesh
3+
version: {{ environ.get('GIT_DESCRIBE_TAG', '6.5.3.1dev') }}
4+
5+
source:
6+
path: ../..
7+
8+
build:
9+
10+
build:
11+
script_env:
12+
- CC
13+
- CXX
14+
15+
number: {{ environ.get('GIT_DESCRIBE_NUMBER', 0) }}
16+
binary_relocation: false [osx]
17+
features:
18+
- vc9 [win and py27]
19+
- vc10 [win and py34]
20+
- vc14 [win and py35]
21+
22+
requirements:
23+
build:
24+
- oce ==0.17.1
25+
- cmake
26+
27+
run:
28+
- oce ==0.17.1
29+
30+
about:
31+
home: https://github.com/tpaviot/smesh
32+
license: LGPL
33+
summary: A complete MESH framework based on the OCE library.

ci/conda/run_test.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Test step

pkg/conda/build.sh

Lines changed: 0 additions & 22 deletions
This file was deleted.

pkg/conda/meta.yaml

Lines changed: 0 additions & 27 deletions
This file was deleted.

0 commit comments

Comments
 (0)