Page 1 of 1

Any way to avoid installation into /usr/local?

Posted: Fri Dec 25, 2015 11:02 am
by lembark
Which doesn't exist on this system, linux uses "/opt".

Looking through the Installation guide it seemed to indicate that the prefix could be set:
Configuration can be done in 4 ways:
1) As a command line parameter, e.g. cmake -DCMAKE_VERBOSE_MAKEFILE=ON .

CMAKE_INSTALL_PREFIX - Use this to change the prefix (default /usr/local). This option behaves like --prefix from autoconf. Package maintainers will probably want to set this to "/usr".
Which seem to indicate that using:

Code: Select all

cmake -DCMAKE_INSTALL_PREFIX=/opt/ZoneMinder
Would attempt to make the install into /opt/ZoneMinder.
Catch: make keeps blowing up after not being able to access /usr/local, which makes sense since I need this installed into /opt/ZoneMinder.

Q: Is there any way to have CMAKE actually use the install prefix?

Re: Any way to avoid installation into /usr/local?

Posted: Fri Dec 25, 2015 7:56 pm
by mikb
Not sure on the the CMAKE thing, but Linux uses /opt, or /usr/local (depending on your distribution) -- or both. It's up to you though, the whole point of being in control of your own OS is that *you* can make these choices -- I've got most user-added stuff in /usr/local, but OpenOffice went into /opt. Whatever ... both work!

You could always make a symbolic link from /usr/local/wherever-it-ends-up to /opt/ZoneMinder, if you can't beat it into submission :)

Re: Any way to avoid installation into /usr/local?

Posted: Sat Dec 26, 2015 3:09 pm
by knight-of-ni
You are missing the period "." at the end of your cmake command. It is required and the build will certainly not go as expected if it is missing.

Re: Any way to avoid installation into /usr/local?

Posted: Sat Dec 26, 2015 7:10 pm
by mikb
"For the want of a dot, the compilation was lost" :)