Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Possibility of 'thread-safe' USE flag?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
trythil
Tux's lil' helper
Tux's lil' helper


Joined: 06 Jun 2002
Posts: 123
Location: RHIT, Terre Haute, IN, USA

PostPosted: Mon Jun 24, 2002 8:00 pm    Post subject: Possibility of 'thread-safe' USE flag? Reply with quote

Some packages (notably PHP and MySQL, but there are others) have thread-safety code that can be optionally compiled in. I'm wondering: is there the possibility of a 'thread-safe', 'thread', etc. USE flag in the future to accomodate situations like this? Since I work with and debug threaded code quite frequently, it'd be nice to ensure that packages that my code depends on can be configured to be thread-safe without me manually tweaking ebuild scripts ;)

Sorry if this has been suggested before; never found it in the forums, BugZilla, or the MySQL ebuild script.

Edit: Sorry, this doesn't apply to MySQL after all, as I just found out:

Code:

trythil@beleriand trythil $ cat mysql-thread.c
#include <stdio.h>
#include <mysql/mysql.h>

int main()
{
        my_init();
        printf("%d\n", mysql_thread_safe());
}
trythil@beleriand trythil $ gcc -lmysqlclient_r mysql-thread.c
trythil@beleriand trythil $ ./a.out
1
trythil@beleriand trythil $


I suppose I'm too used to MySQL 4.0.1, where libmysqlclient (minus the -r) is thread-safe. :) PHP, though, still reports thread safety as disabled.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum