protobuf_BuildDesc_RequestHeader_2eproto() should be declared in
RequestHeader.pb.h.  Is it not?
What exact flags are you passing to protoc?

On Thu, Oct 9, 2008 at 8:29 AM, <[EMAIL PROTECTED]> wrote:

>
> I'm in the process of evaluating PB for a distributed cross language
> project I'm on. I've created a little 'hello world' app to test it's
> capabilities. I have created 2 simple .proto files,
> RequestHeader.proto and Rerender.proto. They compile and run as
> expected. However, if I import RequestHeader into Rerender with the
> following line:
>
> import "RequestHeader.proto";
>
> I get the following compile error:
>
> Error C2039: 'protobuf_BuildDesc_RequestHeader_2eproto' : is not a
> member of '`global namespace''
>
> The method protobuf_BuildDesc_RequestHeader_2eproto() doesn't exist
> anywhere in the code except where it errors out. Below is the
> offending method in Rerender.pb.cc that contains the error:
>
> void
>
> protobuf_BuildDesc_e_3a_2fVital_203_2e0_2fCPPProtobufTest_2fCPPProtobufTest_2fRerender_2eproto()
> {
>  static bool already_here = false;
>  if (already_here) return;
>  already_here = true;
>  GOOGLE_PROTOBUF_VERIFY_VERSION;
>  ::google::protobuf::DescriptorPool* pool =
>    ::google::protobuf::DescriptorPool::internal_generated_pool();
>
>  ::protobuf_BuildDesc_RequestHeader_2eproto(); // <-- ERROR
>  pool->InternalBuildGeneratedFile(
>    "\n;e:/Vital 3.0/CPPProtobufTest/CPPProtob"
>    "ufTest/Rerender.proto\032\023RequestHeader.pro"
>    "to\"\030\n\010Rerender\022\014\n\004Data\030\001 \002(\t", 108,
>
>
> &protobuf_BuildDesc_e_3a_2fVital_203_2e0_2fCPPProtobufTest_2fCPPProtobufTest_2fRerender_2eproto_AssignGlobalDescriptors);
> }
>
> I would assume that the ability to import one proto file into another
> is something that is exercised quite often, so I'm at a loss as to why
> the resulting code from protoc won't compile. I'm using protobuf 2.0.2
> built from source using VS 2008.
>
> Any assistance on how to get this working would be greatly
> appreciated. Thanks.
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To post to this group, send email to protobuf@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/protobuf?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to