Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug
Bug#: 53567
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Gentoo Developers for the x86 Architecture <x86@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Scott Smith <scott-gentoo@gelatinous.com>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 53567 depends on: Show dependency tree
Bug 53567 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2004-06-10 12:35 0000
libaio won't build on x86 because there is a patch that incorrectly applies the
'-fPIC' to the library.  Since the library has no global variables, it does not
need the -fPIC option (see
http://docs.freebsd.org/info/gcc/gcc.info.Code_Gen_Options.html)

Without that it works fine (I've been using it myself on my Pentium III without
a problem).  Since ebx (the PIC register) is callee saved, it's modification by
the library (in order to make the syscall) will automatically cause it to be
saved, thus you don't have to worry about it affecting the function that calls
the aio library. (compile with -S for yourself to verify)

Also the description should probably be changed to "Asynchronous I/O library
that uses the kernels native interface" since the library is not specific to
Oracle.

------- Comment #1 From Danny van Dyk (RETIRED) 2004-06-11 06:53:13 0000 -------
I solved the -fPIC problem but i won't and can't keyword it ~x86.
Reassigning to x86...

Scott: -fPIC is neede on several ARCHs, e.g all 64bit archs + hppa.

------- Comment #2 From Scott Smith 2004-06-11 09:43:50 0000 -------
I'm pretty sure -fPIC is not needed on any platform UNLESS you have global
variables for your shared library.  This library has no global variables, so
it's not needed.

stack variables are referenced via the stack pointer, and the only function
calls (which are relative anyways) are either syscalls or the callback in
io_queue_run (in which case the callback function is passed as a parameter).

I don't have a cross compiler installed, but I would venture that the register
is not used for anything in this library...

------- Comment #3 From Ian Leitch (RETIRED) 2004-06-11 17:32:27 0000 -------
Marked ~x86.

Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug