• Advertisement

Archived

This topic is now archived and is closed to further replies.

newbie with dlls

This topic is 5156 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I know this isn't an opengl question but is there a way to include a dll into a compilation so the dll does not need to be supplied with the executable? Should perhaps mention Im in windows XP using visual c++ .net. [edited by - trager on January 12, 2004 8:02:53 AM]

Share this post


Link to post
Share on other sites
Advertisement
If by that, you mean "I want to use functions from this library, but I don''t want to include the .dll file with the .exe", then I don''t think there''s a way to do that. What you need is statically linked functions from a standard .lib file so the code is actually linked as part of the .exe. Standard dll files don''t do that.

You could create a new project and compile it to a .lib file, write the header, then just link it. I''ve never done that specifically (I''m rather fond of dlls ) but I don''t imagine it''s too hard. Do realize that it''ll make the .exe larger, but I suppose that''s what you want -- a complete package without extra files.

Did that help?

Share this post


Link to post
Share on other sites
I''m not even sure including the .dlls in the exe will help I want to reduce the overage size of the package.

At the moment the exe is 70k but is accompanied with 700k of .dll and I bet I''m only using 10% of the functions in the dll files.

So just curious if there is any sure fire way of doing this

Share this post


Link to post
Share on other sites
Well, if this .dll is something you made, you could compile a smaller .dll with less functions? Also, if you did indeed compile the .dll yourself, make sure it''s not in debug mode, that adds a ton of extra file size.

If it''s some .dll you got from somewhere else, I''m not sure what to say. It may be possible to extract function object info or something, but I wouldn''t really know how to do that without hacking apart the PE format.

Share this post


Link to post
Share on other sites

  • Advertisement