Page 1 of 1

First time using an External

Posted: Sun May 22, 2016 5:23 pm
by RossG
I was surprised to find that I have to keep the external
directory with the .exe when moving it to another computer.

Have I missed a switch somewhere that will include the
external(s) with the .exe?

Re: First time using an External

Posted: Mon May 23, 2016 4:00 pm
by jacque
There's no way to include those. That's why they are called "externals" - - they need to be stored externally to the app.

Re: First time using an External

Posted: Mon May 23, 2016 11:58 pm
by RossG
I thought it might be possible to "include" them
as in days of old.

Thought that perhaps and "external" in the IDE
could become and "internal" in the .exe.

Update:

It's strange that the externals have the extension ".dll"
(Dynamic Link Library) yet can't be linked which is
as I recall done in other languages with a line of code:

#include something.dll

Perhaps a useful improvement to LC?

Re: First time using an External

Posted: Tue May 24, 2016 3:36 am
by jacque
I believe the LC engine is doing the linking for us.

Re: First time using an External

Posted: Tue May 24, 2016 4:11 am
by RossG
jacque wrote:I believe the LC engine is doing the linking for us.
Well, if it is it's a different thing to what I know as "linking" in which the
dll is included in the compiled programme and isn't "external" to it.

Re: First time using an External

Posted: Tue May 24, 2016 9:20 am
by Ledigimate
Hi Ross

Dll's are always external to the executables that link to them.
It may sometimes seem like the .dll is compiled "into" an executable when the .dll is in fact part of the Operating System, in which case there is no need for distributing the .dll along with your executable.
It should otherwise always be distributed along with the executable.

Edit: It is however possible to include a .dll as an embedded resource of the executable to make it easier to distribute, but the embedded .dll would have to be extracted from the executable and stored in a separate file before actually using it. It still remains an external in that it has to be extracted into a separate file before it can be used.

Re: First time using an External

Posted: Tue May 24, 2016 12:02 pm
by RossG
A .dll is an executable file without the .exe extension
so even if it needs the OS to run (same as the .exe) it
should be possible to combine them into one package
for convenience.

Just my opinion.

Re: First time using an External

Posted: Tue May 24, 2016 1:05 pm
by dave.kilroy
Hi Ross - I used to do a bit of .NET development and always had to package .dlls externally - if the app needed a private .dll for when it was installed on the target machine (as opposed to calling on commonly available .dlls provided by the OS) they would be included in the installer package and installed alongside the .exe. And with some private .dlls there was extra code and/or certification needed to make sure they were properly registered with the OS or they couldn't run. However the last time I did this kind of stuff was about six years ago so I might have mis-remembered!

Regards

Dave

PS: and with Windows virtualisations there sometimes could be two copies of .dlls floating round (all obviously external to the .exe)