Skip to content

Commit a0df86e

Browse files
author
Tess Avitabile
committed
CXX-747 Add OSX builder to evergreen project
1 parent 1a9ca18 commit a0df86e

File tree

1 file changed

+48
-3
lines changed

1 file changed

+48
-3
lines changed

.mci.yml

Lines changed: 48 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,31 @@
22
# CXX Driver Config for MCI #
33
#######################################
44

5+
#######################################
6+
# Variables #
7+
#######################################
8+
variables:
9+
10+
## source variables
11+
source:
12+
ubuntu_source: &ubuntu_source https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-latest.tgz
13+
osx_source: &osx_source https://fastdl.mongodb.org/osx/mongodb-osx-x86_64-latest.tgz
14+
15+
## cmake path variables
16+
cmake_path:
17+
ubuntu_cmake_path: &ubuntu_cmake_path /opt/cmake/bin/cmake
18+
osx_cmake_path: &osx_cmake_path /Applications/Cmake.app/Contents/bin/cmake
19+
20+
## tar options variables
21+
tar_options:
22+
ubuntu_tar_options: &ubuntu_tar_options --wildcards --no-anchored
23+
24+
## cmake flag variables
25+
cmake_flags:
26+
ubuntu_cmake_flags: &ubuntu_cmake_flags -DCMAKE_CXX_FLAGS="-Wall -Wextra -Wno-attributes -Werror -Wno-error=missing-field-initializers"
27+
osx_cmake_flags: &osx_cmake_flags -DCMAKE_CXX_FLAGS="-stdlib=libc++ -Wall -Wextra -Wno-attributes -Werror -Wno-error=missing-field-initializers" -DBSONCXX_POLY_USE_BOOST=ON -DLIBBSON_DIR=/data/tmp/c-driver-install -DLIBMONGOC_DIR=/data/tmp/c-driver-install
28+
29+
530
#######################################
631
# Functions #
732
#######################################
@@ -17,8 +42,8 @@ functions:
1742
params:
1843
working_dir: "."
1944
script: |
20-
wget -O mongodb.tgz https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-latest.tgz
21-
tar --extract --file mongodb.tgz --strip-components=2 --wildcards --no-anchored "*/bin/mongod"
45+
curl -o mongodb.tgz ${source}
46+
tar --extract --file mongodb.tgz --strip-components=2 ${tar_options} "*/bin/mongod"
2247
mkdir -p /data/tmp/db
2348
./mongod --fork --logpath=/data/tmp/log --dbpath=/data/tmp/db --pidfilepath=/data/tmp/pid
2449
@@ -78,7 +103,7 @@ tasks:
78103
params:
79104
working_dir: "mongo-cxx-driver/build"
80105
script: |
81-
PKG_CONFIG_PATH="/data/tmp/c-driver-install/lib/pkgconfig" /opt/cmake/bin/cmake -DCMAKE_BUILD_TYPE=${build_type} -DCMAKE_INSTALL_PREFIX=./install -DCMAKE_C_FLAGS="-Wall -Wextra -Wno-attributes -Werror -Wno-error=missing-field-initializers" -DCMAKE_CXX_FLAGS="-Wall -Wextra -Wno-attributes -Werror -Wno-error=missing-field-initializers" ..
106+
PKG_CONFIG_PATH="/data/tmp/c-driver-install/lib/pkgconfig" ${cmake_path} ${cmake_flags} -DCMAKE_BUILD_TYPE=${build_type} -DCMAKE_INSTALL_PREFIX=./install -DCMAKE_C_FLAGS="-Wall -Wextra -Wno-attributes -Werror -Wno-error=missing-field-initializers" ..
82107
make
83108
./src/bsoncxx/test/test_bson
84109
./src/mongocxx/test/test_driver
@@ -98,6 +123,10 @@ buildvariants:
98123
display_name: "Ubuntu 14.04 Release"
99124
expansions:
100125
build_type: "Release"
126+
source: *ubuntu_source
127+
tar_options: *ubuntu_tar_options
128+
cmake_path: *ubuntu_cmake_path
129+
cmake_flags: *ubuntu_cmake_flags
101130
run_on:
102131
- ubuntu1404-test
103132
tasks:
@@ -107,7 +136,23 @@ buildvariants:
107136
display_name: "Ubuntu 14.04 Debug"
108137
expansions:
109138
build_type: "Debug"
139+
source: *ubuntu_source
140+
tar_options: *ubuntu_tar_options
141+
cmake_path: *ubuntu_cmake_path
142+
cmake_flags: *ubuntu_cmake_flags
110143
run_on:
111144
- ubuntu1404-test
112145
tasks:
113146
- name: compile_and_test
147+
148+
- name: osx-108
149+
display_name: "OS X 10.8 Release"
150+
expansions:
151+
build_type: "Release"
152+
source: *osx_source
153+
cmake_path: *osx_cmake_path
154+
cmake_flags: *osx_cmake_flags
155+
run_on:
156+
- osx-108
157+
tasks:
158+
- name: compile_and_test

0 commit comments

Comments
 (0)