coreutils: modernize and add test
Closes Homebrew/homebrew#35305. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
This commit is contained in:
parent
25185d7721
commit
441927e348
1 changed files with 7 additions and 3 deletions
|
@ -1,5 +1,3 @@
|
|||
require "formula"
|
||||
|
||||
class Coreutils < Formula
|
||||
homepage "https://www.gnu.org/software/coreutils"
|
||||
url "http://ftpmirror.gnu.org/coreutils/coreutils-8.23.tar.xz"
|
||||
|
@ -26,7 +24,7 @@ class Coreutils < Formula
|
|||
system "./configure", "--prefix=#{prefix}",
|
||||
"--program-prefix=g",
|
||||
"--without-gmp"
|
||||
system "make install"
|
||||
system "make", "install"
|
||||
|
||||
# Symlink all commands into libexec/gnubin without the 'g' prefix
|
||||
coreutils_filenames(bin).each do |cmd|
|
||||
|
@ -62,6 +60,12 @@ class Coreutils < Formula
|
|||
end
|
||||
filenames.sort
|
||||
end
|
||||
|
||||
test do
|
||||
(testpath/"test").write("test")
|
||||
(testpath/"test.sha1").write("a94a8fe5ccb19ba61c4c0873d391e987982fbbd3 test")
|
||||
system "#{bin}/gsha1sum", "-c", "test.sha1"
|
||||
end
|
||||
end
|
||||
|
||||
__END__
|
||||
|
|
Loading…
Reference in a new issue