ext/nokogiri_ext_xmlsec/extconf.rb in nokogiri-xmlsec-instructure-0.10.1 vs ext/nokogiri_ext_xmlsec/extconf.rb in nokogiri-xmlsec-instructure-0.10.2

- old
+ new

@@ -1,6 +1,7 @@ require 'mkmf' +require 'nokogiri' def barf message = 'dependencies not met' raise message end @@ -20,8 +21,14 @@ puts "Ensure we escaping: #{$CFLAGS}" $CFLAGS['-DXMLSEC_CRYPTO="openssl"'] = '-DXMLSEC_CRYPTO=\\"openssl\\"' end +$CFLAGS << Dir[Gem.loaded_specs['nokogiri'].full_gem_path + "/ext/*"].map { |dir| " -I#{dir}"}.join("") + puts "Clfags: #{$CFLAGS}" $libs = `xmlsec1-config --libs`.strip + +# We reference symbols out of nokogiri but don't link directly against it +$LDFLAGS << ' -Wl,-undefined,dynamic_lookup' + create_makefile('nokogiri_ext_xmlsec')