Skip to content

Haskell project fails on FreeBSD: Missing (or bad) C library: gfortran #6570

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

Closed
yurivict opened this issue Mar 3, 2020 · 4 comments
Closed

Comments

@yurivict
Copy link

yurivict commented Mar 3, 2020

Configuring library for hmatrix-0.20.0.0.. cabal: Missing dependency on a foreign library: * Missing (or bad) C library: gfortran This problem can usually be solved by installing the system package that provides this library (you may need the "-dev" version). If the library is already installed but in a non-standard location then you can use the flags --extra-include-dirs= and --extra-lib-dirs= to specify where it is.If the library file does exist, it may contain errors that are caught by the C compiler at the preprocessing stage. In this case you can re-run configure with the verbosity flag -v3 to see the error messages. 

libgfortran.so is in /usr/local/lib/gcc9.

--extra-lib-dirs= is a cabal install flag.

Is there any way to specify the library location like this at the level of individual projects in the context of the FreeBSD port?

@gbaz
Copy link
Collaborator

gbaz commented Mar 4, 2020

you can place these flags in cabal.project files.

@arrowd
Copy link
Collaborator

arrowd commented Mar 12, 2020

We already have a workaround. It is not clear why cabal new-configure doesn't take --extra-lib-dirs into account.

@bgamari
Copy link
Contributor

bgamari commented Mar 15, 2020

For what it's worth, --extra-lib-dirs being ignored is tracked as #2997.

@gbaz
Copy link
Collaborator

gbaz commented Aug 29, 2021

resolving in favor of that

@gbaz gbaz closed this as completed Aug 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants