Question

While installing libsigsegv for clisp, I have run into an error. "make install" does not finish correctly. The problem as I can see it is a permission issue. I am very new to Unix and cant figure out how to solve this issue. Can you help me please to solve this issue? Any suggestions highly appreciated.

me@me-VPCSB11FX:~/school/summer/libsigsegv/libsigsegv$ make install
Making install in src
make[1]: Entering directory `/home/me/school/summer/libsigsegv/libsigsegv/src'
make[2]: Entering directory `/home/me/school/summer/libsigsegv/libsigsegv/src'
test -z "/usr/local/lib" || /bin/mkdir -p "/usr/local/lib"
/bin/bash ../libtool --mode=install /usr/bin/install -c  'libsigsegv.la'   '/usr/local/lib/libsigsegv.la'
/usr/bin/install -c .libs/libsigsegv.lai /usr/local/lib/libsigsegv.la
/usr/bin/install: cannot create regular file '/usr/local/lib/libsigsegv.la': Permission denied
make[2]: *** [install-libLTLIBRARIES] Error 1
make[2]: Leaving directory `/home/me/school/summer/libsigsegv/libsigsegv/src'
make[1]: *** [install-am] Error 2
make[1]: Leaving directory `/home/me/school/summer/libsigsegv/libsigsegv/src'
make: *** [install-recursive] Error 1
Was it helpful?

Solution

The installation step is trying to write to a shared directory /usr/local/lib, which is read-only for end users and writable only for administrators and such.

You would need to give yourself additional privilleges by using su or sudo -- see e.g. here.

Also please note that installing custom stuff this way of make install is not very nice nowadays. You should be using some package management system like RPM or Aptitude or whatever, depending on your Unix distribution. It handles uninstallation, dependencies, conflicts, updates and everything else automatically.

OTHER TIPS

The detailed installation instructions are found in the INSTALL or INSTALL.generic file, for every GNU package. For GNU libiconv it is this file: http://git.savannah.gnu.org/gitweb/?p=libsigsegv.git;a=blob;f=INSTALL

The default installation location, /usr/local, is not writable by an ordinary user. You have three options:

  • Use sudo make install instead of make install.
  • Make the /usr/local directory and its subdirectory owned by yourself, instead of owned by root: chown -R $(id -u -n) /usr/local
  • Specify a different installation directory (see section "Installation Names" of said INSTALL file): For example: ./configure --prefix=${HOME}/gnu/arch/$(uname -p)
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top