You're welcome. Be careful with that technique, though.
If somebody configures your project with CMAKE_INSTALL_PREFIX set to C:/Put/Stuff/Here, they'll end up with your main install tree underneath that, and then all your custom dir files in "C:/Put/Stuff/CustomDir". On Tue, May 22, 2012 at 3:31 PM, <[email protected]> wrote: > I got it to work. > > Under windows/NSIS I set the destination to "../CustomDir" instead of > $CustomDir. > With this and a custom nsis script which knows the location it is possible > to run CPack. > > In the NSIS script I've the following > Var $CustomDir="@CPACK_TEMPORARY_DIRECTORY@\..\CustomDir" > > After this I can install files from this directory too. > > The directory content after the preinstall: > .../_CPack_Packages/win32/NSIS/myproject.1.0.0.1/ > .../_CPack_Packages/win32/NSIS/CustomDir/ > .../_CPack_Packages/win32/NSIS/project.nsi > . > . > . > > @Eric, @David: Thank you very much > > Best Regards > > > Am 22.05.2012 um 00:38 schrieb Eric Noulard <[email protected]>: > > > 2012/5/21 David Cole <[email protected]>: > >> On Mon, May 21, 2012 at 2:05 PM, <[email protected]> wrote: > >>> > >>> But what about other systems like linux. If I have an executable and > >>> shared libraries for example. > >>> Then it is possible to install it under /opt/myproject, but it is not > >>> possible to install the executable under /usr/bin and the shared > libraries > >>> under /usr/lib? Or did I misunderstood something? > >> > >> > >> But you don't build an NSIS installer based on those. > > > > And installing lib in /usr/lib and exe in /usr/bin IS possible > > because the 2 path shares the /usr prefix. > > > > On Linux if you build an RPM or DEB package which contains various > > prefix (/usr /opt etc..) you either get a non relocatable package > > or decide that some files are "special" like config files. > > > > but David is right this does not work with NSIS. > > > >>> Sorry, for simple installers the default NSIS template is great, but > for > >>> customized ones it seems to be very difficult, isn't it? > > > > As difficult as it is with NSIS alone :-] > > > >> Yes, you're correct. It takes some effort if you are not installing > >> everything underneath the directory that the end user chooses for your > final > >> location. > >> > >> It's quite good for "simple installers" and "component-based > installers" -- > >> beyond that, and especially putting things outside the location chosen > by > >> the end user ... you're on your own. > > > > If you do have 2 separate unrelated installation prefixes > > may be you can just build 2 NSIS installers > > (which contains only one prefix) > > using CPack twice out of 2 differents configurations of the same project > > > > Or craft your own project.nsi file. > > > > -- > > Erk > > Le gouvernement représentatif n'est pas la démocratie -- > > http://www.le-message.org >
-- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
