Shuffle the order of the various CFLAGS used when building the Ruby extension: first the flags from manywarnings (gnulib), then libguestfs own CFLAGS, and then -DGUESTFS_PRIVATE=1 (so it is not overridden).
This matches also what happens in automake parts, and makes it possible to override any flags from manywarnings also in the Ruby extension. --- ruby/ext/guestfs/extconf.rb.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ruby/ext/guestfs/extconf.rb.in b/ruby/ext/guestfs/extconf.rb.in index c4551fa6c..6b806101e 100644 --- a/ruby/ext/guestfs/extconf.rb.in +++ b/ruby/ext/guestfs/extconf.rb.in @@ -33,8 +33,9 @@ have_func("rb_define_alloc_func") have_type("rb_alloc_func_t") $CFLAGS = - "#{$CFLAGS} @CFLAGS@ -DGUESTFS_PRIVATE=1 " << - "@WARN_CFLAGS@ @WERROR_CFLAGS@" + "#{$CFLAGS} " << + "@WARN_CFLAGS@ @WERROR_CFLAGS@ " << + "@CFLAGS@ -DGUESTFS_PRIVATE=1" create_header create_makefile(extension_name, "@abs_srcdir@") -- 2.13.4 _______________________________________________ Libguestfs mailing list Libguestfs@redhat.com https://www.redhat.com/mailman/listinfo/libguestfs