Click here to Skip to main content
15,885,278 members
Articles / Desktop Programming / Win32

Dynamic Libraries with Delayed Function Loading

Rate me:
Please Sign up or sign in to vote.
0.00/5 (No votes)
27 Oct 2011Public Domain4 min read 24.6K   306   5  
This article explains how to create a dynamic library that loads exported functions the first time they are used, opposed to loading them when the library is loaded.

Microsoft Visual Studio Solution File, Format Version 10.00
# Visual Studio 2008
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "client", "client\client.vcproj", "{F08017D2-45D4-4500-86F2-4D2E77391018}"
	ProjectSection(ProjectDependencies) = postProject
		{48E6650D-8C52-41B1-99C1-9C156184F240} = {48E6650D-8C52-41B1-99C1-9C156184F240}
		{33A3F321-76E5-41A3-BBF7-A179E2179B12} = {33A3F321-76E5-41A3-BBF7-A179E2179B12}
	EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "payload_dll", "payload_dll\payload_dll.vcproj", "{48E6650D-8C52-41B1-99C1-9C156184F240}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "proxy_generator", "proxy_generator\proxy_generator.vcproj", "{33A3F321-76E5-41A3-BBF7-A179E2179B12}"
	ProjectSection(ProjectDependencies) = postProject
		{48E6650D-8C52-41B1-99C1-9C156184F240} = {48E6650D-8C52-41B1-99C1-9C156184F240}
		{B7880462-BD2F-40C2-8F76-DE3008219C38} = {B7880462-BD2F-40C2-8F76-DE3008219C38}
	EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "proxy_dll", "proxy_dll\proxy_dll.vcproj", "{B7880462-BD2F-40C2-8F76-DE3008219C38}"
EndProject
Global
	GlobalSection(SolutionConfigurationPlatforms) = preSolution
		Debug|Win32 = Debug|Win32
		Release|Win32 = Release|Win32
	EndGlobalSection
	GlobalSection(ProjectConfigurationPlatforms) = postSolution
		{F08017D2-45D4-4500-86F2-4D2E77391018}.Debug|Win32.ActiveCfg = Debug|Win32
		{F08017D2-45D4-4500-86F2-4D2E77391018}.Debug|Win32.Build.0 = Debug|Win32
		{F08017D2-45D4-4500-86F2-4D2E77391018}.Release|Win32.ActiveCfg = Release|Win32
		{F08017D2-45D4-4500-86F2-4D2E77391018}.Release|Win32.Build.0 = Release|Win32
		{48E6650D-8C52-41B1-99C1-9C156184F240}.Debug|Win32.ActiveCfg = Debug|Win32
		{48E6650D-8C52-41B1-99C1-9C156184F240}.Debug|Win32.Build.0 = Debug|Win32
		{48E6650D-8C52-41B1-99C1-9C156184F240}.Release|Win32.ActiveCfg = Release|Win32
		{48E6650D-8C52-41B1-99C1-9C156184F240}.Release|Win32.Build.0 = Release|Win32
		{33A3F321-76E5-41A3-BBF7-A179E2179B12}.Debug|Win32.ActiveCfg = Debug|Win32
		{33A3F321-76E5-41A3-BBF7-A179E2179B12}.Debug|Win32.Build.0 = Debug|Win32
		{33A3F321-76E5-41A3-BBF7-A179E2179B12}.Release|Win32.ActiveCfg = Release|Win32
		{33A3F321-76E5-41A3-BBF7-A179E2179B12}.Release|Win32.Build.0 = Release|Win32
		{B7880462-BD2F-40C2-8F76-DE3008219C38}.Debug|Win32.ActiveCfg = Debug|Win32
		{B7880462-BD2F-40C2-8F76-DE3008219C38}.Debug|Win32.Build.0 = Debug|Win32
		{B7880462-BD2F-40C2-8F76-DE3008219C38}.Release|Win32.ActiveCfg = Release|Win32
		{B7880462-BD2F-40C2-8F76-DE3008219C38}.Release|Win32.Build.0 = Release|Win32
	EndGlobalSection
	GlobalSection(SolutionProperties) = preSolution
		HideSolutionNode = FALSE
	EndGlobalSection
EndGlobal

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under A Public Domain dedication


Written By
Founder
Germany Germany
Software developer since April 2000.
Active in various areas, most notably C/C++ development with Windows platform, web development, scripting.
Coder by heart.
Interested in higher level software development techniques, abstractions, modeling, software factories.
Nuts and bolts guy.

Comments and Discussions