diff mbox series

[bug#73989,1/2] gnu: plib: Build with -fPIC.

Message ID 08aef5dc3850e87fff8bc084facca2fee9b7b04b.1729785827.git.maxim.cournoyer@gmail.com
State New
Headers show
Series Add TORCS. | expand

Commit Message

Maxim Cournoyer Oct. 24, 2024, 4:04 p.m. UTC
* gnu/packages/game-development.scm (plib) [configure-flags]: New argument.
[inputs]: Move field after...
[native-inputs]: ... this one.

Change-Id: Ieddfb8814632f74c98d0e2cda949709b718c7a0d
---
 gnu/packages/game-development.scm | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)


base-commit: e4e1e16bc1b27684b55e6bf047f9f669e1a0c7b5
diff mbox series

Patch

diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm
index ee869c9cc5..7d2d47ce7b 100644
--- a/gnu/packages/game-development.scm
+++ b/gnu/packages/game-development.scm
@@ -2572,10 +2572,12 @@  (define-public plib
               (patches (search-patches "plib-CVE-2011-4620.patch"
                                        "plib-CVE-2012-4552.patch"))))
     (build-system gnu-build-system)
-    (inputs
-     (list mesa libxi libxmu))
-    (native-inputs
-     (list pkg-config))
+    ;; plib exists only as a static library, per the author's choice (see:
+    ;; https://sourceforge.net/p/plib/mailman/message/10289018/).  Build it
+    ;; with PIC, so that shared programs can at least "link" to it.
+    (arguments (list #:configure-flags #~(list "CXXFLAGS=-fPIC")))
+    (native-inputs (list autoconf automake pkg-config))
+    (inputs (list mesa libxi libxmu))
     (home-page "https://plib.sourceforge.net/")
     (synopsis "Suite of portable game libraries")
     (description "PLIB is a set of libraries that will permit programmers to