2016-06-28 21:53:08 +02:00
|
|
|
#!/bin/bash
|
2016-07-13 16:20:15 +02:00
|
|
|
|
|
|
|
# for executing in non travis environment
|
|
|
|
[ -z "$TRAVIS_OS_NAME" ] && TRAVIS_OS_NAME="$( uname -s | tr '[:upper:]' '[:lower:]' )"
|
|
|
|
|
|
|
|
|
|
|
|
######################################
|
|
|
|
## COMPILE HYPERION
|
|
|
|
|
2016-06-28 21:53:08 +02:00
|
|
|
# compile hyperion on osx
|
2016-07-13 16:20:15 +02:00
|
|
|
if [[ $TRAVIS_OS_NAME == 'osx' ]]
|
|
|
|
then
|
2016-08-11 07:13:55 +02:00
|
|
|
procs=$(sysctl -n hw.ncpu | xargs)
|
|
|
|
echo "Processes: $procs"
|
2016-08-07 18:39:45 +02:00
|
|
|
|
2016-07-13 16:20:15 +02:00
|
|
|
mkdir build || exit 1
|
2016-08-07 18:39:45 +02:00
|
|
|
cd build
|
2016-07-13 16:20:15 +02:00
|
|
|
cmake -DCMAKE_BUILD_TYPE=Release -DENABLE_TESTS=ON -Wno-dev .. || exit 2
|
2016-08-07 18:39:45 +02:00
|
|
|
make -j$procs || exit 3
|
2016-07-13 16:20:15 +02:00
|
|
|
# make -j$(nproc) package || exit 4 # currently osx(dmg) package creation not implemented
|
2016-06-28 21:53:08 +02:00
|
|
|
fi
|
|
|
|
|
|
|
|
# compile hyperion on linux
|
2016-07-13 16:20:15 +02:00
|
|
|
if [[ $TRAVIS_OS_NAME == 'linux' ]]
|
|
|
|
then
|
|
|
|
mkdir build || exit 1
|
|
|
|
cd build
|
2016-07-20 16:04:56 +02:00
|
|
|
cmake -DPLATFORM=x86-dev -DCMAKE_BUILD_TYPE=Release .. || exit 2
|
2016-07-13 16:20:15 +02:00
|
|
|
make -j$(nproc) || exit 3
|
|
|
|
make -j$(nproc) package || exit 4
|
2016-06-28 21:53:08 +02:00
|
|
|
fi
|
2016-07-13 16:20:15 +02:00
|
|
|
|