Skip to content

Commit

Permalink
makensis 3.0b3 (devel)
Browse files Browse the repository at this point in the history
Closes Homebrew/legacy-homebrew#49570.

Signed-off-by: Dominyk Tiller <dominyktiller@gmail.com>
  • Loading branch information
idleberg authored and DomT4 committed Feb 28, 2016
1 parent 8156817 commit f726bd8
Showing 1 changed file with 32 additions and 10 deletions.
42 changes: 32 additions & 10 deletions Formula/makensis.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,16 @@
class Makensis < Formula
desc "System to create Windows installers"
homepage "http://nsis.sourceforge.net/"
url "https://downloads.sourceforge.net/project/nsis/NSIS%202/2.50/nsis-2.50-src.tar.bz2"
sha256 "3fb674cb75e0237ef6b7c9e8a8e8ce89504087a6932c5d2e26764d4220a89848"

stable do
url "https://downloads.sourceforge.net/project/nsis/NSIS%202/2.50/nsis-2.50-src.tar.bz2"
sha256 "3fb674cb75e0237ef6b7c9e8a8e8ce89504087a6932c5d2e26764d4220a89848"

resource "nsis" do
url "https://downloads.sourceforge.net/project/nsis/NSIS%202/2.50/nsis-2.50.zip"
sha256 "36bebcd12ad8ec6b94920b46c4c5a7a9fccdaa5e9aececb9e89aecfdfa35e472"
end
end

bottle do
cellar :any_skip_relocation
Expand All @@ -11,29 +19,44 @@ class Makensis < Formula
sha256 "df608eed02642d4f9dfbc230e175e460e9769d351acbd9411455ad4333cf1282" => :mavericks
end

devel do
url "https://downloads.sourceforge.net/project/nsis/NSIS%203%20Pre-release/3.0b3/nsis-3.0b3-src.tar.bz2"
sha256 "faf22d6cd4bd46780afcf22524a1de39bcc38c85773719ec7a1ecf002e308d3a"

resource "nsis" do
url "https://downloads.sourceforge.net/project/nsis/NSIS%203%20Pre-release/3.0b3/nsis-3.0b3.zip"
sha256 "8eee1f0f31c5f776cb2aa34197f906220c9ed43918424eb5bced3ca773e58b10"
end
end

depends_on "scons" => :build

# scons appears to have no builtin way to override the compiler selection,
# and the only options supported on OS X are 'gcc' and 'g++'.
# Use the right compiler by forcibly altering the scons config to set these
patch :DATA

resource "nsis" do
url "https://downloads.sourceforge.net/project/nsis/NSIS%202/2.50/nsis-2.50.zip"
sha256 "36bebcd12ad8ec6b94920b46c4c5a7a9fccdaa5e9aececb9e89aecfdfa35e472"
end

def install
# makensis fails to build under libc++; since it's just a binary with
# no Homebrew dependencies, we can just use libstdc++
# https://sourceforge.net/p/nsis/bugs/1085/
ENV.libstdcxx if ENV.compiler == :clang

# Don't strip, see https://github.com/Homebrew/homebrew/issues/28718
scons "STRIP=0", "makensis"
bin.install "build/release/makensis/makensis"
scons "STRIP=0", "SKIPUTILS=all", "makensis"

if build.stable?
bin.install "build/release/makensis/makensis"
else
bin.install "build/urelease/makensis/makensis"
end

(share/"nsis").install resource("nsis")
end

test do
system "#{bin}/makensis", "-VERSION"
end
end

__END__
Expand All @@ -56,4 +79,3 @@ def install
+
def AddValuedDefine(define):
defenv.Append(NSIS_CPPDEFINES = [(define, env[define])])

0 comments on commit f726bd8

Please sign in to comment.