use node-pre-gyp binary in npm install

This commit is contained in:
Mike Morris
2015-02-17 16:56:16 -05:00
parent 5330d9c417
commit 24946b29fa
3 changed files with 13 additions and 6 deletions

View File

@@ -61,5 +61,5 @@ test: test-js test-suite
.PHONY: clean
clean:
rm -rf build
rm -rf build lib
rm -f $(MBGL)/config/$(HOST).gypi

View File

@@ -4,13 +4,20 @@ Renders map tiles with [Mapbox GL](https://github.com/mapbox/mapbox-gl-native).
[![Build Status](https://api.travis-ci.com/mapbox/node-mapbox-gl-native.svg?token=Phdq58g7NsfstW6gyeYW)](https://magnum.travis-ci.com/mapbox/node-mapbox-gl-native)
## Loading the module
## Installing
To compile this module, make sure all submodules are initialized
By default, installs binaries. On these platforms no external dependencies are needed.
- 64 bit OS X or 64 bit Linux
- Node v0.10.x
Just run:
```js
var mbgl = require('mbgl');
```
npm install mbgl
```
However, other platforms will fall back to a source compile with `make build`. To compile this module, make sure all submodules are initialized.
## Rendering a map tile

View File

@@ -32,7 +32,7 @@
"tape": "^3.5.0"
},
"scripts": {
"install": "make",
"install": "node-pre-gyp install || make",
"test": "make test"
},
"gypfile": true,