Skip to content

Commit 769d12c

Browse files
richardlauBethGriggs
authored andcommitted
build: add a Prepare ccache job in Travis
Combined compile and test of Node.js where lots of files need to be compiled (e.g. after a V8 update) is exceeding the time limit for Travis jobs (50 minutes). Add a job to Travis that compiles Node.js but doesnt run any tests to populate the ccache. Introduce staging and move the `Test Suite` job into a later stage so that it can use the populated ccache. PR-URL: #27002 Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Signed-off-by: Beth Griggs <Bethany.Griggs@uk.ibm.com>
1 parent 9330d7e commit 769d12c

File tree

1 file changed

+21
-3
lines changed

1 file changed

+21
-3
lines changed

.travis.yml

+21-3
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,13 @@ language: cpp
22
cache: ccache
33
os: linux
44
dist: xenial
5+
stages:
6+
- check
7+
- test
58
matrix:
69
include:
710
- name: "First commit message adheres to guidelines at <a href=\"https://goo.gl/p2fr5Q\">https://goo.gl/p2fr5Q</a>"
11+
stage: check
812
if: type = pull_request
913
language: node_js
1014
node_js: "node"
@@ -13,13 +17,27 @@ matrix:
1317
bash -x tools/lint-pr-commit-message.sh ${TRAVIS_PULL_REQUEST};
1418
fi
1519
- name: "Linter"
20+
stage: check
1621
language: node_js
1722
node_js: "node"
18-
env:
19-
- NODE=$(which node)
2023
script:
21-
- make lint
24+
- NODE=$(which node) make lint
25+
- name: "Prepare ccache"
26+
stage: check
27+
addons:
28+
apt:
29+
sources:
30+
- ubuntu-toolchain-r-test
31+
packages:
32+
- g++-6
33+
install:
34+
- export CC='ccache gcc-6' CXX='ccache g++-6' JOBS=2
35+
- ./configure
36+
- make -j2 V=
37+
script:
38+
- true
2239
- name: "Test Suite"
40+
stage: test
2341
addons:
2442
apt:
2543
sources:

0 commit comments

Comments
 (0)