Files
chromebrew/packages/mlocate.rb
Maximilian Downey Twiss de24923ee8 Add Rubocop CI (#7083)
* Rename IgnoredPatterns to AllowedPatterns.

* Exclude docopt.rb (not our code) from Rubocop

* Disable Style/RedundantReturn

* Disable Style/MutableConstant

* Disable Style/NumericLiterals

* Set Layout/IndentationStyle to spaces

* Temporarily disable various cops.

* Add Rubocop CI via Octocop

* Lint tree with rubocop -A -c .rubocop.yml

Co-authored-by: Satadru Pramanik <satadru@gmail.com>
2022-08-22 13:31:25 -04:00

37 lines
1.6 KiB
Ruby

require 'package'
class Mlocate < Package
description 'mlocate is a locate/updatedb implementation.'
homepage 'https://pagure.io/mlocate'
version '0.26-1'
license 'GPL-2'
compatibility 'all'
source_url 'https://releases.pagure.org/mlocate/mlocate-0.26.tar.xz'
source_sha256 '3063df79fe198fb9618e180c54baf3105b33d88fe602ff2d8570aaf944f1263e'
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/mlocate/0.26-1_armv7l/mlocate-0.26-1-chromeos-armv7l.tar.xz',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/mlocate/0.26-1_armv7l/mlocate-0.26-1-chromeos-armv7l.tar.xz',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/mlocate/0.26-1_i686/mlocate-0.26-1-chromeos-i686.tar.xz',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/mlocate/0.26-1_x86_64/mlocate-0.26-1-chromeos-x86_64.tar.xz'
})
binary_sha256({
aarch64: '69e02f44a498cd38a8f4bc2e3410f934506426d670664c402a09bfb34d51418c',
armv7l: '69e02f44a498cd38a8f4bc2e3410f934506426d670664c402a09bfb34d51418c',
i686: '74acf4453947b3570f68c43e485cb8e9f2da688e4a50336d593bbba1b6ebd2ee',
x86_64: 'f943fe00ad4666f5a9c7bf12d710cd8f2e136a33ad94568863b92dd45526d7eb'
})
def self.build
system "mkdir -p #{CREW_PREFIX}/db/mlocate"
system "sed -i 's,\$(localstatedir)/,#{CREW_PREFIX}/db/,g' Makefile.*"
system "sed -i \"s/groupname = mlocate/groupname = #{USER}/g\" Makefile.*"
system './configure'
system 'make'
end
def self.install
system 'make', "DESTDIR=#{CREW_DEST_DIR}", 'install'
end
end