guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GFortran can’t find system headers


From: Ludovic Courtès
Subject: Re: GFortran can’t find system headers
Date: Tue, 15 Oct 2013 22:17:53 +0200
User-agent: Gnus/5.130007 (Ma Gnus v0.7) Emacs/24.3 (gnu/linux)

Nikita Karetnikov <address@hidden> skribis:

> I’m trying to package APL, which requires LAPACK, which requires
> Fortran.

Cool.

> Here’s my attempt to add the last one:
>
> (define-public gfortran-4.8
>   (package (inherit gcc-4.8)
>     (name "gfortran")
>     (arguments `(#:configure-flags '("--enable-languages=fortran")))))
>
> I get the following error while trying to build it:
>
> The directory that should contain system headers does not exist:
>   /usr/include

Yes, the problem is that the your ‘arguments’ field above completely
overrides that of ‘gcc-4.8’.

Instead, what should do is preserve the arguments; the value associated
with #:configure-flags should be changed to replace any
--enable-languages=.* flag with yours.  See ‘gcc-boot0’ in base.scm for
how to do that.

Alternately, you could turn the current ‘gcc-4.8’ definition into a
‘make-gcc-4.8’ procedure like this:

  (define* (make-gcc-4.8 #:key languages)
    (package
       ...

       #:configure-flags ... ,(string-join languages ",")

       ...))

  (define gcc-4.8
    (make-gcc-4.8 #:languages '("c" "c++")))

That would probably be easier to work with.

HTH,
Ludo’.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]