use more modern libpng version instead of the system-provided one and fix compile errors
This commit is contained in:
2
configure
vendored
2
configure
vendored
@@ -48,7 +48,7 @@ case ${MASON_PLATFORM} in
|
||||
*)
|
||||
GLFW_VERSION=a21f2377
|
||||
SQLITE_VERSION=system
|
||||
LIBPNG_VERSION=system
|
||||
LIBPNG_VERSION=1.6.13
|
||||
LIBCURL_VERSION=system
|
||||
LIBUV_VERSION=0.10.28
|
||||
ZLIB_VERSION=system
|
||||
|
||||
4
deps/gtest/gtest.gyp
vendored
4
deps/gtest/gtest.gyp
vendored
@@ -12,6 +12,10 @@
|
||||
'sources': [
|
||||
'gtest-all.cc'
|
||||
],
|
||||
'link_settings': {
|
||||
'xcode_settings': { 'OTHER_LDFLAGS': [ '-pthread' ] },
|
||||
'ldflags': [ '-pthread' ],
|
||||
},
|
||||
'direct_dependent_settings': {
|
||||
'include_dirs': [
|
||||
'.',
|
||||
|
||||
@@ -30,6 +30,11 @@
|
||||
'include_dirs': [
|
||||
'../include',
|
||||
],
|
||||
'link_settings': {
|
||||
'libraries': [
|
||||
'<@(png_static_libs)',
|
||||
],
|
||||
},
|
||||
'conditions': [
|
||||
['OS == "mac"', {
|
||||
'xcode_settings': {
|
||||
@@ -37,7 +42,6 @@
|
||||
'OTHER_CFLAGS': [ '<@(cflags)' ],
|
||||
}
|
||||
}, {
|
||||
'ldflags': [ '<@(ldflags)' ],
|
||||
'cflags_cc': [ '<@(cflags_cc)' ],
|
||||
'cflags': [ '<@(cflags)' ],
|
||||
}]
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
'OTHER_LDFLAGS': [ '<@(ldflags)' ],
|
||||
}
|
||||
}, {
|
||||
'ldflags': [ '<@(ldflags)' ],
|
||||
'libraries': [ '<@(ldflags)' ],
|
||||
}]
|
||||
],
|
||||
'dependencies': [
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
#include <cassert>
|
||||
#include <cstdlib>
|
||||
#include <stdexcept>
|
||||
#include <cstring>
|
||||
|
||||
|
||||
namespace mbgl {
|
||||
@@ -73,7 +74,7 @@ void readCallback(png_structp png, png_bytep data, png_size_t length) {
|
||||
if (reader->pos + length > reader->length) {
|
||||
png_error(png, "Read Error");
|
||||
} else {
|
||||
memcpy(data, reader->data + reader->pos, length);
|
||||
std::memcpy(data, reader->data + reader->pos, length);
|
||||
reader->pos += length;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
'<@(uv_ldflags)',
|
||||
'<@(sqlite3_ldflags)',
|
||||
'<@(curl_ldflags)',
|
||||
'<@(png_ldflags)'
|
||||
'<@(png_ldflags)',
|
||||
],
|
||||
},
|
||||
'targets': [
|
||||
|
||||
Reference in New Issue
Block a user