blob: f4ab62ab7fa7541dcb0f9ed1f7e609286038d505 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
require 'formula'
class CpioDownloadStrategy < CurlDownloadStrategy
def stage
system "gzcat #{@tarball_path} | cpio -id"
chdir
end
end
class Mksh < Formula
homepage 'https://www.mirbsd.org/mksh.htm'
url 'https://www.mirbsd.org/MirOS/dist/mir/mksh/mksh-R40d.cpio.gz',
:using => CpioDownloadStrategy
version '0.40d'
sha1 '74450a1107664797e5fdbdeb444f18f82f0686ac'
def install
system "sh", "./Build.sh", "-c", (ENV.compiler == :clang ? "lto" : "combine")
bin.install 'mksh'
man1.install 'mksh.1'
end
def caveats; <<-EOS.undent
To allow using mksh as a login shell, run this as root:
echo #{HOMEBREW_PREFIX}/bin/mksh >> /etc/shells
Then, any user may run `chsh` to change their shell.
EOS
end
end
|