gnu: make-libiberty: Build with -fPIC.

Since iberty is a static library, linking a PIC-enabled target to it
requires it to also have been built with PIC.  (The target is Dyninst
in this case.)

This `-fPIC' flag is appended to the default CFLAGS of `-O2 -g'.

* gnu/packages/gcc.scm (make-libiberty)[arguments]:
  Adjust make-flags to add -fPIC to CFLAGS.

Change-Id: I155045d05f4434cb68be933a95b7bc9fdec98818
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
This commit is contained in:
Nguyễn Gia Phong 2024-09-19 16:38:38 +09:00 committed by Ludovic Courtès
parent ad6deff8bb
commit fee669e2c2
No known key found for this signature in database
GPG Key ID: 090B11993D9AEBB5

View File

@ -1065,6 +1065,7 @@ using compilers other than GCC."
(name "libiberty") (name "libiberty")
(arguments (arguments
`(#:out-of-source? #t `(#:out-of-source? #t
#:make-flags '("CFLAGS=-O2 -g -fPIC")
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-before 'configure 'chdir (add-before 'configure 'chdir