PDA

View Full Version : Setting [EXENAME] at compile time



NewsArchive
07-27-2005, 10:25 AM
Friedrich,

Can a compiler variable be initialized by anything other than a static
string? A #const, perhaps?

Specifically, I have a need to build two installs with different behaviors.
The behaviors were easily implemented using the preprocessor to compile code
variations. As a defense against my own stupidity, I want [EXENAME] to differ
based on the variant being built.

I've got usable behavior by using #copyfile and #deletefile post-compile, but
setting [EXENAME] at compile time would be a bit cleaner.

--
Best regards,

Mark

-------------------------------------------------------------------
Why waste time learning when ignorance is instantaneous?
We do email right!
Rock solid hosting services at http://www.lanbytes.net

NewsArchive
07-27-2005, 10:26 AM
Mark,

I'll check this.

Friedrich

--
Friedrich Linder
CEO, Lindersoft
www.lindersoft.com
1.954.252.3910

"point. click. ship" - that's SetupBuilder 5

NewsArchive
07-27-2005, 10:26 AM
Update: I think we can add a "#set compiler var" compiler directive to
handle this. But I don't know if this function can make it into the final
5.00 (SB5 is already code complete).

Thanks,
Friedrich

--
Friedrich Linder
CEO, Lindersoft
www.lindersoft.com
1.954.252.3910

"point. click. ship" - that's SetupBuilder 5

NewsArchive
07-27-2005, 10:26 AM
Update 2: Added to Developer Edition.

Thanks for your suggestion.

Friedrich

--
Friedrich Linder
CEO, Lindersoft
www.lindersoft.com
1.954.252.3910

"point. click. ship" - that's SetupBuilder 5

NewsArchive
07-27-2005, 10:26 AM
>Update 2: Added to Developer Edition.
>
>Thanks for your suggestion.

Friedrich,

Awesome! Thanks very much.

Let me run a similar issue by you to see what you think. The behavior mods
I'm working on have to do with creating some unique bits for resellers. What
I'm into now is minor program mods for the same purpose.

When this gets to SB I'll have a set of unique DLLs for each reseller. This
is all for the same core product, and ideally will use the same install
script.

It would be very useful if Install File Source Path could use a compile time
variable. As it stands now I'm creating unique directories for each reseller
and renaming the current build target to the one used in the SB script. I
don't mind the work of juggling that stuff around, but I know it won't be
long before I start mixing things up.

--
Best regards,

Mark

-------------------------------------------------------------------
Why waste time learning when ignorance is instantaneous?
We do email right!
Rock solid hosting services at http://www.lanbytes.net

NewsArchive
07-27-2005, 10:26 AM
Mark,

You can already do this in SB5. For example, I have one compiler variable
[SB5_PROJECT]. This variable points to the latest SB5 source code folder
(e.g. c:\sb5\build1206). My file source path specification is, say,
[SB5_PROJECT]\sbuilder.exe.

I only have to change one compiler variable to change the source path for
all my files.

BTW, you can use the Project | Convert File Source Paths feature to rename
all your fixed hard coded source paths to a compiler variable.

Does this help?

Friedrich

--
Friedrich Linder
CEO, Lindersoft
www.lindersoft.com
1.954.252.3910

"point. click. ship" - that's SetupBuilder 5

NewsArchive
07-27-2005, 10:26 AM
>Mark,
>
>You can already do this in SB5. For example, I have one compiler variable
>[SB5 PROJECT]. This variable points to the latest SB5 source code folder
>(e.g. c:\sb5\build1206). My file source path specification is, say,
>[SB5 PROJECT]\sbuilder.exe.

I thought about trying that in the script items, but was concerned about the
possibility of breaking the GUI file management. I'll give that a go.

>Does this help?

As always. :}

--
Best regards,

Mark

-------------------------------------------------------------------
Why waste time learning when ignorance is instantaneous?
We do email right!
Rock solid hosting services at http://www.lanbytes.net