I don't know if the author of protobuf-c frequents this discussion group.
 You might try e-mailing him directly.

On Tue, Sep 29, 2009 at 7:48 AM, zavi <zav...@gmail.com> wrote:

>
> Hello,
>
> I'm trying to compile protobuf-c and keep getting errors I didn't when
> I tried compiling on other machines.
> Obviously the preliminary protobuf compilation succeeded. I should
> also mention that the previous successful installations were on a 64-
> bit machine, where as the current machine I'm trying to install on is
> 32-bit.
>
> I'm trying to install using a predefined prefix. The protobuf
> installation was performed to the same target directory.
>
> When I run:
> ./configure --prefix=<prefix dir>
> I get this error -
> checking google/protobuf/stubs/common.h usability... no
> checking google/protobuf/stubs/common.h presence... no
> checking for google/protobuf/stubs/common.h... no
> configure: error:
> ERROR: protobuf headers are required.
> You must either install protobuf from google,
> or if you have it installed in a custom location
> you must add '-Iincludedir' to CXXFLAGS
> and '-Llibdir' to LDFLAGS.
>
> So I tried running this instead:
> ./configure CXXFLAGS=-I<prefix dir>/include LDFLAGS=-L=<prefix dir>/
> lib --prefix==<prefix dir>
>
> The operation succeeds although with an alarming warning:
> configure: WARNING: google/protobuf/stubs/common.h: accepted by the
> compiler, rejected by the preprocessor!
> configure: WARNING: google/protobuf/stubs/common.h: proceeding with
> the compiler's result
>
> When I try to run make now I fail on this error:
> make[2]: Entering directory `<install dir>/new_installs/protobuf-
> c-0.11/src/test'
> /bin/sh ../../libtool --tag=CXX --mode=link g++  -I<prefix dir>/
> include  -L<prefix dir>/lib -o cxx-generate-packed-data  cxx-generate-
> packed-data.o test-full.pb.o -lprotobuf
> g++ -I<prefix dir>/include -o cxx-generate-packed-data cxx-generate-
> packed-data.o test-full.pb.o  -L<prefix dir>/lib <prefix dir>//lib/
> libprotobuf.so   -Wl,--rpath -Wl,<prefix dir>//lib -Wl,--rpath -
> Wl,<prefix dir>//lib
> test-full.pb.o: In function `google::protobuf::GoogleOnceInit(int*,
> void (*)())':
> test-full.pb.cc:(.text._ZN6google8protobuf14GoogleOnceInitEPiPFvvE
> [google::protobuf::GoogleOnceInit(int*, void (*)())]+0x14): undefined
> reference to `pthread_once'
> collect2: ld returned 1 exit status
> make[2]: *** [cxx-generate-packed-data] Error 1
>
> I'd appreciate any ideas. I'm at a loss here.
>
> Some technical details:
> protobuf  2.1.0
> protobuf-c 0.11
> OS RedHat 5.2 i386
> gcc 4.3.1
>
> Thank you very much,
> Aviad
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
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 
protobuf+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/protobuf?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to