mirror of
https://github.com/ruby/ruby.git
synced 2025-08-23 13:04:13 +02:00
[ruby/fiddle] Suppress -Wundef warnings
(https://github.com/ruby/fiddle/pull/157)
The GCC warning puts undefined macro names in double quotes while clang
puts them in single quotes.
7dcb40bccb
This commit is contained in:
parent
346085ea94
commit
a51007fc35
2 changed files with 1 additions and 5 deletions
|
@ -68,11 +68,6 @@ unless bundle
|
||||||
end
|
end
|
||||||
if have_ffi_header && (have_library('ffi') || have_library('libffi'))
|
if have_ffi_header && (have_library('ffi') || have_library('libffi'))
|
||||||
have_libffi = true
|
have_libffi = true
|
||||||
checking_for("undefined FFI_GO_CLOSURES is used") do
|
|
||||||
if egrep_cpp(/warning: 'FFI_GO_CLOSURES' is not defined/, cpp_include(ffi_header), "2>&1")
|
|
||||||
$defs.push('-DFFI_GO_CLOSURES=0')
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -40,6 +40,7 @@
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#define FFI_GO_CLOSURES 0 /* fiddle does not use go closures */
|
||||||
#ifdef USE_HEADER_HACKS
|
#ifdef USE_HEADER_HACKS
|
||||||
#include <ffi/ffi.h>
|
#include <ffi/ffi.h>
|
||||||
#else
|
#else
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue