Menu

#6 MainSource predefined variable

open
nobody
None
5
2006-01-13
2006-01-13
No

I suggest to implement new predefined variable (like
__FILE__, eg. named __MAIN__) which remember full
path of file with *main* script. With such variable
it will be possible to easy implementat "plugins".

I have many programs installed in the same manner. In
main ISS script for each program I have series of
#define's. At the end of each script I have #include
to common part of script for all installers. In the
common file I need to implement "plugins".

For example:

Main script:
#define ...
#define ...
#include "Common.iss"

Common.iss:
... common code
[Code]
... common pascal code
procedure CurStepChanged(CurStep: TSetupStep);
begin
... common part of event
#if FileExists(__MAIN__ + "_CurStepChanged.iss")
#include __MAIN__ + "_CurStepChanged.iss"
#endif
end;
...

Discussion


Log in to post a comment.