ploticus: add prefabs to installation
The existing formula for Ploticus 2.42 omits the installation of the "prefabs" directory, which most users will need. This patch ensures that the prefabs are installed into pkgshare, and that ploticus knows where to find them without having to set the PREFABS_DIR environment variable. Closes Homebrew/homebrew#48296. Signed-off-by: Dominyk Tiller <dominyktiller@gmail.com>master
parent
22521b18b5
commit
18de525327
|
@ -4,6 +4,7 @@ class Ploticus < Formula
|
|||
url "https://downloads.sourceforge.net/project/ploticus/ploticus/2.42/ploticus242_src.tar.gz"
|
||||
version "2.42"
|
||||
sha256 "3f29e4b9f405203a93efec900e5816d9e1b4381821881e241c08cab7dd66e0b0"
|
||||
revision 1
|
||||
|
||||
bottle do
|
||||
cellar :any
|
||||
|
@ -18,10 +19,17 @@ class Ploticus < Formula
|
|||
# Use alternate name because "pl" conflicts with OS X "pl" utility
|
||||
args=["INSTALLBIN=#{bin}",
|
||||
"EXE=ploticus"]
|
||||
inreplace "src/pl.h", /#define\s+PREFABS_DIR\s+""/, "#define PREFABS_DIR \"#{pkgshare}\""
|
||||
system "make", "-C", "src", *args
|
||||
# Required because the Makefile assumes INSTALLBIN dir exists
|
||||
bin.mkdir
|
||||
system "make", "-C", "src", "install", *args
|
||||
pkgshare.install Dir["prefabs/*"]
|
||||
end
|
||||
|
||||
def caveats; <<-EOS.undent
|
||||
Ploticus prefabs have been installed to #{opt_pkgshare}
|
||||
EOS
|
||||
end
|
||||
|
||||
test do
|
||||
|
|
Loading…
Reference in New Issue