all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Ilmbase and openexr header files
@ 2015-09-06 16:52 Andreas Enge
  2015-09-07 12:03 ` Ludovic Courtès
  0 siblings, 1 reply; 4+ messages in thread
From: Andreas Enge @ 2015-09-06 16:52 UTC (permalink / raw)
  To: guix-devel

Hello,

the openexr package has ilmbase as a propagated input, since the openexr
header files include ilmbase header files. However, there is a problem with
subdirectories, since both packages put the include files into
.../include/OpenEXR.

Then, for instance,
   /gnu/store/bnp4nsy7v4lzw562k4v7w34jdg8vkc3s-openexr-2.2.0/include/OpenEXR/ImfInt64.h
contains a line
   #include "ImathInt64.h"
This is the file
   /gnu/store/6ih7f5cq1amgh134f75xw2sxk39p9gi7-ilmbase-2.2.0/include/OpenEXR/ImathInt64.h
which of course is not found, since it resides in the subdirectory OpenEXR.
(Well, I wonder whether things work when everything is installed together in
/usr/include/OpenEXR, but anyway this is not our case.)

There was an error when adding openexr support to vigra, which I repaired
with a kludge, and it is happening again in the package hugin that I am
preparing. So I wonder what would be the proper fix.

I see the following options:
1) In vigra, I added ilmbase explicitly as an input and a configure-flag
              (string-append "-DCMAKE_CXX_FLAGS=-I"
                             (assoc-ref %build-inputs "ilmbase")
                             "/include/OpenEXR"))))
   which adds the correct include directory with an "-I" option during
   compilation.
2) One might modify the environment variable CPATH in a separate phase
   by adding the OpenEXR subdirectory of ilmbase.
3) One might also patch the openexr header files, replacing
   #include "Imath...
   by
   #include "OpenEXR/Imath...

To me, 3) looks like the proper fix. What do you think?

Andreas

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Ilmbase and openexr header files
  2015-09-06 16:52 Ilmbase and openexr header files Andreas Enge
@ 2015-09-07 12:03 ` Ludovic Courtès
  2015-09-07 13:38   ` Andreas Enge
  0 siblings, 1 reply; 4+ messages in thread
From: Ludovic Courtès @ 2015-09-07 12:03 UTC (permalink / raw)
  To: Andreas Enge; +Cc: guix-devel

Andreas Enge <andreas@enge.fr> skribis:

> the openexr package has ilmbase as a propagated input, since the openexr
> header files include ilmbase header files. However, there is a problem with
> subdirectories, since both packages put the include files into
> .../include/OpenEXR.
>
> Then, for instance,
>    /gnu/store/bnp4nsy7v4lzw562k4v7w34jdg8vkc3s-openexr-2.2.0/include/OpenEXR/ImfInt64.h
> contains a line
>    #include "ImathInt64.h"
> This is the file
>    /gnu/store/6ih7f5cq1amgh134f75xw2sxk39p9gi7-ilmbase-2.2.0/include/OpenEXR/ImathInt64.h
> which of course is not found

This shouldn’t be a problem because:

--8<---------------cut here---------------start------------->8---
$ pkg-config OpenEXR --cflags
-pthread -I/gnu/store/bnp4nsy7v4lzw562k4v7w34jdg8vkc3s-openexr-2.2.0/include/OpenEXR -I/gnu/store/6ih7f5cq1amgh134f75xw2sxk39p9gi7-ilmbase-2.2.0/include/OpenEXR 
--8<---------------cut here---------------end--------------->8---

> There was an error when adding openexr support to vigra, which I repaired
> with a kludge, and it is happening again in the package hugin that I am
> preparing. So I wonder what would be the proper fix.

My guess is that Vigra doesn’t use pkg-config, and thus doesn’t get the
right -I flags.

Is that a correct guess?  :-)

Thanks,
Ludo’.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Ilmbase and openexr header files
  2015-09-07 12:03 ` Ludovic Courtès
@ 2015-09-07 13:38   ` Andreas Enge
  2015-09-07 15:56     ` Ludovic Courtès
  0 siblings, 1 reply; 4+ messages in thread
From: Andreas Enge @ 2015-09-07 13:38 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: guix-devel

On Mon, Sep 07, 2015 at 02:03:17PM +0200, Ludovic Courtès wrote:
> This shouldn’t be a problem because:
> --8<---------------cut here---------------start------------->8---
> $ pkg-config OpenEXR --cflags
> -pthread -I/gnu/store/bnp4nsy7v4lzw562k4v7w34jdg8vkc3s-openexr-2.2.0/include/OpenEXR -I/gnu/store/6ih7f5cq1amgh134f75xw2sxk39p9gi7-ilmbase-2.2.0/include/OpenEXR 
> --8<---------------cut here---------------end--------------->8---
> My guess is that Vigra doesn’t use pkg-config, and thus doesn’t get the
> right -I flags.
> Is that a correct guess?  :-)

Indeed it is, thanks for looking into this!

The same problem occurs with hugin, which I am currently packaging; it uses
pkg-config, but there are error messages
   -- WARNING: you are using the obsolete 'PKGCONFIG' macro, use FindPkgConfig
So it is possible that pkg-config is used incorrectly there. In any case,
I feel less bad now about using the same work-around...

Andreas

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Ilmbase and openexr header files
  2015-09-07 13:38   ` Andreas Enge
@ 2015-09-07 15:56     ` Ludovic Courtès
  0 siblings, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2015-09-07 15:56 UTC (permalink / raw)
  To: Andreas Enge; +Cc: guix-devel

Andreas Enge <andreas@enge.fr> skribis:

> On Mon, Sep 07, 2015 at 02:03:17PM +0200, Ludovic Courtès wrote:
>> This shouldn’t be a problem because:
>> --8<---------------cut here---------------start------------->8---
>> $ pkg-config OpenEXR --cflags
>> -pthread -I/gnu/store/bnp4nsy7v4lzw562k4v7w34jdg8vkc3s-openexr-2.2.0/include/OpenEXR -I/gnu/store/6ih7f5cq1amgh134f75xw2sxk39p9gi7-ilmbase-2.2.0/include/OpenEXR 
>> --8<---------------cut here---------------end--------------->8---
>> My guess is that Vigra doesn’t use pkg-config, and thus doesn’t get the
>> right -I flags.
>> Is that a correct guess?  :-)
>
> Indeed it is, thanks for looking into this!
>
> The same problem occurs with hugin, which I am currently packaging; it uses
> pkg-config, but there are error messages
>    -- WARNING: you are using the obsolete 'PKGCONFIG' macro, use FindPkgConfig
> So it is possible that pkg-config is used incorrectly there.

This is a warning emitted by a CMake function, I think.

Could you check in ‘CMakeOutput.log’ or whatever it’s called what
‘pkg-config’ it invoked and what its result was?

Thanks,
Ludo’.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-09-07 15:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-06 16:52 Ilmbase and openexr header files Andreas Enge
2015-09-07 12:03 ` Ludovic Courtès
2015-09-07 13:38   ` Andreas Enge
2015-09-07 15:56     ` Ludovic Courtès

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.