I understand this thread is really old, but I thought updating the
group with a solution might help those that stumble across this in the
future.

I had some success removing dynamic dependencies on protoc and making
the binary static using Ermine. Please refer to this wiki -
http://www.coderanch.com/how-to/java/ProtocIndependentBinary

Thanks
- Deepak

On Jul 10 2010, 9:16 pm, Chao Wang <jacky.chao.w...@gmail.com> wrote:
> Will it solve the libz.so.1 linking problem?
>
> Thanks,
> Jacky
>
>
>
>
>
>
>
> On Sat, Jul 10, 2010 at 3:11 AM, Kenton Varda <ken...@google.com> wrote:
> > LDFLAGS=-static isn't good enough?
>
> > On Fri, Jul 9, 2010 at 6:08 AM, Oliver Jowett 
> > <oliver.jow...@gmail.com>wrote:
>
> >> Jacky wrote:
> >> > Many thanks!  sorry for the late reply - I've just went back. :)
>
> >> > I tried this:
>
> >> > jacky@alpha:~/workspace/protobuf-2.3.0/src$ ldd protoc
> >> >         linux-vdso.so.1 =>  (0x00007fff427ba000)
> >> >         libz.so.1 => /lib/libz.so.1 (0x00007fe2e1485000)
> >> >         libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00007fe2e1171000)
> >> >         libm.so.6 => /lib/libm.so.6 (0x00007fe2e0eed000)
> >> >         libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x00007fe2e0cd6000)
> >> >         libpthread.so.0 => /lib/libpthread.so.0 (0x00007fe2e0ab9000)
> >> >         libc.so.6 => /lib/libc.so.6 (0x00007fe2e0736000)
> >> >         /lib64/ld-linux-x86-64.so.2 (0x00007fe2e16b9000)
>
> >> > It seems like the binary file still depends on some gcc-related shared
> >> > objects.
>
> >> I actually spent a while today dealing with the same issue, and
> >> eventually admitted defeat and gave up on trying to convince libtool and
> >> friends to behave.
>
> >> Instead I did this:
>
> >> ./configure --disable-shared
> >> make
> >> rm src/protoc && make   # this is just to make the link command obvious
>
> >> Then rerun the final invocation of g++ that libtool runs to link protoc,
> >> adding "-static" to it.
>
> >> (Yes, I know, static binaries are evil, but so is libstdc++ version skew)
>
> >> -O
>
> >> --
> >> 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<protobuf%2bunsubscr...@googlegroups.com>
> >> .
> >> For more options, visit this group at
> >>http://groups.google.com/group/protobuf?hl=en.

-- 
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