Skip to content

Commit ee157f4

Browse files
zbjornsonchearon
authored andcommitted
Use --target instead of building with each node version
1 parent b5aea29 commit ee157f4

File tree

8 files changed

+12
-19
lines changed

8 files changed

+12
-19
lines changed

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,6 @@ install:
2424
2525
export PREBUILD_SLUG="$TRAVIS_REPO_SLUG";
2626
27-
bash ci/install.sh osx "$PREBUILD_VERSION" "$PREBUILD_CANVAS_VERSION" "$PREBUILD_NODE_VERSIONS";
27+
bash -c 'export NVM_DIR=$HOME/.nvm; . $HOME/.nvm/nvm.sh; . ci/install.sh osx "$PREBUILD_VERSION" "$PREBUILD_CANVAS_VERSION" "$PREBUILD_NODE_VERSIONS"';
2828
2929
fi

appveyor.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
version: 0.0.{build}
22
image: Visual Studio 2017
33
install:
4-
- ps: Install-Product node 8 x64
4+
- ps: Install-Product node 10 x64
55
- set PREBUILD_SLUG=%APPVEYOR_REPO_NAME%
66
- npm install -g npm node-gyp
77
- set "PATH=%APPDATA%\npm;%PATH%"

ci/install.sh

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,11 @@ source ci/$OS/preinstall.sh
3232
cp ci/$OS/binding.gyp node-canvas/binding.gyp
3333

3434
for ver in $NODEJS_VERSIONS; do
35-
echo "------------ Building with node $ver ------------"
36-
37-
source ci/$OS/node_version.sh $ver;
35+
echo "------------ Building for node $ver ------------"
3836

3937
cd node-canvas
4038

41-
node-gyp rebuild || {
39+
node-gyp rebuild --target=$ver || {
4240
echo "error building in nodejs version $ver"
4341
exit 1;
4442
}
@@ -56,7 +54,6 @@ for ver in $NODEJS_VERSIONS; do
5654
done;
5755

5856
echo "------------ Releasing with release.js ------------"
59-
source ci/$OS/node_version.sh 11
6057
node ci/release.js $PREBUILD_VERSION || exit 1;
6158

6259
cd ..

ci/linux/node_version.sh

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

ci/linux/preinstall.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
# apt-get-style dependencies aren't done here since the
22
# linux build is done on a docker image that has them
33

4+
nvm install node # latest
5+
nvm use node # latest
6+
npm install -g node-gyp
7+
48
git clone git://anongit.gentoo.org/proj/pax-utils.git
59
cd pax-utils
610
PATH=$PATH:$PWD

ci/osx/node_version.sh

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

ci/osx/preinstall.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
nvm install node # latest
2+
nvm use node # latest
3+
npm install -g node-gyp
4+
15
brew update
26
brew install cairo pango librsvg python3 # python3 is for macpack
37
brew upgrade python # activates python 3

ci/win/node_version.sh

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

0 commit comments

Comments
 (0)