MacPorts 1.8.0 released

The MacPorts project is an open-source community initiative to design an easy-to-use system for compiling, installing, and upgrading either command-line, X11 or Aqua based open-source software on the Mac OS X operating system.

MacPorts 1.8.0 brings a long list of news:

  • There is now a ‘build_arch’ variable, available in portfiles and configurable in macports.conf, which sets the CPU architecture that ports should be compiled for (when not building universal). Its default is the same as that of the Apple-supplied /usr/bin/gcc.
  • MacPorts base now works on and has appropriate default settings for Mac OS X 10.6 Snow Leopard.
  • MacPorts now requires Mac OS X 10.4 Tiger or later. (Panther is not just “unsupported”, it really won’t work.)
  • The universal_sysroot and universal_target keys have been removed from macports.conf. These settings are now handled automatically.
  • Added a ‘replaced_by’ portfile option. This causes upgrade to deactivate the current port and install the port specified by this option. This also allows ports to be renamed. Upgrade accepts a –no-replace option which disables this behaviour.
  • The upgrade action now accepts –force and –enforce-variants options. The former causes ports to be rebuilt even if they are not outdated, and the global -f option no longer has this effect (it had too many effects already). The latter causes ports to be rebuilt if the requested variants do not match those installed (even if they are not outdated).
  • Dependencies can be satisfied by ports that are installed but not available in the ports tree (useful for testing uncommitted ports).
  • Ports that are installed but not available in the ports tree no longer cause an error when running commands like ‘port clean installed’. They are skipped and a warning is printed.
  • Selfupdate no longer disables readline support unless readline is found in /usr/local, which has historically caused failures.
  • Uninstalling a port that is not installed now produces an informational message rather than an error.
  • Added a ‘conflicts’ portfile option. Conflicting ports will be detected during dependency calculation.
  • ‘port selfupdate’ now explicitly states precisely what it does.
  • Operating system and architecture information is now shown in debug output.
  • Fixed a bug that could break some symlinks to man pages.
  • Switched to a more efficient algorithm for looking up port information in the index, which makes many operations faster.
  • MacPorts base now tries to avoid using commands that come from ports, so that a broken port can’t break the base code.
  • Deleting all the contents of a portfile option no longer unsets the option entirely.
  • Removed the code that upgrades from the old DarwinPorts filesystem layout. Trying to upgrade to 1.8.0+ from a version older than 1.5.0 will produce an error message saying you need to install 1.7.1 first.
  • port(1) now reports its version as dotted-decimal rather than floating point.
  • Dependencies are now always obtained by parsing the Portfile and not from the PortIndex, since the latter can’t provide expanded variables like $prefix which may be used in path: depspecs.
  • Newline characters in long_description can no longer cause receipt corruption.
  • Now unlocking the filemap when it is not in use. This allows e.g. ‘port contents’ to be run while another port instance is performing installs. Note that running more than one simultaneous port instance that will modify the registry can easily fail, though hopefully without corrupting anything.
  • Removed some irrelevant debug output that was being printed when a port failed.
  • Added new depends_fetch and depends_extract options, for dependencies that are needed to fetch or extract the port, respectively.
  • Packages (including the one for MacPorts base) now correctly indicate that they can only be installed on the root volume.
  • Using an alternative fetch or extract type now adds appropriate dependencies automatically, e.g. ‘use_zip yes’ adds a dep on unzip, and ‘fetch.type svn’ adds a dep on subversion.
  • port(1) should now exit with an appropriate status code when an error is encountered. Use the -p option to continue despite errors.
  • Proxy information can now be obtained from System Preferences and from macports.conf. The older method using environment variables no longer works out of the box on Leopard due to changes that Apple made to the default /etc/sudoers.
  • Improved handling of malformed variant definitions.
  • Cope a little better with missing receipt files.
  • Fixed a major memory leak in the filemap code.
  • Improved the logic for determining whether phases can be skipped. This fixes the specific problems of being unable to build packages of ports that are installed, port not running specific phases (e.g. build) when told to if the port is installed, and inactive dependencies being rebuilt instead of simply activated.
  • When archive mode is enabled, ports will no longer be rebuilt if an archive is available.
  • Activating a port will now first deactivate any other version of the same port that is already active.
  • Added a ‘license’ portfile option, which is displayed in ‘port info’ output.
  • port lint recognizes new top-level category php.
  • Do not print header lines when the quiet option -q is set.
  • svn.tag is deprecated, use svn.revision instead.
  • port -i option has been removed.
  • ui_warn logs to stderr instead of stdout.
  • Remove –pretend option for port selfupdate, use global dry-run option instead.
  • port(1) option -y for dry-run.
  • New pseudo-port ‘obsolete’ to identify ports which are installed but no longer in the PortIndex.
  • MacPorts can now perform fetch, extract, patch, configure and build in a user rather than system owned location. By default, this is ~/.macports/opt. This allows MacPorts to do all but the install of the port without root privileges.
  • MacPorts can now automatically drop privileges so as to avoid running as root whenever possible. To enable this, pass the desired user to run as to configure with the –with-macports-user option.
  • The Portfile format has a number of new boolean attributes to indicate when an action should or should not be run with root privileges: ‘patch.asroot’, ‘build.asroot’, ‘configure.asroot’, ‘destroot.asroot’, and ‘install.asroot’. The default for all is “no”. If the prefix folder (by default /opt/local) is not writable, MacPorts will attempt to elevate privileges to root for the install phase.
  • A “make group” command has been added to the Makefile and a “–with-shared-directory” switch to the configure script. Running “make group” will create a macports group. “–with-shared-directory” will let let the group specified by “–with-install-group” have full read write access to the /opt/local hierarchy. This will allow users who are members of the new macports group to have full write permissions to /opt/local and its subfolders, and hence to install ports which only affect that hierarchy without requiring root privileges.
  • A switch called “–with-no-root-privileges” has been added for use by user installing MacPorts for their own use only.
  • Add several new options to port search, looks in name and description by default
  • Add xpkg package type, xar-based format with XML.
  • Split portpkg creation out from portsubmit phase.
  • Make dependencies displayed in port info respect variants specified in variants.conf; collapse port deps to be an alias for port info with appropriate flags. Note this changes output format of port deps somewhat.
  • Make dependencies in port upgrade respect variants as specified (in order of precedence) on command line, latest installed version, or variants.conf.
  • Add select action, which integrates *_select tools into port.
  • The variants action additionally shows default variants, conflicting variants and variants’ dependencies.
  • Implicit variants (e.g., darwin) can no longer be explicitly set/unset.

Don't miss