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

"...build constraints exclude all Go files in..." #2

Open
catrevil opened this issue Jun 17, 2020 · 1 comment
Open

"...build constraints exclude all Go files in..." #2

catrevil opened this issue Jun 17, 2020 · 1 comment

Comments

@catrevil
Copy link

I'm not sure how to get around this.

I'm trying to cross-compile this for windows 64 bit since the "...gcc.exe: filename too long..." issue on windows is due to the limitations of the OS's FILENAME length.

Upon search of the error, there is a claim that you cannot cross-compile something that uses cgo?

I just want to use this for windows 64 bit...
What do you advise?

I have all dependent packages in what I assume are there appropriate directory structures.

The error is as follows:
GOOS=windows GOARCH=amd64 go build

../../barnex/fftw/fftw.go:7:2: build constraints exclude all Go files in /home/catrevil/go/src/github.com/barnex/fftw/internal/double

../../barnex/fftw/fftw.go:8:2: build constraints exclude all Go files in /home/catrevil/go/src/github.com/barnex/fftw/internal/float

@catrevil
Copy link
Author

It is actually possible to compile this for Windows 10 on a Linux machine! I am not sure how to make it version check as of right now, but one needs only to set anything related to memalign to 0 instead of 1 within the config.h file, while additionally setting HAVE_MALLOC_H (iirc) to 0, while ensuring that OUR_MALLOC was set to 1. I also used xgo for this, but I think it can be done in a simpler manner. Making the changes notes would cause an inability to compile for other OS if my understanding is correct.

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

1 participant