Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

V3.7.1 mapnik #3

Open
wants to merge 7 commits into
base: v3.7.0-mapnik-v3.6.2-carto
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,13 @@ matrix:
# Overrides `script` to disable publishing
before_script:
- npm test
# test building with out SSE_MATH enabled
- os: linux
env: BUILDTYPE=release SSE_MATH=false
node_js: 4
# Overrides `script` to disable publishing
before_script:
- npm test
# Coverage build
- os: linux
env: BUILDTYPE=debug CXXFLAGS="--coverage" LDFLAGS="--coverage"
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Changelog

## 3.7.1

- Mapnik 3.7.0 was not properly published to npm with node-pre-gyp. Releasing again with fix.
- Fix to `SSE_MATH` flag during building

## 3.7.0

Updated to 3.0.18 of mapnik. See [here](https://github.com/mapnik/mapnik/blob/master/CHANGELOG.md).
Expand Down
6 changes: 4 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
MODULE_NAME := $(shell node -e "console.log(require('./package.json').binary.module_name)")

SSE_MATH ?= true

default: release

ifneq (,$(findstring clang,$(CXX)))
Expand All @@ -23,11 +25,11 @@ pre_build_check:
mapnik-config -v

release_base: pre_build_check deps/geometry/include/mapbox/geometry.hpp node_modules
V=1 CXXFLAGS="-fno-omit-frame-pointer $(PROFILING_FLAG)" ./node_modules/.bin/node-pre-gyp configure build --ENABLE_GLIBC_WORKAROUND=true --loglevel=error --clang
V=1 CXXFLAGS="-fno-omit-frame-pointer $(PROFILING_FLAG)" ./node_modules/.bin/node-pre-gyp configure build --ENABLE_GLIBC_WORKAROUND=true --enable_sse=$(SSE_MATH) --loglevel=error --clang
@echo "run 'make clean' for full rebuild"

debug_base: pre_build_check deps/geometry/include/mapbox/geometry.hpp node_modules
V=1 ./node_modules/.bin/node-pre-gyp configure build --ENABLE_GLIBC_WORKAROUND=true --loglevel=error --debug --clang
V=1 ./node_modules/.bin/node-pre-gyp configure build --ENABLE_GLIBC_WORKAROUND=true --enable_sse=$(SSE_MATH) --loglevel=error --debug --clang
@echo "run 'make clean' for full rebuild"

release: mason_packages/.link/bin/mapnik-config
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"url": "http://github.com/mapnik/node-mapnik",
"homepage": "http://mapnik.org",
"author": "Dane Springmeyer <[email protected]> (mapnik.org)",
"version": "3.7.0",
"version": "3.7.1",
"mapnik_version":"v3.0.18",
"main": "./lib/mapnik.js",
"binary": {
Expand Down
Binary file not shown.
Binary file not shown.
24 changes: 20 additions & 4 deletions test/vector-tile.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2400,18 +2400,26 @@ describe('mapnik.VectorTile ', function() {
assert.equal(vtile.reportGeometryValidity({split_multi_features:true}).length, 0);
}
var expected = './test/data/vector_tile/tile0-simplify_distance.mvt';
var expected_nosse = './test/data/vector_tile/tile0-simplify_distance.nosse.mvt';
var actual = './test/data/vector_tile/tile0-simplify_distance.actual.mvt';
if (!existsSync(expected) || process.env.UPDATE) {
fs.writeFileSync(expected, vtile.getData());
}
if (!existsSync(expected_nosse)) {
fs.writeFileSync(expected_nosse, vtile.getData());
}
var expected_data = fs.readFileSync(expected);
var expected_nosse_data = fs.readFileSync(expected_nosse);
fs.writeFileSync(actual, vtile.getData());
var actual_data = fs.readFileSync(actual);
var vt1 = new mapnik.VectorTile(0,0,0);
vt1.setData(expected_data);
var vt2 = new mapnik.VectorTile(0,0,0);
vt2.setData(actual_data);
assert.equal(JSON.stringify(vt1.toJSON()) == JSON.stringify(vt2.toJSON()), true);
vt2.setData(expected_nosse_data);
var vt3 = new mapnik.VectorTile(0,0,0);
vt3.setData(actual_data);
assert.equal(JSON.stringify(vt1.toJSON()) == JSON.stringify(vt3.toJSON()) ||
JSON.stringify(vt2.toJSON()) == JSON.stringify(vt3.toJSON()), true);
done();
});
});
Expand All @@ -2432,18 +2440,26 @@ describe('mapnik.VectorTile ', function() {
assert.equal(vtile.reportGeometryValidity({split_multi_features:true}).length, 0);
}
var expected = './test/data/vector_tile/tile0-simple_and_distance.mvt';
var expected_nosse = './test/data/vector_tile/tile0-simple_and_distance.nosse.mvt';
var actual = './test/data/vector_tile/tile0-simple_and_distance.actual.mvt';
if (!existsSync(expected) || process.env.UPDATE) {
fs.writeFileSync(expected, vtile.getData());
}
if (!existsSync(expected_nosse)) {
fs.writeFileSync(expected_nosse, vtile.getData());
}
var expected_data = fs.readFileSync(expected);
var expected_nosse_data = fs.readFileSync(expected_nosse);
fs.writeFileSync(actual, vtile.getData());
var actual_data = fs.readFileSync(actual);
var vt1 = new mapnik.VectorTile(0,0,0);
vt1.setData(expected_data);
var vt2 = new mapnik.VectorTile(0,0,0);
vt2.setData(actual_data);
assert.equal(JSON.stringify(vt1.toJSON()) == JSON.stringify(vt2.toJSON()), true);
vt2.setData(expected_nosse_data);
var vt3 = new mapnik.VectorTile(0,0,0);
vt3.setData(actual_data);
assert.equal(JSON.stringify(vt1.toJSON()) == JSON.stringify(vt3.toJSON()) ||
JSON.stringify(vt2.toJSON()) == JSON.stringify(vt3.toJSON()), true);
done();
});
});
Expand Down