Browse Source

Travis multi-OS

pull/2/merge
Hoa V. DINH 8 years ago
parent
commit
6615cd2398
3 changed files with 27 additions and 10 deletions
  1. +3
    -0
      .travis.yml
  2. +3
    -1
      travis/before-script.sh
  3. +21
    -9
      travis/script.sh

+ 3
- 0
.travis.yml View File

@ -1,3 +1,6 @@
os:
- osx
- linux
language: c
before_script: travis/before-script.sh
script: travis/script.sh

+ 3
- 1
travis/before-script.sh View File

@ -1,4 +1,6 @@
#!/bin/sh
set -e
sudo apt-get install libsasl2-dev libssl-dev zlib1g-dev
if test "x`uname`" = xLinux ; then
sudo apt-get install libsasl2-dev libssl-dev zlib1g-dev
fi

+ 21
- 9
travis/script.sh View File

@ -1,12 +1,24 @@
#!/bin/sh
set -e
distdir=libetpan-travis-build
./autogen.sh --with-curl=no --disable-db --with-expat=no
make dist distdir=$distdir
tar xzf $distdir.tar.gz
cd $distdir
./configure --with-curl=no --disable-db --with-expat=no
make
cd tests
make imap-sample
if test "x`uname`" = xLinux ; then
distdir=libetpan-travis-build
./autogen.sh --with-curl=no --disable-db --with-expat=no
make dist distdir=$distdir
tar xzf $distdir.tar.gz
cd $distdir
./configure --with-curl=no --disable-db --with-expat=no
make
cd tests
make imap-sample
else
echo Building library for iPhoneOS
xctool -project build-mac/libetpan.xcodeproj -sdk iphoneos7.1 -scheme "libetpan ios" build ARCHS="armv7 armv7s arm64"
echo Building library for iPhoneSimulator
xctool -project build-mac/libetpan.xcodeproj -sdk iphonesimulator7.1 -scheme "libetpan ios" build ARCHS="i386 x86_64"
echo Building library for Mac
xctool -project build-mac/libetpan.xcodeproj -sdk macosx10.8 -scheme "static libetpan" build
echo Building framework for Mac
xctool -project build-mac/libetpan.xcodeproj -sdk macosx10.8 -scheme "libetpan" build
fi

Loading…
Cancel
Save