|Version 5 (modified by 17 years ago) ( diff ),|
Notes on compiling MySQL on HLFS
The configure script will fail to locate Linuxthreads when compiling on HLFS based system, as HLFS is pure NTPL.
Bug is described here: http://bugs.mysql.com/bug.php?id=19785
Suggested fix from the developers of MySQL:
1) Insert a misleading comment into the header file defining thread functions:
echo '/* Linuxthreads */' >> /usr/include/pthread.h
(The check just goes by searching that string.)
2) Explicitly give a threads library:
./configure --with-pthread --with-named-thread-lib=-lpthread ...
(This takes precedence over the checks.)
Option 2 would be preferred, but didn't work for me.
Option 1 solved the problem, and MySQL compiled happily.
The third fix is the attached patch based on the patch by Kevin P. Fleming found in the LFS archives.