← Back to team overview

maria-developers team mailing list archive

Re: Shared plugin library build question


On Wed, 2011-11-09 at 00:54 +0100, Vladislav Vaintroub wrote:

> If you stuck, a simple way to fix it  might be  to add -D_REENTRANT to cmake/os/HP-UX.cmake ,
> so everything is compiled with it.
> The line
> would do the trick.

I added 'ADD_DEFINITIONS(-pthread)' instead, the -pthread flag causes
the compiler to define _REENTRANT.  I don't see any cmake configure code
that tries to determine if -pthread is needed when compiling or linking
and I don't see its use in any of the other cmake files, I find this
surprising.  The Mariadb 5.3.2 configure script certainly has code to
see if -pthread (or -mt or -threads) should be used or not.

I am also not sure if this is all I need for linking since we want to
use -pthread to link in the libpthread library.  Do flags added with
ADD_DEFINITIONS get used on a link line or is there another rule I
should use in addition to ADD_DEFINITIONS?

I now die when compiling client/mysql.cc.  HIST_ENTRY does not seem to
be defined but HAVE_HIST_ENTRY is.  This might be another include file
issue, I am not sure yet.

Steve Ellcey

Follow ups