1

I am working on an Fedora-34 ssh server and I don't have root access. So I was trying to compile and install the following tool:

% git clone https://github.com/google/sentencepiece.git 
% cd sentencepiece
% mkdir build
% cd build
% cmake ..
% make -j $(nproc)
% sudo make install
% sudo ldconfig -v

For the last two lines I couldn't use sudo. So what I did is that I created a bin folder in my $HOME, and again run the following:

% git clone https://github.com/google/sentencepiece.git 
% cd sentencepiece
% mkdir build
% cd build
% cmake .. -DCMAKE_INSTALL_PREFIX:PATH=$HOME/bin/
% make -j $(nproc)
% make install
% ldconfig -v

However, when I run the last command I get the below error:

ldconfig: Can't create temporary cache file /etc/ld.so.cache~: Permission denied
M.A.G
  • 261

1 Answers1

3

ldconfig is a command which updates the system-wide cache of libraries, it can be run only by root/sudo. Doesn't your application work without it? If it doesn't please use where is LD_LIBRARY_PATH? how do I set the LD_LIBRARY_PATH env variable?