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

Problems installing with spack #129

Open
ghost opened this issue Sep 22, 2023 · 8 comments
Open

Problems installing with spack #129

ghost opened this issue Sep 22, 2023 · 8 comments

Comments

@ghost
Copy link

ghost commented Sep 22, 2023

 30    ar cr libh5zzfp.a H5Zzfp_props.o
 31    ar cr libh5zzfp.a H5Zzfp_props_f.o

32 ar: libh5zzfp.a: error reading H5Zzfp_props_f.o: file truncated
33 make[1]: *** [Makefile:40: libh5zzfp.a(H5Zzfp_props.o)] Error 1
34 make[1]: *** Waiting for unfinished jobs....
35 make[1]: Leaving directory '/tmp/tech/spack-stage/spack-stage-h5z-zf
p-develop-7uhkj4qsuxmnpnwmo2jeicmnon7gbpf5/spack-src/src'
36 make: *** [Makefile:53: install] Error 2

See build log for details:
/tmp/tech/spack-stage/spack-stage-h5z-zfp-develop-7uhkj4qsuxmnpnwmo2jeicmnon7gbpf5/spack-build-out.txt

==> Warning: Skipping build of sw4-3.0-beta2-4vca7qyjynhz2tbw2soalrzs67jvfwse since h5z-zfp-develop-7uhkj4qsuxmnpnwmo2jeicmnon7gbpf5 failed
[+] /home/tech/spack/opt/spack/linux-ubuntu22.04-skylake/gcc-11.4.0/py-h5py-3.8.0-bedfnrd7fbxal2o63rvjwsa7tzc3hhnu
==> Error: sw4-3.0-beta2-4vca7qyjynhz2tbw2soalrzs67jvfwse: Package was not installed
==> Error: Installation request failed. Refer to reported errors for failing package(s).

ubuntu22.04.3
H5Z-ZFP
installation via spack

any suggestions ?

@markcmiller86
Copy link
Member

markcmiller86 commented Sep 29, 2023

What version of spack were you using and what was your spack command?

I will see if I can reproduce on a docker container.

@markcmiller86 markcmiller86 changed the title H5Z-ZFP Problems installing with spack Sep 29, 2023
@markcmiller86
Copy link
Member

It looks like spack has yet to make a new release since updating the spack recipe for H5Z-ZFP 1.1.1. Its on their develop branch now and so should go into the next spack release. That said, I dunno if their current develop branch will build all dependencies correctly. But, I'd say give it a try.

Following guidance here instead of doing git checkout releases/v0.20 do git checkout develop (which I think is default branch just after cloning anyways). And, if you cloned it in the distant past, do a git pull first to pull in everything on their develop branch.

Then follow other instructions as before.

@markcmiller86
Copy link
Member

So, this worked for me on an ubuntu docker system (ubuntu-jammy)

git clone https://github.com/llnl/spack.git
cd spack/
. ./share/spack/setup-env.sh
spack install h5z-zfp~fortran ^hdf5~mpi~fortran ^zfp~openmp

Note, default branch in the clone is develop.

It installed 19 packages and took about 20 mins.

spack find -p h5z-zfp
-- linux-ubuntu22.04-ivybridge / gcc@11.4.0 ---------------------
h5z-zfp@1.1.1  /tmp/spack/opt/spack/linux-ubuntu22.04-ivybridge/gcc-11.4.0/h5z-zfp-1.1.1-oxkdje4krexkyfnlo36y6kjm5qxf4stq
==> 1 installed package

@ghost
Copy link
Author

ghost commented Oct 6, 2023

home/tech/spack/var/spack/repos/builtin/packages/sw4/package.py:51, in edit:
48 os.environ["fftw"] = "yes"
49 os.environ["SW4ROOT"] = spec["proj"].prefix
50 os.environ["HDF5ROOT"] = spec["hdf5"].prefix

51        os.environ["H5ZROOT"] = spec["h5z-zfp"].prefix
     52        os.environ["ZFPROOT"] = spec["zfp"].prefix
     53        os.environ["FFTWHOME"] = spec["fftw"].prefix
     54        os.environ["EXTRA_LINK_FLAGS"] = "-lstdc++ -lm -ldl "

See build log for details:
/tmp/tech/spack-stage/spack-stage-sw4-3.0-pimxejebklplgx2wsg4a7ulo35jij5pc/spack-build-out.txt

tech@tech1:~$ spack find -p h5z-zfp
-- linux-ubuntu22.04-skylake / gcc@11.4.0 -----------------------
h5z-zfp@1.1.1 /home/tech/spack/opt/spack/linux-ubuntu22.04-skylake/gcc-11.4.0/h5z-zfp-1.1.1-y6dhjpupaev2dy2oulaol2gms4uujyhk

@ghost
Copy link
Author

ghost commented Oct 6, 2023

==> Error: KeyError: 'No spec with name h5z-zfp in sw4@=3.0%gcc@=11.4.0+fftw+hdf5+openmp+proj~zfp build_system=makefile arch=linux-ubuntu22.04-skylake ^autoconf

@ghost
Copy link
Author

ghost commented Oct 17, 2023

51        os.environ["H5ZROOT"] = spec["h5z-zfp"].prefix

@markcmiller86
Copy link
Member

==> Error: KeyError: 'No spec with name h5z-zfp in sw4@=3.0%gcc@=11.4.0+fftw+hdf5+openmp+proj~zfp build_system=makefile arch=linux-ubuntu22.04-skylake ^autoconf

The ~zfp is disabling zfp in the sw4 build. If you disable zfp, you certainly cannot have h5z-zfp. The fact that spack failed instead of proceeding with sw4 build sounds like its not handling cases where zfp has been removed from the build. Lets go look at that code...

@markcmiller86
Copy link
Member

So, I think you need to change ~zfp to +zfp. Have you tried that.

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