Delay load DLL dependencies on Windows #1687
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
While Allegro is flexible with options wrt what to include into the build, the packagers and end-user of the library, probably, would benefit the most from this on Windows platform. There is no lazy symbol binding by default on that platform and all DLLs must present for an app to launch. There is, however, an option to delay load an entire DLL until an imported function is used. This way, if using redistributable binary, there is no need to keep dependencies that are not used thus slightly saving on disk space, memory impact, and launch time.