Since I have been in contact with the Ubuntu system before, I am quite familiar with the command
sudo apt-get install XXX for a convenient installation software package. I have always felt that Mac is also a Linux system and there should be little difference between Ubuntu. However, today, when using the command
sudo apt-get install libxml2, the Mac system reported
-bash:apt-get:command not found. Later, I found out that the original apt-get is debian(Ubuntu) package manager, so I continued to query the solution.
Solution 1: Brew is used instead of Apt-GET
What is brew?
Homebrew is a software package management tool on Mac OSX that can be easily installed or uninstalled on the Mac.
How to install?
All you need to do to install is type the following command on the terminal (the Mac comes with Ruby and you don’t need to install it)
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
After installation, use
brew install libxml2. For more brew features, please use
brew --help to view its help documentation.
Solution 2: Fink
What is Fink?
The Fink project hopes to bring a variety of open source software on Unix to the Darwin and Mac OS X platforms. We modified Unix software to compile and run (” port “) on Mac OS X, and provided a convenient distribution system so that everyone could download and use it. Fink USES tools in Debian such as DPKG and Apt-get to provide powerful binary package management. (The above content is from Fink’s official website)
How to install?
1. Open the following link to find the installation method of the corresponding version of OSX
my system version is 10.10.3
can be in the upper left corner of the system apple -> About the local view system version
More/System/Library/CoreServices/SystemVersion plist output
& lt; key> ProductVersion< /key>
< string> 10.10.3 & lt; /string>
As mentioned in the link above, there are two ways to install version 10.10, one is to use a script provided by Fink for automatic installation, and the other is to download the zip for manual installation. I chose the first method, easy and quick 🙂
this address is a github address, I am not familiar with github, I have not found the way to download this file directly –So when I got to the link, I chose to copy the code and pasted it into a file called Install_Fink
chmod +x ./Install_Fink // Modify the file as an executable ./Install_Fink // Run the File
The script then checks to see if there are pre-installed xcode-select /Java/XQuartz programs in the system, without prompting for installation, and prompts you to continue by clicking any key or to exit by using Ctrl+ C and entering a password during the run. When the script downloads the Fink installation, it will be prompted with some configuration options. If it is not clear, Enter directly USES the default configuration or selects Y.
our prompt you to some basic installation is complete we lift upgrade has been completed, please run fink update – all take a look at what other have not upgraded, you may find this time after the input prompt can not find fink this command, if in the previous tip configuration Path when you don’t have refused to him, then only need to restart the terminal fink can use before ~ if you turned him down, and run which fink command what all can’t find the words, So you can run the Shell script
/sw/bin/pathsetup.sh to configure the Path 🙂
(2) download the installed package
this method I don’t have a try, the installation process and order is the same as the script, specific please refer to the above gives a version of the installation address, probably look at the main steps include install xcode – select – & gt; Decompression package — & GT; Run./the bootstrap – & gt; Set the Path – & gt; Download the description file and the patch
After the installation is complete in terminal input
sudo apt - get the install libxml2 </ code> surprise you will find that you can use ~ another Fink is not only a package manager, it also provides many other functions, so far I haven't to explore XD, another during installation to download command select features to install, I don't have to explore deeply ~ everything is waiting for you to read a text to dig too ~ if you have any questions about this article can give me a message, I will try my best to help solve ^. ^
- How to Solve apt get update problem: usr/lib/apt/methods/HTTPS could not be found_PUBKEY 7EA0A9C3F273FCD8
- ruby 2.1.1 rails 4.2.0 Install gemset mysql command line tool for mac osx
- FTP use get command 550 failed to open file, but use the put command to solve the problem
- Using apt get to delete software completely
- ERROR Docker Engine API on Mac Osx
- How to Use spatial in MAC
- Ubuntu add apt repository command not found solution
- How to use C # to get image format without system. Drawing. Common
- How does a Mac terminal exit the python command line
- Installation and use of graphviz under mac
- Mac: how to show hidden files under Apple Mac operating system
- [Solved] Docker Container Use APT error: Permission denied
- N: Ignoring file ’50unattended-upgrades.ucf-dist’ in directory ‘/etc/apt/apt.conf.d/’ as it has an i
- [Solved] Mac Terminal error: command not found: telnet
- Command not found: ADB appears on Mac
- Mac command not found solution
- mac Upgrade: httpd: apr_sockaddr_info_get() failed for bogon
- use cin.get () instead of system (“pause”) to avoid the flash of C + + programs
- Mac opens Terminal and reports an error -bash:: command not found
- How to delete software completely on MAC