问题
I want to install ZLIB in the Linux server. My server account is: /home/myname . I download and extract ZLIB on my account properly. Then, I enter to ZLIB1.2.6 folder and run the command:
./configure --prefix=/home/myname/zlib
But, it gives error:
-bash: ./configure: Permission denied
Can anybody help me why is this happening ?
回答1:
Ok, if you are using Debian, you should do:
su
to become root
apt-get update
to refresh the package lists, then
apt-cache search zlib
to check the relevant packages in the lists you have just updated, then
apt-get install <whatever_package_you_found_earlier>
I suggest using regular expression as search strings for apt-cache, since they are more accurate, as in
apt-cache search ^zlib
to return only package names starting with zlib
回答2:
sudo apt-get install libgcrypt11-dev zlib1g-dev
回答3:
As Ignacio wrote above, just install the package for your particular distribution unless there is a very, very specific reason why you need that particular version of zlib.
来源:https://stackoverflow.com/questions/9979870/installing-zlib-in-linux-server