Commit 475171c947ef3bc38c28af8cface16c53f90ae36
Merge pull request #19 from mani-monaj/cmake-fixes
Set CMAKE_INSTALL_PREFIX only when not externally set
Showing
1 changed file
with
3 additions
and
1 deletions
CMakeLists.txt
| @@ -152,7 +152,9 @@ endif() | @@ -152,7 +152,9 @@ endif() | ||
| 152 | # Install (sudo make install) | 152 | # Install (sudo make install) |
| 153 | # --------------------------------------------------------- | 153 | # --------------------------------------------------------- |
| 154 | 154 | ||
| 155 | -set(CMAKE_INSTALL_PREFIX /usr/) | 155 | +if(NOT CMAKE_INSTALL_PREFIX) |
| 156 | + set(CMAKE_INSTALL_PREFIX /usr/) | ||
| 157 | +endif(NOT CMAKE_INSTALL_PREFIX) | ||
| 156 | 158 | ||
| 157 | # Check if it is a 64 bit system | 159 | # Check if it is a 64 bit system |
| 158 | if(CMAKE_SIZEOF_VOID_P EQUAL 8 AND NOT LIB_SUFFIX) | 160 | if(CMAKE_SIZEOF_VOID_P EQUAL 8 AND NOT LIB_SUFFIX) |