You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2019/03/01 06:15:25 UTC

[GitHub] Tevic edited a comment on issue #3680: go static build error

Tevic edited a comment on issue #3680: go static build error
URL: https://github.com/apache/pulsar/issues/3680#issuecomment-468556225
 
 
   I've figure out a workaround:
   1.install the requirements for build cpp client
   2.build cpp client, finally make install
   3.download curl source build and install, with specific build flags:
   ```
   ./configure --disable-shared --enable-static --disable-ldap --disable-sspi
   make
   make install
   ```
   4.build your go code use command like this:
   ```
   CGO_CPPFLAGS="-I/usr/local/include -I/usr/include" CGO_LDFLAGS="-L/usr/local/lib -L/usr/lib -lcurl -lssl -lcrypto -lcrypto -lz -lpulsar -lstdc++ -lboost_system -lboost_regex -lprotobuf -ldl" go build -ldflags '-extldflags "-static"' hello.go
   
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services