Commit Graph

3061 Commits

Author SHA1 Message Date
Josh Haberman
14e2b4fa51 A very small fix to silence some warnings.
Also updated the Gemfile.lock since alpha-4 has been
pushed to RubyGems.

Change-Id: I8ddc5f125f28aa9a33c88dfe48251a75a877e1d3
2015-09-28 08:56:14 -07:00
Feng Xiao
0e5686a707 Merge pull request #727 from AustinSchuh/arena_bounds_fix
Handled blocks being too small in arena.cc
2015-09-24 17:41:45 -07:00
Jan Tattermusch
c31f11deb4 expose GetOutputFile in csharp_names.h 2015-09-23 15:12:17 -07:00
Jan Tattermusch
97a1c1e08d Merge pull request #785 from jskeet/csharp-directories
Generate C# directory hierarchy with new option
2015-09-23 14:31:31 -07:00
Konstantin Podsvirov
f397ede7c6 Add CMake option protobuf_DEBUG_POSTFIX 2015-09-17 13:00:12 +03:00
Konstantin Podsvirov
e301946ca4 Simplify testing from CMake project to "check" target 2015-09-17 12:08:47 +03:00
Feng Xiao
c9418912cb Merge pull request #813 from 0xAAE/master
Add GOOGLE_ATTRIBUTE_NOINLINE to GetArena() and GetMaybeArenaPointer(…
2015-09-16 14:44:48 -07:00
Konstantin Podsvirov
d41601c249 Improved testing from CMake project
Build tests optimization
Now lite-test added to CTest collection
2015-09-16 12:55:35 +03:00
Konstantin Podsvirov
0a22fe59b7 Rename CMake option BUILD_SHARED_LIBS to protobuf_BUILD_SHARED_LIBS 2015-09-15 15:36:20 +03:00
Konstantin Podsvirov
620bd7418d Rename CMake option ZLIB to protobuf_WITH_ZLIB 2015-09-15 15:31:25 +03:00
Konstantin Podsvirov
673d32e093 Rename CMake option BUILD_TESTING to protobuf_BUILD_TESTS 2015-09-15 15:30:02 +03:00
Konstantin Podsvirov
2fa0439b00 Improved testing from CMake project 2015-09-15 15:01:05 +03:00
0xAAE
d41a3d630c Add GOOGLE_ATTRIBUTE_NOINLINE to GetArena() and GetMaybeArenaPointer() methods. This is to avoid "unresolved link" errors in MSVC 2015 during Release build 2015-09-15 01:46:28 +03:00
Feng Xiao
fbabf987e6 Merge pull request #769 from pkasting/metadata
Fix compile failures building protobuf DLLs on MSVC in Chromium's cod…
2015-09-10 12:46:21 -07:00
Feng Xiao
c8c5fed544 Merge pull request #766 from pkasting/hash
Refine check for unordered_{map|set} availability.
2015-09-10 12:45:22 -07:00
Feng Xiao
e61ff47ac3 Merge pull request #802 from bsilver8192/master
Small fixes
2015-09-08 22:23:03 -07:00
Brian Silverman
21f3d3777a Don't assume char is signed.
It isn't always, which causes problems when trying to put negative
values into the array with C++11.
2015-09-08 20:25:48 -04:00
Brian Silverman
133be3dc1f Use TEST_TMPDIR for writing temporary files if it's set.
Bazel expects all tests to do this.
2015-09-08 20:25:48 -04:00
Jisi Liu
0e606bc2eb Merge pull request #786 from pherl/master
Update objc script in generate_descriptor_proto.sh
2015-09-08 13:32:28 -07:00
Jisi Liu
ef50a2976e Update objc script in generate_descriptor_proto.sh 2015-09-08 13:21:45 -07:00
Paul Yang
e473761a9e Merge pull request #796 from jcanizales/add-missing-comma
Fix podspec by adding missing comma
2015-09-04 21:56:18 -07:00
Jorge Canizales
af66e9003f Fix podspec by adding missing comma 2015-09-04 13:16:40 -07:00
Jan Tattermusch
3778f52171 Merge pull request #794 from jskeet/any
Pack/Unpack implementation for Any.
2015-09-04 09:45:45 -07:00
Jon Skeet
e50461d809 Pack/Unpack implementation for Any.
We still need the JSON representation, which relies on something like a DescriptorPool to fetch message types from based on the type URL. That will come a bit later.
(The DescriptorPool comment in this commit is just a note which will prove useful if we use DescriptorPool itself.)
2015-09-04 12:43:26 +01:00
Joshua Haberman
4cb0edd778 Merge pull request #772 from dano/fix_scalar_map
Fix Python 3.4 cpp implementation
2015-09-04 10:12:49 +02:00
Feng Xiao
63eca470fd Merge pull request #793 from kbinani/fix_redefinition_BYTE_SIZE_macro
Rename 'BYTE_SIZE' macro to 'GOOGLE_PROTOBUF_BYTE_SIZE'
2015-09-03 22:10:19 -07:00
kbinani
9a06c8000e Rename 'BYTE_SIZE' macro to 'GOOGLE_PROTOBUF_BYTE_SIZE'
Xcode raises warning that says "'BYTE_SIZE' macro redefined".
The original 'BYTE_SIZE' macro definition is here, for example:
'/Applications/Xcode/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/mach/vm_param.h'
2015-09-04 14:00:16 +09:00
Jon Skeet
9489817df2 Regenerated code. Most changes are whitespace, removing trailing spaces.
Other changes are due to the well-known types changing without us regenerating.
2015-09-01 15:47:48 +01:00
Jon Skeet
ccd76802fa Stop adding a space to the end of lines for descriptor binary data. 2015-09-01 15:35:10 +01:00
Jon Skeet
75a18a39ca Specify csharp_namespace in descriptor.proto 2015-09-01 15:29:15 +01:00
Jon Skeet
5eb1fac983 Generate a directory hierarchy based on namespace (C#)
This introduces a new C# option, base_namespace.
If the option is not specified, the behaviour is as before: no directories are generated.
If the option *is* specified, all C# namespaces must be relative to the base namespace, and the directories are generated relative to that namespace.

Example:
- Any.proto declares csharp_namespace = "Google.Protobuf.WellKnownTypes"
- We build with --csharp_out=Google.Protobuf --csharp_opt=base_namespace=Google.Protobuf
- The Any.cs file is generated in Google.Protobuf/WellKnownTypes (where it currently lives)

We need a change to descriptor.proto before this will all work (it wasn't in the right C# namespace) but that needs the other descriptors to be regenerated too. See next commit...
2015-09-01 15:05:03 +01:00
Konstantin Podsvirov
905f464035 Using NEW behavior for CMP0022 in CMake project 2015-09-01 16:44:48 +03:00
Jon Skeet
0101a59b62 Remove vestigial reference to MakeFixedTag 2015-09-01 13:27:26 +01:00
Konstantin Podsvirov
d79e0379f2 Option for switching static runtime link policy with MSVC 2015-09-01 15:00:00 +03:00
Dan O'Reilly
d9598ca55d Fix Python 3.4 cpp implementation
Fixes the ScalarMapContainer/MessageMapContainer implementations on
Python 3.4, by dynamically allocating their PyTypeObjects using
PyType_FromSpecWithBases, instead of statically allocating them. This is
necessary because Python 3.4+ disallows statically allocating a class
with a dynamically allocated parent.

Signed-off-by: Dan O'Reilly <oreilldf@gmail.com>
2015-08-31 16:42:31 -04:00
Konstantin Podsvirov
20b882d469 Using find_package(ZLIB) with MSVC too 2015-08-31 16:23:40 +03:00
Konstantin Podsvirov
db01460042 Improved configure.ac parsing 2015-08-31 15:20:18 +03:00
Feng Xiao
0087da9d47 Merge remote-tracking branch 'origin/master' into beta-1
Conflicts:
	src/google/protobuf/extension_set.h
2015-08-29 16:42:55 -07:00
Joshua Haberman
cee703d736 Merge pull request #776 from haberman/pyfix
Fix for https://github.com/google/protobuf/issues/758
2015-08-29 16:29:23 -07:00
Josh Haberman
4472b4ad15 Fixed assignment syntax error.
Change-Id: Ifef8a300258214aae8f6b8516fbc61b7335b5724
2015-08-28 19:21:49 -07:00
Josh Haberman
fc80fad9d5 Fix for https://github.com/google/protobuf/issues/758
Change-Id: I590b34b96c84a3ba6e094a0bd86f153147ade3d3
2015-08-28 16:34:48 -07:00
Feng Xiao
f0640b5a04 Merge pull request #770 from pkasting/string_space
Move StringSpaceUsedIncludingSelf to lite library.
2015-08-28 14:09:00 -07:00
Feng Xiao
69ac02a216 Merge pull request #771 from pkasting/static_init_1
Remove a static initializer by removing a global of non-POD type.
2015-08-28 14:05:01 -07:00
Feng Xiao
67946e98a9 Merge pull request #569 from redivo/master
Fix GOOGLE_PROTOBUF_ATOMICOPS_ERROR syntax error
2015-08-28 13:34:35 -07:00
Austin Schuh
ad1d726cc2 Handled blocks being too small in arena.cc
When the user passed in a block which was smaller than the Block
structure, this code would blow past the end of the memory and
crash.  Check for that condition.
2015-08-28 11:10:55 -07:00
Feng Xiao
fb0af6d02e Merge pull request #768 from pkasting/time
Delete kNanosPerSecond from time.cc.
2015-08-28 10:28:44 -07:00
Peter Kasting
4f3bead537 Remove a static initializer by removing a global of non-POD type.
These are banned by the Google style guide, and Chromium has a hard
no-new-static-initializers policy preventing updating to a new version of
libprotobuf unless this is resolved.  This is the first such change, I'll need
to make at least one more in the future.

Luckily, the protobuf source tree already has an alternative to static
initializers in once.h; use that machinery instead.

I defined everything in the .cc file in a blob to replace the old implementation
rather than matching the .h layout precisely; let me know if a different
ordering is preferred.  I also eliminated the macro that used to be used here as
spelling everything out only takes one additional line, and the macro didn't
actually handle all details of using a particular member variable, just the
declaration, so it felt a bit error-prone.
2015-08-27 20:16:33 -07:00
Peter Kasting
f5a332553e It helps if you write macros correctly 2015-08-27 20:12:56 -07:00
Peter Kasting
a1be711e96 Try modifying check in hopes of passing upstream build 2015-08-27 19:59:06 -07:00
Peter Kasting
432771fa24 Review comments 2015-08-27 19:52:13 -07:00