Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues with go build #40

Open
rajeshUber-zz opened this issue Aug 31, 2016 · 2 comments
Open

Issues with go build #40

rajeshUber-zz opened this issue Aug 31, 2016 · 2 comments

Comments

@rajeshUber-zz
Copy link

When i run: go build /home/uber/gocode/src/github.com/devsisters/goquic/example/server.go

I get the following:

github.com/devsisters/goquic

./lib/linux_amd64/libquic.a(logging.cc.o): In function logging::(anonymous namespace)::TickCount()': ./libquic/build/debug/../../src/base/logging.cc:150: undefined reference toclock_gettime'
./lib/linux_amd64/libquic.a(time_posix.cc.o): In function (anonymous namespace)::ClockNow(int)': ./libquic/build/debug/../../src/base/time/time_posix.cc:98: undefined reference toclock_gettime'
collect2: error: ld returned 1 exit status

Thanks in advance,
Rajesh

@rajeshUber-zz
Copy link
Author

Solved it by adding -lrt to cgo

@y123456yz
Copy link

#cgo LDFLAGS: -pthread -lgoquic -lquic -lssl -lcrypto -lstdc++ -lm -lprotobuf -lrt
change goquic.go can change the problem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants