How to interface with MySql 9.6?

realhet real_het at hotmail.com
Fri Feb 20 18:27:42 UTC 2026


On Friday, 20 February 2026 at 16:45:35 UTC, Adam D. Ruppe wrote:
> On Friday, 20 February 2026 at 16:21:58 UTC, realhet wrote:
>> Now I'm compiling only these arsd modules: mysql, jsvar, 
>> script, http2, uri, characterencodings, string, conv, 
>> database, dom, core, cgi
>> I believe this is the smallest set required for MySql.
>
> Do `dmd -i mysql.d` and let the compiler find the dependencies.
>
> But it requires only three: mysql.d, database.d, and core.d. It 
> compiles in under a second from scratch.

Can't use -i for the heavy lifting.
My buildsys has another addicting feature: It caches the object 
files for the unchanged modules.

So my workflow is something like this: On the start of a day I 
open a project with 100KLOC and 30 modules, on the first build it 
takes some time on my old AMD FX8350 8 core cpu, around 2-3 
minutes.
But after I have a budget: If I only modify less than 8 modules 
(recursively), then it is posibble to launch a separate LDC2 
compiler for each module, so normally I can see what I did in 
20-30 seconds (and that's release mode).
And I have the opportunity to modify my framework too, not just 
project code. Only when I modify my `core` module, that takes 
long but normally I can have acceptable build times.

Another bonus is that I immediatelly see the errors, so I can 
break all the build process any time, modify, then try again.

What would help this is would be that "import discovery feature" 
of the compiler: I could call it for each modules recursively.  
But I've checked that years ago and it seemed not too fast.  And 
I just love compile time code generation.  So this import 
detection feature would take a while.  This dumb discovery 
feature of my buildsys takes only below milliseconds, because the 
code is already in reach, cached, preprocessed.  But I have to 
make it more clever.

Another cool feature would be a build overwatch thing:
An automata that can act in every frame (at 60FPS): It can always 
check the current build requirements and solve it.  No strict 
start-end build process, just a service that caches and compiles 
the modules and when all is ready, it finally calls the linker 
and launches the exe and goes to sleep for a while.  With this, I 
could let myself edit and save files while a build is already in 
progress.  Now I need to abort it first, that unfortunatelly 
includes the unchanged modules as well.

Just a rough example: All that 13 modules take 6.5seconds.  Then 
I only put a space in the mysql module it becomes 2 seconds.


>But it requires only three: mysql.d, database.d, and core.d
I will try to restrict to these, but I think there are more 
needed: For example cgi module is used in that RowOperations 
template: fromRow, toRow, I think that's important, but will see.

```
ldc2 test_MySql_arsd.d -o- --deps=deps.txt -I c:\D\libs
```
That's 4 seconds here. And only after this I can launch the 8 
LDC2 instances... Way too much.

But I should make use of this on a separate thread in the 
background.  Anyways I gotta solve this, but not now. :D



More information about the Digitalmars-d-learn mailing list