On Thu, 14 Nov 2013 16:59:02 +0100, Sönke Ludwig wrote:
Am 14.11.2013 16:52, schrieb Stephan Dilly:
On Thu, 14 Nov 2013 15:37:29 GMT, Sönke Ludwig wrote:
On Tue, 12 Nov 2013 15:21:16 +0100, Sönke Ludwig wrote:
Am 12.11.2013 14:36, schrieb Stephan Dilly:
so i created a dub package with a mysql-native and vibe.d dependancy. now i am used to work with visuald but i cannot link my project. i want to use the pooled connection stuff like in the sample. my application gets the "Havevibed" version so that it uses the code in mysql-native that uses vibe-d for pooling. but the mysql-native library in my solution does not get this version defined. that leads to the problem that even though my exe expects this part of the library mysql-native is build without that part and that way the linker poos itself:
Error 42: Symbol Undefined _D5mysql2db7MysqlDB7__ClassZ Error 42: Symbol Undefined _D5mysql2db7MysqlDB6__ctorMFAyaE5mysql10connection11SvrCapFlagsZC5mysql2db7MysqlDB (mysql.db.MysqlDB mysql.db.MysqlDB.__ctor(immutable(char)[], mysql.connection.SvrCapFlags))
i can fix that by either using
1)
dub generate visuald-combined
which is bad since it a) drives the compile times up too much and b) is bad project structure
2)
i can add the version "Havevibed" to the mysql-native lib by hand and also the import paths of vibe.d so that the correct "version" of the lib gets compiled. but i have to do this everytime i use "dub generate" which also sucksis there a better way to fix this ?
I'll fix that, it's definitely a bug.
When starting to look into a fix, I realized that this in fact is not a bug, but correct behavior, considering the dependency graph. Since "mysql-native" has no dependency to "vibe-d", it also doesn't have it available when it is compiled separately. To fix this, I've added an optional vibe-d dependency to mysql-native "~master".
This currently requires to use a version based vibe-d dependency (e.g. ">=0.7.17"), as DUB currently detects branch and version based dependencies as conflicting. Similar issue: #151
So far so good, but i won't get ~master of vibe.d that way, right ? so i am unable to work around this right now because i have to have vibe.d ~master because of other fixes :D
Since I already saw that coming, I've tagged a 0.7.18.beta.1 version ;)
works like a charm. thanks a lot!