aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorAlex Wang2015-12-25 17:36:08 -0500
committerMike McQuaid2015-12-26 21:50:51 +0000
commitd09698f19f3a57ce00baddc6142aa484d7d908f6 (patch)
tree437c7421ae4bc9c0960a63d4e5a0632b729a4990 /Library
parente865cee3d33e38485a46e1b88f8aa9466f31633f (diff)
downloadbrew-d09698f19f3a57ce00baddc6142aa484d7d908f6.tar.bz2
Add -DNDEBUG to std_cmake_args
CMake has -DNDEBUG and -O3 as its default flags for Release builds. Homebrew clears out the default CMake flags, which is fine for optimization because Homebrew passes its own optimization flag(s). -DNDEBUG wasn't added back in, though. This ensures -DNDEBUG is passed to CMake release builds by default, instead of individual formulas having to add it explicitly. This also removes explicit additions of -DNDEBUG from the formulae that had them -- gflags, llvm, and taglib. Closes Homebrew/homebrew#47378. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/formula.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb
index 68c836f2b..36bdb0ffe 100644
--- a/Library/Homebrew/formula.rb
+++ b/Library/Homebrew/formula.rb
@@ -1041,8 +1041,8 @@ class Formula
# less consistent and the standard parameters are more memorable.
def std_cmake_args
%W[
- -DCMAKE_C_FLAGS_RELEASE=
- -DCMAKE_CXX_FLAGS_RELEASE=
+ -DCMAKE_C_FLAGS_RELEASE=-DNDEBUG
+ -DCMAKE_CXX_FLAGS_RELEASE=-DNDEBUG
-DCMAKE_INSTALL_PREFIX=#{prefix}
-DCMAKE_BUILD_TYPE=Release
-DCMAKE_FIND_FRAMEWORK=LAST