FS#64577 - [qhull] not compiled with -fPIC

Attached to Project: Arch Linux
Opened by Tyler (ryan0270) - Tuesday, 19 November 2019, 22:03 GMT
Last edited by Antonio Rojas (arojas) - Saturday, 23 November 2019, 19:49 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Antonio Rojas (arojas)
Architecture x86_64
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
-fPIC flag is missing while building the libraries
This prevents other software to build with this library

NOTE: this same issue appeared in a previous bug report: https://bugs.archlinux.org/task/30010
After that report the PKGBUILD was updated with -fPIC but this 2019.1 commit removed it: https://git.archlinux.org/svntogit/packages.git/commit/trunk/PKGBUILD?h=packages/qhull&id=8e9850ad8332d316c7f705e392e1db6ccd6dea2c

Additional info:
* package version(s): qhull 2019.1-1

* config and/or log files etc.
build output:
/usr/bin/ld: /usr/lib/libqhullstatic.a(global.c.o): relocation R_X86_64_PC32 against symbol `qh_qh' can not be used when making a shared object; recompile with -fPIC

* link to upstream bug report, if any

This task depends upon

Closed by  Antonio Rojas (arojas)
Saturday, 23 November 2019, 19:49 GMT
Reason for closing:  Fixed
Additional comments about closing:  2019.1-2 builds libqhullcpp.a with -fPIC and drops other static libs as per Arch policy
Comment by Michel Koss (MichelKoss1) - Wednesday, 20 November 2019, 13:26 GMT
Arch automatically compiles all shared libs with PIC so I think only libqhullstatic*.a static lib has this issue. Fedora has patch which link executables against shared libs[1]. They also remove libqhullstatic*.a[2].

Some other things: "make VERBOSE=1" will show more compilation details in logs. You may also consider getting rid of RPATHs[3] (you can confirm they exist with checksec.

[1] https://src.fedoraproject.org/rpms/qhull/blob/master/f/0001-Link-executables-against-shared-libs.patch
[2] https://src.fedoraproject.org/rpms/qhull/blob/master/f/qhull.spec#_113
[3] https://src.fedoraproject.org/rpms/qhull/blob/master/f/qhull.spec#_77

Loading...