# How to select NSIS on a non standard location

**URL:** https://discourse.cmake.org/t/how-to-select-nsis-on-a-non-standard-location/2570
**Category:** Usage
**Created:** [January 18, 2021, 8:14pm UTC](https://discourse.cmake.org/t/how-to-select-nsis-on-a-non-standard-location/2570 "2021-01-18T20:14:47Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Mathieu\_Westphal](https://discourse.cmake.org/user_avatar/discourse.cmake.org/mathieu_westphal/32/133_2.png) [@Mathieu\_Westphal](https://discourse.cmake.org/u/Mathieu_Westphal)
#### Post date: [January 18, 2021, 8:14pm UTC](https://discourse.cmake.org/t/how-to-select-nsis-on-a-non-standard-location/2570/1 "2021-01-18T20:14:47Z")

</div>

I have a computer that need to run NSIS for packaging with cpack, however the NSIS installed version on the system is not complete and needs to be patched (by adding an include file) in order to support the needs of my project.

I cannot modify the installed version as I do not have admnistrative rights but can install NSIS on my userspace.

I cannot find a way to specific the NSIS installation to use when running cpack. Is it possible ?

---

<div class="post-metadata">

### Author: ![Mathieu\_Westphal](https://discourse.cmake.org/user_avatar/discourse.cmake.org/mathieu_westphal/32/133_2.png) [@Mathieu\_Westphal](https://discourse.cmake.org/u/Mathieu_Westphal)
#### Post date: [January 18, 2021, 8:19pm UTC](https://discourse.cmake.org/t/how-to-select-nsis-on-a-non-standard-location/2570/2 "2021-01-18T20:19:22Z")

</div>

It looks like adding the makensis.exe location to the path does the trick. It would be nice to have a -D option for it.

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.cmake.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.cmake.org/u/ben.boeckel)
#### Post date: [January 19, 2021, 7:50pm UTC](https://discourse.cmake.org/t/how-to-select-nsis-on-a-non-standard-location/2570/3 "2021-01-19T19:50:48Z")

</div>

It seems that `makensis` is searched for directly via `cmSystemTools::FindProgram`. Please open an issue to allow for a CPack-time variable to use before doing the `FindProgram` call.

---

<div class="post-metadata">

### Author: ![Mathieu\_Westphal](https://discourse.cmake.org/user_avatar/discourse.cmake.org/mathieu_westphal/32/133_2.png) [@Mathieu\_Westphal](https://discourse.cmake.org/u/Mathieu_Westphal)
#### Post date: [January 22, 2021, 9:12am UTC](https://discourse.cmake.org/t/how-to-select-nsis-on-a-non-standard-location/2570/4 "2021-01-22T09:12:50Z")

</div>

[https://gitlab.kitware.com/cmake/cmake/-/issues/21733](https://gitlab.kitware.com/cmake/cmake/-/issues/21733)
