Bug 1571441

Summary: GRASS libs are not found by dynamic linker
Product: [Fedora] Fedora Reporter: Daniele Viganò <dennyvatwork>
Component: grassAssignee: Devrim Gündüz <devrim>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 28CC: cz172638, davejohansen, devrim, neteler, oliver, pertusus, volker27
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Unspecified   
Whiteboard:
Fixed In Version: grass-7.4.0-2.fc28 grass-7.4.0-2.fc27 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-05-01 07:42:49 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Make linker aware of grass
none
Patch for grass.spec none

Description Daniele Viganò 2018-04-24 19:46:53 UTC
Created attachment 1426212 [details]
Make linker aware of grass

Description of problem:

When installing GRASS (7.4 as writing) its libraries are not installed in /usr/lib64, but instead are located in /usr/lib64/grass74/lib thus are not found by the dynamic linker, i.e:

$ ldd /usr/lib64/grass74/lib/libgrass_raster.so
	linux-vdso.so.1 (0x00007ffc51338000)
	libgrass_gis.7.4.0.so => not found
	libgrass_gproj.7.4.0.so => not found
	libm.so.6 => /lib64/libm.so.6 (0x00007efd4c55c000)
	libdl.so.2 => /lib64/libdl.so.2 (0x00007efd4c358000)
	libc.so.6 => /lib64/libc.so.6 (0x00007efd4bf99000)
	/lib64/ld-linux-x86-64.so.2 (0x00007efd4cb1b000)


$ ldd /usr/lib64/grass74/lib/libgrass_vedit.so 
	linux-vdso.so.1 (0x00007ffc5b7fe000)
	libgrass_vector.7.4.0.so => not found
	libgrass_dbmiclient.7.4.0.so => not found
	libgrass_dbmibase.7.4.0.so => not found
	libgrass_gis.7.4.0.so => not found
	libm.so.6 => /lib64/libm.so.6 (0x00007fc1130b3000)
	libc.so.6 => /lib64/libc.so.6 (0x00007fc112cf4000)
	/lib64/ld-linux-x86-64.so.2 (0x00007fc113652000)

$ ldd /usr/lib64/grass74/lib/libgrass_*.so | grep 'not found' | wc -l
240

Version-Release number of selected component (if applicable):

$ rpm -qa | grep grass
grass-libs-7.4.0-1.fc28.x86_64
grass-devel-7.4.0-1.fc28.x86_64
grass-7.4.0-1.fc28.x86_64
grass-gui-7.4.0-1.fc28.x86_64


How reproducible:

Always


Steps to Reproduce:
1. ldd /usr/lib64/grass74/lib/libgrass_vedit.so
2. libgrass_* symbols are not found
3. -OR- try to compile an applicatin which depends on GRASS like QGIS3

Actual results:

$ ldd /usr/lib64/grass74/lib/libgrass_vedit.so 
	linux-vdso.so.1 (0x00007ffc5b7fe000)
	libgrass_vector.7.4.0.so => not found
	libgrass_dbmiclient.7.4.0.so => not found
	libgrass_dbmibase.7.4.0.so => not found
	libgrass_gis.7.4.0.so => not found
	libm.so.6 => /lib64/libm.so.6 (0x00007fc1130b3000)
	libc.so.6 => /lib64/libc.so.6 (0x00007fc112cf4000)
	/lib64/ld-linux-x86-64.so.2 (0x00007fc113652000)


