[Bug 1217751] New: PETSc packaging is broken
https://bugzilla.suse.com/show_bug.cgi?id=1217751 Bug ID: 1217751 Summary: PETSc packaging is broken Classification: openSUSE Product: openSUSE Tumbleweed Version: Current Hardware: Other OS: Other Status: NEW Severity: Normal Priority: P5 - None Component: Other Assignee: screening-team-bugs@suse.de Reporter: badshah400@gmail.com QA Contact: qa-bugs@suse.de Target Milestone: --- Found By: --- Blocker: --- This is partly a rant, partly a cry for help brought about by trying to build a package that depends on petsc as it appears in Factory. TL;DR it is hell! The various flavours of the PETSc package install their headers and libraries to multiple non-standard locations (even after accounting for mpi paths). For example: * petsc-serial - Headers are in the `/usr/lib64/petsc/3.18.5/linux-gnu-c-opt/include/` dir, they should be somewhere in `/usr/include` - Shared lib is in `/usr/lib64/petsc/3.18.5/linux-gnu-c-opt/lib/`; should be in `/usr/lib64/petsc` at worst. - Pkgconfig file is in `/usr/lib64/petsc/3.18.5/linux-gnu-c-opt/lib/pkgconfig/` where pkgconfig does not even look. Not surprisingly, installing petsc-devel and doing `pkgconfig --libs petsc` does not work. Side note: there is also a bonus 0 byte PETSc.pc file in the same dir. `petsc.pc` should be installed to `/usr/lib64/pkgconfig` - There is a supposedly-arch independent `share` dir in `/usr/lib64/petsc/3.18.5/linux-gnu-c-opt` * petsc-openmpi4-devel (and other mpi/hpc flavours I have not dared to look into) - Headers: `/usr/lib64/mpi/gcc/openmpi4/lib64/petsc/3.18.5/linux-gnu-c-opt/include/` - Shared lib and pkgconfig file: `/./usr/lib64/mpi/gcc/openmpi4/lib64/petsc/3.18.5/linux-gnu-c-opt/lib/` ... You get the idea. There is no predictability to determining paths to headers and libraries when using petsc as a dependency. Obviously, with the above setup, pkg-config goes out of the window and there is nothing to make up for it, no petsc-config binary or such. Imagine that petsc gets update to version 3.20.0, dependent packages have to modify their specfiles to get the include path right again. And please don't tell me to use gymnastics like: ``` %define petsc_version %(rpm -q --queryformat="%%{version}" petsc-openmpi4-devel) %define petsc_path %{openmpi_prefix}/%{_lib}/petsc/%{petsc_version}/linux-gnu-c-opt ``` Partly, I was looking into updating petsc to version 3.20.0, but the specfile scared me a little bit, I won't lie. -- You are receiving this mail because: You are on the CC list for the bug.
https://bugzilla.suse.com/show_bug.cgi?id=1217751 https://bugzilla.suse.com/show_bug.cgi?id=1217751#c1 --- Comment #1 from Atri Bhattacharya <badshah400@gmail.com> --- Fwiw, I looked at Fedora's petsc package (serial flavour), and both their spec file and paths are: * Headers: `/usr/include/petsc/` * Lib: `/usr/lib64/` * Pkgconfig: `/usr/lib64/pkgconfig/` So it does not have to be the mess we have right now. -- You are receiving this mail because: You are on the CC list for the bug.
https://bugzilla.suse.com/show_bug.cgi?id=1217751 https://bugzilla.suse.com/show_bug.cgi?id=1217751#c3 --- Comment #3 from Atri Bhattacharya <badshah400@gmail.com> --- Thanks for the clarifications, I am working on cleaning this up and updating the package. -- You are receiving this mail because: You are on the CC list for the bug.
https://bugzilla.suse.com/show_bug.cgi?id=1217751 https://bugzilla.suse.com/show_bug.cgi?id=1217751#c6 Atri Bhattacharya <badshah400@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |IN_PROGRESS --- Comment #6 from Atri Bhattacharya <badshah400@gmail.com> --- (In reply to Egbert Eich from comment #5)
Hope you don't mind that I'm assigning this to you. It looks like you've work-arounded your issues. Please feel free to simplify the non-HPC bits of petsc.
Thanks, I hope to improve work on this over the next couple of weeks or so. -- You are receiving this mail because: You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@suse.com