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

Fatal Error: Cannot open module file 'lbfgsb_entry.mod0' for writing at (1): Permission denied #1

Open
idavydov opened this issue Sep 13, 2021 · 0 comments

Comments

@idavydov
Copy link
Owner

When using this module from another package, the following error occurs:

$ CGO_LDFLAGS="-framework Accelerate" CC=gcc-11 go install  bitbucket.org/Davydov/godon/godon@latest
# github.com/idavydov/go-lbfgsb
lbfgsb__entry.f90:51:23:

   51 | end module lbfgsb_entry
      |                       1
Fatal Error: Cannot open module file 'lbfgsb_entry.mod0' for writing at (1): Permission denied
compilation terminated.

This is related to golang/go#48349.

The current work-around is to use the -J and -I flags:

CGO_FFLAGS="-J $TMPDIR -I $TMPDIR" CGO_LDFLAGS="-framework Accelerate" CC=gcc-11 go install -x bitbucket.org/Davydov/godon/godon@latest

Please note that "-framework Accelerate" is specific to Mac OS X.

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