Hi all, atm I have a nearly finished mysql.inc file that can be used with MySQL v4.0 v4.1 and v5.0. Loaded dynamically and static.
It uses several defines to set the right MySQL version and to turn the dynamically linking on or off. Nog my question is: what is the best way to use this? Create 6 different units in packages/base/mysql - for each combination one? (thus mysql40, mysql40dyn, mysql41, mysql41dyn, mysql50 and mysql51dyn?) And then remove the existing mysql4 unit? This one is useless anyway because someone tried to update to MySQL 4.1, which wasn't done completely so now it's useless with 4.0 and 4.1. (At least with sqldb, too bad I didn't discovered that, so that mysql-support in 2.0.2 is very bad) But then, what to do with the MySQL-connection for sqldb? In principle the only thing that has to be changes to use another MySQL-version is to change the used unit. So, always use the TMysqlConn-component, but changes the usage-clausule. But how can this be handled by Lazarus? With the SQLDB-package only one unit can be used. (Or else multiple types with the same name are defined) Let the users manually change the usage-line if they want to use a different MySQL-library-version? Or create a TMysqlConn40, TMysqlconn41 and TMyslqconn50 wich are effectively the same, only with another usage-line? (Using the ifdef's again?) Is the problem clear and does someone have any ideas on this? -- Met vriendelijke groeten, Joost van der Sluis CNOC Informatiesystemen en Netwerken http://www.cnoc.nl _______________________________________________ fpc-devel maillist - [email protected] http://lists.freepascal.org/mailman/listinfo/fpc-devel
