| 6 | |
| 7 | === Does MacPorts always build from source? === |
| 8 | |
| 9 | MacPorts 2.0.0, released in 2011, added the ability to securely install ports from prebuilt binary archives. With a default configuration; you don't need to do anything to take advantage of this, |
| 10 | MacPorts will automatically install from an archive if one is available. |
| 11 | |
| 12 | If no archive is available, MacPorts will fall back to building from source. This can happen for a number of reasons: |
| 13 | * Each port is only prebuilt with its default set of variants. So if you specify different variants when installing, the port will be built from source. |
| 14 | * Some software has a license that is incompatible with that of a dependency, making it impossible to legally distribute binaries. A common example is software licensed under the GPL that depends on OpenSSL without adding a special exception to allow linking with it. |
| 15 | * Archives are only prebuilt for a limited number of CPU architectures and OS versions. |
| 16 | * If you are using a custom value for any of the following macports.conf settings, the prebuilt archives are not compatible with your installation and will not be used: `prefix`, `applications_dir`, `frameworks_dir`, `cxx_stdlib`, `delete_la_files` |
| 17 | |
| 18 | These limitations could be avoided by using a custom archive site configured to suit your needs, rather than the official one, though of course someone still needs to build the archives. See [wiki:howto/ShareArchives2]. |