Notes |
|
(0019972)
|
edice
|
2010-03-21 05:58
|
|
I consider this a bug.
I did the following:
install (TARGETS my_program DESTINATION .)
And it will correctly install the executable to c:\Program Files\MyProject\my_program.exe
However, I cannot make CPack-NSIS create StartMenu shortcuts that point to that executable. It INSISTS on pointing to bin\my_program.exe which is annoying.
It would be good if this problem were resolved.
Thanks,
Paul
ps in the meantime, it seems I am forced to install to a bin directory. |
|
|
(0024520)
|
David Cole
|
2011-01-07 17:23
(edited on: 2011-01-07 17:28) |
|
As of this commit:
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=702c8f8ba79591744449244ed47a5181fdf68a63 [^]
you can set CPACK_NSIS_EXECUTABLES_DIRECTORY to anything you want -- it defaults to "bin" for backwards compatibility, but you should be able to set it to "." for the root of the install or to "some\\other\\path\\in\\your\\install\\tree" if you would like.
This value is automatically pre-pended to the strings that you set in CPACK_PACKAGE_EXECUTABLES.
You could set this to "." and then specifying CPACK_PACKAGE_EXECUTABLES something like this:
set(CPACK_NSIS_EXECUTABLES_DIRECTORY ".")
set(CPACK_PACKAGE_EXECUTABLES
"bin\\exe1" "The First Exe"
"other\\exe2" "The Second Exe"
"exe3" "Top Dog Top Directory Exe"
)
Alternatively, after this commit:
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=1bbe4e69171f3155f262bb12f15437db4b71c207 [^]
CPACK_NSIS_MENU_LINKS may now be used directly to refer to any files, separately from CPACK_PACKAGE_EXECUTABLES, not just *.exe files under CPACK_NSIS_EXECUTABLES_DIRECTORY... So you could just as easily now *not* set the new dir variable, but rather simply do:
set(CPACK_NSIS_MENU_LINKS
"bin\\exe1.exe" "The First Exe"
"other\\exe2.exe" "The Second Exe"
"exe3.exe" "Top Dog Top Directory Exe"
)
Either way you slice it, I think both of these ways should work and be able to qualify as fixing the reported symptoms in this issue... I am going to resolve this as fixed. Feel free to re-open it if you disagree, or feel there is a need for further discussion.
Thanks!
|
|
|
(0024521)
|
David Cole
|
2011-01-07 17:39
|
|
Fixed by the same commits that fix the related issues 0007828 and 0010644 |
|
|
(0026325)
|
David Cole
|
2011-05-02 14:45
|
|
Closing resolved issues that have not been updated in more than 3 months. |
|