homebrew-core/Formula/abcm2ps.rb
2017-12-21 08:57:04 -08:00

46 lines
1.3 KiB
Ruby

class Abcm2ps < Formula
desc "ABC music notation software"
homepage "http://moinejf.free.fr"
url "https://github.com/leesavide/abcm2ps/archive/v8.13.18.tar.gz"
sha256 "4855a55ab2ee046e2d11ee30f453a5bef81870d32421fde4305c4850a3c68760"
bottle do
sha256 "21e00350e7cbf8b2749fc8eb42cc98c2f357b381cd9a92b01bc23584033ede97" => :high_sierra
sha256 "17cc1187664cd5c6b3d4e20c60fa06ff43852e5d530c0753e3ea3eecc4801e85" => :sierra
sha256 "9f8dec3ec399b43328b55cd44c7d5f86a89bda69d84c1227faf94f54d949b346" => :el_capitan
end
depends_on "pkg-config" => :build
depends_on "pango" => :optional
def install
system "./configure", "--prefix=#{prefix}"
system "make", "install"
end
test do
(testpath/"voices.abc").write <<~EOS
X:7
T:Qui Tolis (Trio)
C:Andre Raison
M:3/4
L:1/4
Q:1/4=92
%%staves {(Pos1 Pos2) Trompette}
K:F
%
V:Pos1
%%MIDI program 78
"Positif"x3 |x3|c'>ba|Pga/g/f|:g2a |ba2 |g2c- |c2P=B |c>de |fga |
V:Pos2
%%MIDI program 78
Mf>ed|cd/c/B|PA2d |ef/e/d |:e2f |ef2 |c>BA |GA/G/F |E>FG |ABc- |
V:Trompette
%%MIDI program 56
"Trompette"z3|z3 |z3 |z3 |:Mc>BA|PGA/G/F|PE>EF|PEF/E/D|C>CPB,|A,G,F,-|
EOS
system "#{bin}/abcm2ps", testpath/"voices"
assert_predicate testpath/"Out.ps", :exist?
end
end