Expected results:
ldd /usr/lib64/grass74/lib/libgrass_vedit.so 
	linux-vdso.so.1 (0x00007ffc4cd89000)
	libgrass_vector.7.4.0.so => /usr/lib64/grass74/lib/libgrass_vector.7.4.0.so (0x00007f327d378000)
	libgrass_dbmiclient.7.4.0.so => /usr/lib64/grass74/lib/libgrass_dbmiclient.7.4.0.so (0x00007f327d16d000)
	libgrass_dbmibase.7.4.0.so => /usr/lib64/grass74/lib/libgrass_dbmibase.7.4.0.so (0x00007f327cf5a000)
	libgrass_gis.7.4.0.so => /usr/lib64/grass74/lib/libgrass_gis.7.4.0.so (0x00007f327cd0e000)
	libm.so.6 => /lib64/libm.so.6 (0x00007f327c97a000)
	libc.so.6 => /lib64/libc.so.6 (0x00007f327c5bb000)
	libgrass_dgl.7.4.0.so => /usr/lib64/grass74/lib/libgrass_dgl.7.4.0.so (0x00007f327c3a2000)
	libgrass_dig2.7.4.0.so => /usr/lib64/grass74/lib/libgrass_dig2.7.4.0.so (0x00007f327c189000)
	libgrass_linkm.7.4.0.so => /usr/lib64/grass74/lib/libgrass_linkm.7.4.0.so (0x00007f327bf86000)
	libgrass_rtree.7.4.0.so => /usr/lib64/grass74/lib/libgrass_rtree.7.4.0.so (0x00007f327bd7b000)
	libgeos_c.so.1 => /lib64/libgeos_c.so.1 (0x00007f327bb45000)
	libgdal.so.20 => /lib64/libgdal.so.20 (0x00007f327a643000)
	libgrass_btree2.7.4.0.so => /usr/lib64/grass74/lib/libgrass_btree2.7.4.0.so (0x00007f327a43c000)
	libgrass_gproj.7.4.0.so => /usr/lib64/grass74/lib/libgrass_gproj.7.4.0.so (0x00007f327a232000)
	libgrass_raster.7.4.0.so => /usr/lib64/grass74/lib/libgrass_raster.7.4.0.so (0x00007f327a007000)
	libpq.so.5 => /lib64/libpq.so.5 (0x00007f3279dbe000)
	libgrass_datetime.7.4.0.so => /usr/lib64/grass74/lib/libgrass_datetime.7.4.0.so (0x00007f3279bb5000)
	libz.so.1 => /lib64/libz.so.1 (0x00007f327999e000)

[...cut...]

Additional info:

Before https://src.fedoraproject.org/cgit/rpms/grass.git/commit/?id=5f02b2aa69da7840ddb2cc9fed90aae7a5396736 libs where moved into /usr/lib64 from /usr/lib64/grass72/lib.

Another solution (a more clean one?) would be add a grass-x86_64.conf in /etc/ld.so.conf.d/ (as wine an others do):

$ cat /etc/ld.so.conf.d/grass-x86_64.conf 
/usr/lib64/grass74/lib

Comment 1 Daniele Viganò 2018-04-24 22:54:41 UTC
Created attachment 1426295 [details]
Patch for grass.spec

Adds /usr/lib[64]/grass74/lib to ld.so.conf

Comment 2 markusN 2018-04-25 20:52:33 UTC
Thanks, Daniele! I have committed the change [1]. Unfortunately builds are broken in F28 at time due to an (unrelated)
   "nothing provides libsuperlu.so.5()(64bit) needed by armadillo"

Hope that gets fixed soon in koji.

[1] https://src.fedoraproject.org/rpms/grass/c/d0be3bb0abbb079c4f4f0b06652162828053f4d5?branch=master

Comment 3 Fedora Update System 2018-04-26 17:24:57 UTC
grass-7.4.0-2.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-146acddf9e

Comment 4 Fedora Update System 2018-04-27 15:05:54 UTC
grass-7.4.0-2.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-146acddf9e

Comment 5 Fedora Update System 2018-04-27 16:46:36 UTC
grass-7.4.0-2.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2018-e13babe183

Comment 6 Fedora Update System 2018-04-28 01:53:51 UTC
grass-7.4.0-2.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-e13babe183

Comment 7 Fedora Update System 2018-05-01 07:42:49 UTC
grass-7.4.0-2.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.

Comment 8 Fedora Update System 2018-05-02 12:36:00 UTC
grass-7.4.0-2.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.