In response to my topic in here, I've made a MIT-licensed app named winMyLib whose job is to "install" libmysql.dll and write a registry value of where this libmysql.dll located. winMyLib is also capable of detecting all potentially "would-be-loaded" libmysql.dll by iterating through PATH environment variable and determine whether there are libmysql.dll located there and what version it is. The main point of this app is, it able to "choose" which libmysql.dll path to write into the registry so the winMyLib-compliant apps can just simply read this registry value to determine where to find libmysql.dll.
The question is, how to tell ZConnection where to find the libmysql.dll to be used? I know I can use some dirty tricks by reading the registry value of winMyLib and just copy the pointed libmysql.dll to my exe directory (that way I dont distribute the libmysql.dll with my exe), but I mean, if can do it cleanly, why should I dirty my hands?
Manually locate libmysql.dll?
Moderators: gto, EgonHugeist
- mdaems
- Zeos Project Manager
- Posts: 2766
- Joined: 20.09.2005, 15:28
- Location: Brussels, Belgium
- Contact:
Hi,
There's no way to do it using the regular Zeoslib distributions.
But:
- We are looking for somebody to implement a new component that could be linked to a ZConnection and allowing to specify a dll and protocol to be used with that connection. This would allow zeoslib to combine different protocol versions and dll versions at the same time.
- tohenk made a patch in the past allowing you to specify the dll as part of your connection properties. See http://zeos.firmos.at/viewtopic.php?t=819 .
It will not work right out of the box anymore, but will certainly point you the way to follow.
Mark
There's no way to do it using the regular Zeoslib distributions.
But:
- We are looking for somebody to implement a new component that could be linked to a ZConnection and allowing to specify a dll and protocol to be used with that connection. This would allow zeoslib to combine different protocol versions and dll versions at the same time.
- tohenk made a patch in the past allowing you to specify the dll as part of your connection properties. See http://zeos.firmos.at/viewtopic.php?t=819 .
It will not work right out of the box anymore, but will certainly point you the way to follow.
Mark
It's really been a while since the last post of mine regarding this topic
Just for information (perhaps someone has the same problem for me as I was two months ago ), in the source of winMyLib I also put an additional driver and a lil modification to ZDbcMySql.pas and ZPlainMySqlDriver.pas to recognize the new driver which is winMyLib compliant.
winMyLib can be downloaded from this URL:
http://info.c-rex.co.cc/index.php?sub=p ... ew&lang=en
(the web just went up recently and a few weeks ago I have projects to finish, so don't ask why I made it public only recently )
Just for information (perhaps someone has the same problem for me as I was two months ago ), in the source of winMyLib I also put an additional driver and a lil modification to ZDbcMySql.pas and ZPlainMySqlDriver.pas to recognize the new driver which is winMyLib compliant.
winMyLib can be downloaded from this URL:
http://info.c-rex.co.cc/index.php?sub=p ... ew&lang=en
(the web just went up recently and a few weeks ago I have projects to finish, so don't ask why I made it public only recently )