Old 26th August 2016, 08:32   #1
Junior Member
Join Date: Aug 2016
Posts: 2
Substitute $COMMONFILES64 with relative path

Hi guys

First Im a real noob, I just create my own very simple launchers to make the (few) apps I use portable.
I usually copy the files needed by the launched app to the locations it expects to find them, like to %appdata etc
But when the file to be copied is big, it would be a much better option not to copy the file, but just pretending its there.

For instance I have an app that expect a big 60mb .dll file to be in $COMMONFILES64
Is there any command, to tell the .exe to look for its dll somewhere else at runtime ?
Smething like :
set path $COMMONFILES64 = $EXEDIR\Data\Commonfiles64 or something ?

Or even better, to ADD (not substitute) a path, relative to the laucnhed exe, in case changing the commonfiles location could interfere with another app, running at the time, and which would also access this folder ?

geoslake is offline   Reply With Quote
Old 26th August 2016, 10:15   #2
Anders's Avatar
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,339
It really depends on how the app finds and loads the .dll.

You could try cmd.exe first: set path=%path%;x:\data\dlls and then start the app. If that does not work then you probably have to modify the app itself in ways that are not possible with NSIS...

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Old 26th August 2016, 12:40   #3
Junior Member
Join Date: Aug 2016
Posts: 2
I tried and it doesnt work
Thanks for your help, cheers.
geoslake is offline   Reply With Quote
Old 24th September 2016, 14:27   #4
Major Dude
Join Date: May 2003
Posts: 681
no relativ possible - pls read:

Greets, Brummelchen
Brummelchen is offline   Reply With Quote
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump