Skip to content
This repository has been archived by the owner on Jan 25, 2022. It is now read-only.

Build error #1

Closed
Tucanix opened this issue Dec 19, 2019 · 5 comments
Closed

Build error #1

Tucanix opened this issue Dec 19, 2019 · 5 comments

Comments

@Tucanix
Copy link

Tucanix commented Dec 19, 2019

Hello, when I try to build any of the examples I get this error:

# github.com/maneac/go-ultralight
/home/.tucanix/go/src/github.com/maneac/go-ultralight/SDK/bin/linux/libUltralightCore.so: undefined reference to `typeinfo for std::thread::_State@GLIBCXX_3.4.22'
/home/.tucanix/go/src/github.com/maneac/go-ultralight/SDK/bin/linux/libUltralightCore.so: undefined reference to `std::thread::_M_start_thread(std::unique_ptr<std::thread::_State, std::default_delete<std::thread::_State> >, void (*)())@GLIBCXX_3.4.22'
/home/.tucanix/go/src/github.com/maneac/go-ultralight/SDK/bin/linux/libUltralightCore.so: undefined reference to `std::thread::_State::~_State()@GLIBCXX_3.4.22'
collect2: error: ld returned 1 exit status­

Version:
go version go1.13.4 linux/amd64
gcc version 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.12)
Ubuntu 16.04.6 LTS

@prologic
Copy link

I'm running into this:

prologic@Jamess-MacBook
Mon Dec 23 13:15:31
~/Projects/ubrowser
 1
$ GOPROXY="" go build .
go build github.com/maneac/go-ultralight: invalid flag in #cgo LDFLAGS: -Wl,-rpath,.

@maneac
Copy link
Owner

maneac commented Jan 14, 2020

I'm running into this:

prologic@Jamess-MacBook
Mon Dec 23 13:15:31
~/Projects/ubrowser
 1
$ GOPROXY="" go build .
go build github.com/maneac/go-ultralight: invalid flag in #cgo LDFLAGS: -Wl,-rpath,.

This can be solved by enabling those flags in the environment:
export CGO_LDFLAGS_ALLOW=.*

You may also need to statically set the SDK binary path for correct detection:
export LD_LIBRARY_PATH=$GOPATH/src/github.com/maneac/go-ultralight/SDK/bin/linux:$LD_LIBRARY_PATH

@maneac
Copy link
Owner

maneac commented Jan 14, 2020

Hello, when I try to build any of the examples I get this error:

# github.com/maneac/go-ultralight
/home/.tucanix/go/src/github.com/maneac/go-ultralight/SDK/bin/linux/libUltralightCore.so: undefined reference to `typeinfo for std::thread::_State@GLIBCXX_3.4.22'
/home/.tucanix/go/src/github.com/maneac/go-ultralight/SDK/bin/linux/libUltralightCore.so: undefined reference to `std::thread::_M_start_thread(std::unique_ptr<std::thread::_State, std::default_delete<std::thread::_State> >, void (*)())@GLIBCXX_3.4.22'
/home/.tucanix/go/src/github.com/maneac/go-ultralight/SDK/bin/linux/libUltralightCore.so: undefined reference to `std::thread::_State::~_State()@GLIBCXX_3.4.22'
collect2: error: ld returned 1 exit status­

Version:
go version go1.13.4 linux/amd64
gcc version 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.12)
Ubuntu 16.04.6 LTS

I can't be certain, but I believe the issue is due to an old version of GCC. Updating to GCC-8+ should work.

@prologic
Copy link

I'm running into this:

prologic@Jamess-MacBook
Mon Dec 23 13:15:31
~/Projects/ubrowser
 1
$ GOPROXY="" go build .
go build github.com/maneac/go-ultralight: invalid flag in #cgo LDFLAGS: -Wl,-rpath,.

This can be solved by enabling those flags in the environment:
export CGO_LDFLAGS_ALLOW=.*

You may also need to statically set the SDK binary path for correct detection:
export LD_LIBRARY_PATH=$GOPATH/src/github.com/maneac/go-ultralight/SDK/bin/linux:$LD_LIBRARY_PATH

This helped a little bit but now I get:

prologic@Jamess-MacBook
Wed Jan 22 21:53:42
~/Projects/ubrowser
 0
$ CGO_CFLAGS="-I /Users/prologic/tmp/ultralight/include" go build
# github.com/raff/ultralight-go
../../go/pkg/mod/github.com/raff/ultralight-go@v0.0.0-20190620222822-d2efebcfd598/ultralight.go:378:50: could not determine kind of name for C.kWindowFlags_Maximizable
../../go/pkg/mod/github.com/raff/ultralight-go@v0.0.0-20190620222822-d2efebcfd598/ultralight.go:378:25: could not determine kind of name for C.kWindowFlags_Resizable
../../go/pkg/mod/github.com/raff/ultralight-go@v0.0.0-20190620222822-d2efebcfd598/ultralight.go:378:3: could not determine kind of name for C.kWindowFlags_Titled

I don't know what any of this means at the moment... But I'll keep poking around...

@maneac
Copy link
Owner

maneac commented Mar 14, 2020

The later issues are due to an update method signature in the v1.1 SDK. A patch is coming shortly

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

No branches or pull requests

3 participants