From c3ef065e96f9988785f7ffdd9538575ee0d1930f Mon Sep 17 00:00:00 2001 From: Alex Wang Date: Sat, 15 Oct 2016 06:56:45 -0400 Subject: [PATCH] gcc: set better version number for HEAD builds (#4783) --- Formula/gcc.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Formula/gcc.rb b/Formula/gcc.rb index 4b662a8bbd..f108aa0a08 100644 --- a/Formula/gcc.rb +++ b/Formula/gcc.rb @@ -73,7 +73,11 @@ class Gcc < Formula end def version_suffix - version.to_s.slice(/\d/) + if build.head? + (stable.version.to_s.slice(/\d/).to_i + 1).to_s + else + version.to_s.slice(/\d/) + end end # Fix for libgccjit.so linkage on Darwin