Bureaucrats, cc_docs_admin, cc_staff
2,879
edits
(partial first draft) |
(→configure; make; make install: clarify sudo, replace HOME with PROJECT) |
||
Line 15: | Line 15: | ||
is a very common instruction pattern. Variations include <code>cmake .</code> replacing <code>./configure</code>, and <code>sudo make install</code> replacing <code>make install</code>. | is a very common instruction pattern. Variations include <code>cmake .</code> replacing <code>./configure</code>, and <code>sudo make install</code> replacing <code>make install</code>. | ||
Sometimes this will work exactly as prescribed, but sometimes it will fail at <code> | Sometimes this will work exactly as prescribed, but sometimes it will fail at <code>make install</code> because the package expects to be able to write to <code>/usr/local</code> or some other shared area in the file system. It will always fail if <code>sudo make install</code> is attempted, because <code>sudo</code> is a request for "root" or administrator privileges. The usual solution is to supply a <code>--prefix</code> flag at the <code>configure</code> step, to direct the installation to go to the directory of your choice, ''e.g.:'' | ||
{{Command|./configure --prefix{{=}}$ | {{Command|./configure --prefix{{=}}$PROJECT/some-package && make && make install}} | ||
If other errors arise, contact [mailto:support@computecanada.ca support]. For more information see [[Make]], [[Autotools]], and [[CMake]]. | If other errors arise, contact [mailto:support@computecanada.ca support]. For more information see [[Make]], [[Autotools]], and [[CMake]]. |