brewのgnuplotにpdfオプションが抜かれた俺達は

追記: 2018/11/22

5.25から --with-cairoのオプションが消えてデフォで入るようになったっぽい

さらに追記 2019/12/21

anatofuz.hatenablog.com

TL;DR

$ brew install gnuplot --with-cairo

以前はbrewgnuplotをinstallする際に --with-pdflib-lite などのオプションがあったが最近抜かれていた. そんな中でもpdfを吐き出したい時はどうすれば良いのかぐぐったところstack overflowの記事が発見された.

stackoverflow.com

曰く--with-cario をinstall時に設定すると良いらしい

 ❯ brew reinstall gnuplot --with-aquaterm --with-x11 --with-cairo                                                                                                                                    [21:55:08]
==> Reinstalling gnuplot --with-cairo --with-aquaterm --with-x11
==> Downloading https://downloads.sourceforge.net/project/gnuplot/gnuplot/5.2.2/gnuplot-5.2.2.tar.gz
Already downloaded: /Users/anatofuz/Library/Caches/Homebrew/gnuplot-5.2.2.tar.gz
==> Downloading http://apps.jcns.fz-juelich.de/src/libcerf/libcerf-1.5.tgz
Already downloaded: /Users/anatofuz/Library/Caches/Homebrew/gnuplot--libcerf-1.5.tgz
==> ./configure --prefix=/private/tmp/gnuplot-20180429-83310-1ge0ljp/gnuplot-5.2.2/libcerf --enable-static --disable-shared
==> make install
==> ./configure --disable-silent-rules --prefix=/usr/local/Cellar/gnuplot/5.2.2_1 --with-readline=/usr/local/opt/readline --without-tutorial --disable-wxwidgets --with-qt=no --with-aquaterm --with-x
==> make
==> make install
==> Caveats
AquaTerm support will only be built into Gnuplot if the standard AquaTerm
package from SourceForge has already been installed onto your system.
If you subsequently remove AquaTerm, you will need to uninstall and then
reinstall Gnuplot.
==> Summary
🍺  /usr/local/Cellar/gnuplot/5.2.2_1: 47 files, 2.8MB, built in 1 minute 15 seconds
>>> elapsed time 1m17s

 anatofuz@anatofuz  ~ 
 ❯ gnuplot                                                                                                                                                                                           [21:56:58]

    G N U P L O T
    Version 5.2 patchlevel 2    last modified 2017-11-15

    Copyright (C) 1986-1993, 1998, 2004, 2007-2017
    Thomas Williams, Colin Kelley and many others

    gnuplot home:     http://www.gnuplot.info
    faq, bugs, etc:   type "help FAQ"
    immediate help:   type "help"  (plot window: hit 'h')

Terminal type is now 'aqua'
gnuplot> set term pdf

Terminal type is now 'pdfcairo'
Options are ' transparent enhanced fontscale 0.5 size 5.00in, 3.00in '
gnuplot>

これでokらしい.と言うかなぜ合わせたのか

すでにinstallしている場合は

$brew reinstall gnuplot --with-aquaterm --with-x11 --with-cairo 

など reinstall すればだいたい解決する世界観です