[Mono-list] Pooling=false in connectionString cause Unhandled Exception: System.EntryPointNotFoundException: CreateSemaphore

Joshua Tauberer jit at occams.info
Sun Aug 26 16:24:54 EDT 2007


Robert Jordan wrote:
> enzo wrote:
>> Using a simpe program ( the code is reported at the botom ) which simply 
>> connect to a mysql database a perform a simple select works well if the 
>> option Pooling in the connectionString is false
>> If i set it to true ( as string connectionString = 
>> "Server=localhost;Database=test;User 
>> ID=test;Password=test;Pooling=true"; ) I got an unhandled exception like 
>> this
>>
>> $ mono test1-mysql.exe
>>
>> Unhandled Exception: System.EntryPointNotFoundException: CreateSemaphore
>>   at (wrapper managed-to-native) 
>> MySql.Data.Common.Semaphore:CreateSemaphore 
> 
> It seems that you're using the Windows version of the mysql
> client. Pity, in the past the versions were compatible.
> 
> Try to get a version compiled for Mono.

I can't remember why anymore, but I had to compile the MySQL Connector 
myself when I wanted to use it. (I might have been debugging something, 
or maybe it was that the binaries didn't work on Mono.)

If it's helpful for anyone, with 5.0.6, I used:

gmcs -debug -out:bin/jt/MySql.Data.dll -t:library \
     Properties/*.cs Source/*.cs Source/common/*.cs Source/Types/*.cs 
Source/zlib/* \
     -r:System.Data -r:System.Transactions -r:System.Drawing \
     -d:NET20 \
 
-resource:Source/Resources.resources,MySql.Data.MySqlClient.Source.Resources.resources

from the Driver directory of the package.

-- 
- Josh Tauberer

http://razor.occams.info

"Yields falsehood when preceded by its quotation!  Yields
falsehood when preceded by its quotation!" Achilles to
Tortoise (in "Gödel, Escher, Bach" by Douglas Hofstadter)


More information about the Mono-list mailing list