Files
chromebrew/packages/libmad.rb
Maximilian Downey Twiss f6dc1d8d4e Derive binary_url in package.rb (#7082)
* Add binary_compression value to each package

* Remove binary_url values and arrays

* Handle packages with empty binary_sha256 arrays (either missing binaries or not compiled by us)
2024-01-25 11:03:31 -05:00

42 lines
1.4 KiB
Ruby

require 'package'
class Libmad < Package
description 'MAD is a high-quality MPEG audio decoder.'
homepage 'https://www.underbit.com/products/mad/'
version '0.15.1b-1'
compatibility 'all'
license 'GPL-2'
source_url 'https://httpredir.debian.org/debian/pool/main/libm/libmad/libmad_0.15.1b.orig.tar.gz'
source_sha256 'bbfac3ed6bfbc2823d3775ebb931087371e142bb0e9bb1bee51a76a6e0078690'
binary_compression 'tpxz'
binary_sha256({
aarch64: 'fa97940e20089f3c79388d13a3e05f3d527cd59641fdf09afdf8aea4ea379523',
armv7l: 'fa97940e20089f3c79388d13a3e05f3d527cd59641fdf09afdf8aea4ea379523',
i686: '71822bdcb2d8c25e0005bd0d29b61c9b0b2f592a9e07be5e51783eba4432dbe8',
x86_64: '10dca6998f2fdab04234345da0ed00a6c9d9705d0e139032f5d297f99d31ae7b'
})
def self.patch
downloader 'https://httpredir.debian.org/debian/pool/main/libm/libmad/libmad_0.15.1b-10.diff.gz', 'dfeabd5d2398bf902660edc31f87ad40600f0aa732b946f864d8ee6bbf56a99c'
system 'zcat libmad_0.15.1b-10.diff.gz | patch -Np1'
system "for i in \$(cat debian/patches/series); do patch -Np1 -i debian/patches/\${i}; done"
end
def self.build
system "#{CREW_ENV_OPTIONS} ./configure #{CREW_OPTIONS} \
--enable-accuracy \
--disable-debugging"
system 'make'
end
def self.install
system 'make', "DESTDIR=#{CREW_DEST_DIR}", 'install'
end
def self.check
system 'make', 'check'
end
end