Skip to content

Commit

Permalink
Merge branch 'master' into down-integrate
Browse files Browse the repository at this point in the history
  • Loading branch information
acozzette committed Mar 13, 2018
2 parents 0400cca + 89b5333 commit afe96b6
Show file tree
Hide file tree
Showing 33 changed files with 3,583 additions and 697 deletions.
3 changes: 2 additions & 1 deletion BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ internal_copied_filegroup(
srcs = WELL_KNOWN_PROTOS,
dest = "",
strip_prefix = "src",
visibility = ["//visibility:hidden"],
visibility = ["//visibility:private"],
)

[proto_library(
Expand Down Expand Up @@ -843,6 +843,7 @@ proto_lang_toolchain(
command_line = "--cpp_out=$(OUT)",
runtime = ":protobuf",
visibility = ["//visibility:public"],
blacklisted_protos = [":_internal_wkt_protos_genrule"],
)

proto_lang_toolchain(
Expand Down
5 changes: 5 additions & 0 deletions cmake/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,11 @@ further disable the option `-Dprotobuf_MSVC_STATIC_RUNTIME=OFF`.
If it reports NOTFOUND for zlib_include or zlib_lib, you might haven't put
the headers or the .lib file in the right directory.

If you already have ZLIB library and headers at some other location on your system then alternatively you can define following configuration flags to locate them:

-DZLIB_INCLUDE_DIR=<path to dir containing zlib headers>
-DZLIB_LIB=<path to dir containing zlib>

Build and testing protobuf as usual.

Notes on Compiler Warnings
Expand Down
5 changes: 2 additions & 3 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -184,9 +184,8 @@ AS_IF([test "$with_protoc" != "no"], [
])
AM_CONDITIONAL([USE_EXTERNAL_PROTOC], [test "$with_protoc" != "no"])

ACX_PTHREAD
AM_CONDITIONAL([HAVE_PTHREAD], [test "x$acx_pthread_ok" = "xyes"])

AX_PTHREAD
AM_CONDITIONAL([HAVE_PTHREAD], [test "x$ax_pthread_ok" = "xyes"])
# We still keep this for improving pbconfig.h for unsupported platforms.
AC_CXX_STL_HASH

Expand Down
4 changes: 4 additions & 0 deletions js/binary/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -971,6 +971,10 @@ jspb.utils.byteSourceToUint8Array = function(data) {
return /** @type {!Uint8Array} */(new Uint8Array(data));
}

if (data.constructor === Buffer) {
return /** @type {!Uint8Array} */(new Uint8Array(data));
}

if (data.constructor === Array) {
data = /** @type {!Array<number>} */(data);
return /** @type {!Uint8Array} */(new Uint8Array(data));
Expand Down
Loading

0 comments on commit afe96b6

Please sign in to comment.