diff --git a/Formula/xpdf.rb b/Formula/xpdf.rb index e1a0ce2a90..cc907ed896 100644 --- a/Formula/xpdf.rb +++ b/Formula/xpdf.rb @@ -1,15 +1,34 @@ require 'formula' class Xpdf < Formula - url 'ftp://ftp.foolabs.com/pub/xpdf/xpdf-3.03.tar.gz' homepage 'http://www.foolabs.com/xpdf/' + url 'ftp://ftp.foolabs.com/pub/xpdf/xpdf-3.03.tar.gz' md5 'af75f772bee0e5ae4a811ff9d03eac5a' + # see: http://gnats.netbsd.org/45562 + def patches; DATA; end + def install - system "./configure", "--disable-debug", "--disable-dependency-tracking", - "--prefix=#{prefix}", - "--mandir=#{man}" + ENV.x11 + ENV.append_to_cflags '-I/usr/X11/include -I/usr/X11/include/freetype2' + + system "./configure", "--prefix=#{prefix}", "--mandir=#{man}" system "make" system "make install" end end + +__END__ +diff --git a/xpdf/XPDFViewer.cc b/xpdf/XPDFViewer.cc +index 2de349d..e6ef7fa 100644 +--- a/xpdf/XPDFViewer.cc ++++ b/xpdf/XPDFViewer.cc +@@ -1803,7 +1803,7 @@ void XPDFViewer::initToolbar(Widget parent) { + menuPane = XmCreatePulldownMenu(toolBar, "zoomMenuPane", args, n); + for (i = 0; i < nZoomMenuItems; ++i) { + n = 0; +- s = XmStringCreateLocalized(zoomMenuInfo[i].label); ++ s = XmStringCreateLocalized((char *)zoomMenuInfo[i].label); + XtSetArg(args[n], XmNlabelString, s); ++n; + XtSetArg(args[n], XmNuserData, (XtPointer)i); ++n; + sprintf(buf, "zoom%d", i);