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

cgo compile error #781

Closed
ghost opened this issue May 4, 2018 · 4 comments
Closed

cgo compile error #781

ghost opened this issue May 4, 2018 · 4 comments

Comments

@ghost
Copy link

ghost commented May 4, 2018

Seeing error:

invalid flag in #cgo LDFLAGS:  ...

Could be related to: golang/go#23749

Need to investigate different compiler options to use to make it work on Go 1.10

@ghost ghost added the golang label May 4, 2018
@ghost ghost added this to To do in YDK May 7, 2018
@ghost
Copy link
Author

ghost commented May 21, 2018

Workaround

  • Use a version of Go that doesn't have this problem

TODO

Need to document this in the YDK-Go README/docs

@ghost ghost added the documentation label May 21, 2018
@111pontes 111pontes added the bug label Mar 21, 2019
@111pontes
Copy link
Collaborator

Go 1.10 is the default version in many systems. This issue should be address soon as ydk-go would be broken out of the box for many users.

@ghost ghost added this to the 0.8.3 milestone Apr 2, 2019
@ghost
Copy link
Author

ghost commented Apr 2, 2019

Need to ensure the default Go version for platform (ubuntu/centos) is supported. If default version for platform is not supported, this should be documented along with the reason why. Need to check go version.

ygorelik pushed a commit to ygorelik/ydk-gen that referenced this issue Apr 25, 2019
@ygorelik
Copy link
Collaborator

The code specifies additional CGO flags to enable coverage tests. In order to ignore the flags the following environment variable should be set before compiling the Go code:

export CGO_ENABLED=1
export CGO_LDFLAGS_ALLOW="-fprofile-arcs|-ftest-coverage|--coverage"

Added above setting to Travis tests.

ygorelik pushed a commit to ygorelik/ydk-gen that referenced this issue Apr 25, 2019
ghost pushed a commit that referenced this issue May 16, 2019
ghost pushed a commit that referenced this issue May 16, 2019
@ghost ghost mentioned this issue May 16, 2019
@ghost ghost closed this as completed May 16, 2019
YDK automation moved this from To do to Done May 16, 2019
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
YDK
  
Done
Development

No branches or pull requests

2 participants