Static compilation :
At compile time, the relevant module has been compiled into the httpd binary fileNo Morehttpd.confIn theLoadModuleto load, as long as the<ifmodule></ifmodule>configuration is available.
Dynamic compilation :
when compiling, use theenable-module=sharedorEnable-modules-shared=moduleto dynamically compile. The dynamic is obviously not compiled into the httpd inside, the boot time will not load this module, but give you amodule.sofile. You want to use it, just use the loadmodule syntax to load it in httpd.conf, this module works.
Feel static compilation is like eating out, everything is ready, ready to eat. Dynamic compilation is like eating at home and buying something to get it back. In general, eating out is not allowed, but as long as we say hello (at compile time so module compiled into Apache core).
Difference: Static efficiency is higher, dynamic is more flexible.
Apache static compilation and dynamic compilation differences