summaryrefslogtreecommitdiff
path: root/lib/mkmf.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/mkmf.rb')
-rw-r--r--lib/mkmf.rb12
1 files changed, 3 insertions, 9 deletions
diff --git a/lib/mkmf.rb b/lib/mkmf.rb
index e8750e4..67af386 100644
--- a/lib/mkmf.rb
+++ b/lib/mkmf.rb
@@ -610,9 +610,7 @@ MSG
end
def try_cppflags(flags)
- with_cppflags(flags) do
- try_header("int main() {return 0;}")
- end
+ try_header(MAIN_DOES_NOTHING, flags)
end
def with_cflags(flags)
@@ -624,9 +622,7 @@ MSG
end
def try_cflags(flags)
- with_cflags(flags) do
- try_compile("int main() {return 0;}")
- end
+ try_compile(MAIN_DOES_NOTHING, flags)
end
def with_ldflags(flags)
@@ -638,9 +634,7 @@ MSG
end
def try_ldflags(flags)
- with_ldflags(flags) do
- try_link("int main() {return 0;}")
- end
+ try_link(MAIN_DOES_NOTHING, flags)
end
def try_static_assert(expr, headers = nil, opt = "", &b)