Macports High Sierra


Define local keyword globally in a macports config. My main target is to globally enable all ports to compile with macports-clang-3.4 and use libc instead of libstdc. For example when working with one port I need to set configure.compiler=macports. Asked Jan 24 '14 at 16:59. I have a Mac, I download Macports High Sierra version but I coud'nt find the tesseract version as it is a prerequisite before doing the parameters of the plugin Zotero OCR. Ayabejermi April 10, 2021. I created the inetutils port for that very reason, while High Sierra was still in beta. I have now pushed it to the main repository. Note: the names of the various binaries have the 'g' prefix, as is common practice for GNU utilities under MacPorts.

#63476closeddefect (duplicate)

Reported by:Owned by:
Priority: Normal Milestone:
Component: ports Version: 2.7.1
Keywords: Cc:
Port: libunistring

Description (last modified by ryandesign (Ryan Schmidt))

Change History (2)

comment:1 Changed 4 weeks ago by ryandesign (Ryan Schmidt)

Install macports high sierraMacports high sierra 2019
Description: modified (diff)
Summary:build libunistring fails while installing wxWidgets-3.2 portlibunistring @0.9.10: configure.ac:25: error: AC_INIT should be called with package and version arguments

comment:2 Changed 4 weeks ago by ryandesign (Ryan Schmidt)

Note: See TracTickets for help on using tickets.

Macports provides hundreds of Open Source Unix tools compiled for OS X, free.

Macports is an alternative to Fink. You can use either or use both and install some packages with one tool and some with the other. I use Macports for everything now.

I switched from Macports to Homebrew in September 2021 on Big Sur (macOS 11.6) because I had trouble installing programs using MacPorts.

Installing Macports

If you are upgrading from a previous version, see https://trac.macports.org/wiki/Migration.

Here are instructions for setting up a 64-bit Macports, tested
April 2014 on 10.9.2 Mavericks.
Oct 2015 on 10.10.5 Yosemite.
May 2016 on 10.11.5 El Capitan.
July 2017 on 10.12.6 Sierra.
March 2018 on 10.13.3 High Sierra.
January 2019 on 10.14.2 Mojave.


  • Install the Xcode command line tools (free from Apple) by doing sudo xcode-select --install.
  • From https://www.macports.org/, choose the .pkg installer for your macOS version and download and install it. Follow the instructions on the website. If you are upgrading an old installation and encounter failures, you could try doing sudo port -fp uninstall installed .
  • Installing Macports will alter your .bash_profile to add /opt/bin and /opt/sbin to your PATH.
  • Now you can do sudo port install xxx for all the modules you want. The ones I installed are
    • ImageMagick ... this drags in a lot of prerequisite packages including Ghostscript and Perl.
    • uni2ascii
    • psutils
    • graphviz ... installs Python
    • rsync ... Mavericks, El Capitan, and Sierra come with 2.6.9, MacPorts installs 3.1.2
    • wget
    • gnuplot ... See this repair story.
    • poppler needed for pdftotext
    • exiftool ... manage metadata in .jpg files

Don't install tidy from macports.. use https://github.com/htacg/tidy-html5 instead.


(Apple has announced that in versions of macOS after Catalina, they will not provide Python, Perl, or Ruby. This is a small loss since the versions they had been shipping with the OS were usually downrev. For Catalina, I will install a later version of Perl, as a side effect of the various ports I install. Apple provides Perl 5.16 with Mavericks and Yosemite, and 5.18.2 with El Capitan, Sierra, High Sierra, and Mojave.)

On recent versions of OS X, installing certain ports will cause Macports to install a later version of Perl (on Sierra, it installed 5.24, and 5.26 for High Sierra and Mojave). If you then update CPAN, it will install Perl modules into that version's libraries. The version of Perl executed by programs will depend on the shebang line at the top of the file, and that is where library files will be searched for. The risk is that modules you just installed will not be found, and attempts to install ports will fail with messages about variants. Fix this by making /usr/local/bin/perl a symlink to the MacPorts version of Perl in /opt/local/bin/perlbefore updating CPAN, and making sure that all library Perl programs and modules use #!/usr/local/bin/perl as their 'shebang' line. (The reason for this complexity is that you can't change /usr/bin due to System Integrity Protection.)


For Mojave, I installed the full Xcode and the command line extensions, and then installed MacPorts. Installing ImageMagick installed Perl 5.28.

High Sierra

When I was transitioning to High Sierra, I installed the Apple developer tools using xcode-select --install, and then installed MacPorts. When I tried to install the first ports, I got the message

.. so I had to install the full Xcode. This took about an hour. Then I tried to install ImageMagick. This failed with a message that a .gz file (part of Ghostscript) was an HTML error message that said I was trying to download from SourceForge.net and it was 'in Disaster Recovery Mode.' I was stuck for several days. Then they fixed their error.

Macports high sierra download

For High Sierra, installing ImageMagick installed Perl 5.26. I set my startup environment to


For Sierra, I used PERL5LIB=/Users/myname/bin:/opt/local/lib/perl5/site_perl/5.24 I also did

Problem with Poppler

On Sierra, I tried to install poppler in order to get pdftotext. It dragged in a whole pile of dependencies and then the install failed with the message

I Googled this problem and was led to uninstall poppler, install [email protected] and [email protected], and reinstall poppler. That worked. I have not tried this yet with High Sierra.

El Capitan

Macports High Sierra Download

For El Capitan, I used PERL5LIB=/Users/myname/bin:/opt/local/lib/perl5/site_perl/5.22 and linked /usr/bin/perl to /opt/local/bin/perl to ensure that the correct version is invoked (had to temporarily disable SIP). I also set up my bash configuration to do

Macports High Sierra 2020

Home FAQ© 2010-2021, Tom Van Vleckupdated 2021-09-25 11:23

  • Most Viewed News

    • Kitematic For Windows 10
    • Teamviewer Online Without Installation Mac
    • Upgrade Docker Ubuntu
    • Utorrent Mac Mavericks