Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 364873 - sys-apps/kexec-tools won't load a kernel image when built with -fPIC
Summary: sys-apps/kexec-tools won't load a kernel image when built with -fPIC
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Gentoo Kernel Miscellaneous
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-25 23:15 UTC by Otamay
Modified: 2011-09-11 23:40 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Dirty patch for sys-apps/kexec-tools-2.0.2-r1.ebuild (kexec-tools-fix-fpic-cflag.diff,410 bytes, patch)
2011-04-25 23:18 UTC, Otamay
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Otamay 2011-04-25 23:15:16 UTC
Similar to Bug 183062 , kexec built with CFLAGS="-fPIC" fails to load any kernel image, resulting in "Unhandled rela relocation: R_X86_64_PLT32".

Filtering the -fPIC flag allows kexec to successfully load any kernel capable of.


Reproducible: Always

Steps to Reproduce:
1. Build sys-apps/kexec-tools-2.0.2-r1 with CFLAGS="-fPIC"
2. Load a kernel with kexec -l /boot/vmlinuz
3. Chech the resulting error.
Actual Results:  
Unhandled rela relocation: R_X86_64_PLT32

Expected Results:  
No error, kernel loaded and ready to a reboot.

Gentoo GNU/Linux on an AMD64 processor.
Comment 1 Otamay 2011-04-25 23:18:05 UTC
Created attachment 271175 [details, diff]
Dirty patch for sys-apps/kexec-tools-2.0.2-r1.ebuild

Proposed dirty patch for sys-apps/kexec-tools-2.0.2-r1.ebuild, to filter the -fPIC cflag allowing a built kexec capable to load kernels capable of.
Comment 2 Diego Elio Pettenò (RETIRED) gentoo-dev 2011-09-11 23:40:30 UTC
Do not add -fPIC to your flags unconditionally, such a situation is not supported.