erdc / proteus

A computational methods and simulation toolkit
http://proteustoolkit.org
MIT License
88 stars 56 forks source link

Hashdist: grib_api cannot find openjpeg #334

Open robertsawko opened 8 years ago

robertsawko commented 8 years ago

I am trying to solve breaking compilation with hashdist. I think I can overcome this problem, but I would like to do it the hashdist way. Unfortuntately, it quickly outsmarted me and I cannot really figure out what's wrong about this.

My compilation breaks at grib_api:

[grib_api] libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I. -DGRIB_TEMPLATES_PATH=\"/home/robert/.hashdist/bld/grib_api/7ecsgry6z5mj/share/grib_api/s
amples\" -DGRIB_SAMPLES_PATH=\"/home/robert/.hashdist/bld/grib_api/7ecsgry6z5mj/share/grib_api/samples\" -DGRIB_DEFINITION_PATH=\"/home/robert/.has
hdist/bld/grib_api/7ecsgry6z5mj/share/grib_api/definitions\" -I/home/robert/.hashdist/bld/jasper/5hc2zdijmzwz/include -I/home/robert/.hashdist/bld/
openjpeg/onnv7cguoet5/include -I/home/robert/.hashdist/bld/patchelf/k3rloj265ogt/include -pedantic -Wall -g -O2 -I/home/robert/.hashdist/bld/jasper
/5hc2zdijmzwz/include -MT grib_openjpeg_encoding.lo -MD -MP -MF .deps/grib_openjpeg_encoding.Tpo -c grib_openjpeg_encoding.c  -fPIC -DPIC -o .libs/
grib_openjpeg_encoding.o
[grib_api] grib_openjpeg_encoding.c:14:22: fatal error: openjpeg.h: No such file or directory
[grib_api] compilation terminated.

Even though the file sits where it's supposed to:

%ls ~/.hashdist/bld/openjpeg/onnv7cguoet5/include
openjpeg-2.1  openjpeg.h

The openjpeg.h file is a symbolic link to a file inside openjpeg-2.1 directory. The linking is done via hashdist via fix_include step. Nothing else seems to be out of ordinary. The correct include directory is clearly picked up by grib_api. Can you let me know if you can see what's going wrong. I am working from archlinux/stable distribution. Fresh buiild.

robertsawko commented 8 years ago

Okay, I think I located the fault to openjpeg.yaml file. It seems that on my commit it compiles the version 2.1 but it makes a symbolic link to version 1.5. I am on commit hashdist/hashstack@0355f7b, but I can see the problem on the latest commit to in this file. See the fix_include step.

I am trying to edit yaml file and remove openjpeg from .hashidist/bld to force rebuild file but that doesn't seem to change anything and still 2.1 is used. I suppose there's some temporary file sitting in somewhere...

robertsawko commented 8 years ago

Perhaps this should have been a hashdist issue all along. I have now created a pull request hashdist/hashstack#926 back onto stable/arch but I think the same problem is on master and presumably some other branches. My proteus compilation has now passed the problematic step, but I won't close this until I know that you received this message.

cekees commented 8 years ago

OK, thanks a lot. Let's leave this open until I've made sure the hashstack fix is included in the .hashstack_version that we store as the default proteus stack.

robertsawko commented 8 years ago

Yep, it's the c0q1 tests which are crashing. More precisely it's test_c0q1() and apparently it's becuase it has something to do with test_hexMesh_3x3=False. Setting that to True makes the whole file run.

adimako commented 5 years ago

This should be sorted @cekees. Or no more relevant?