You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The forcing of some compiler options can be bad. In the case of -Wall. This is GCC centric and would cause compilation on other platforms to fail (i.e. Solaris and Windows). The following patch might be a solution.
--- ext/xslt_lib/extconf.rb 2011-01-11 10:16:12.424617000 -0600
+++ ext/xslt_lib/extconf.rb.new 2011-01-11 10:07:10.048251000 -0600
@@ -54,7 +54,14 @@
$CFLAGS += " -DUSE_EXSLT"
end
-$CFLAGS = '-g -Wall ' + `xml2-config --cflags`.chomp + " " + `xslt-config --cflags`.chomp + " " + $CFLAGS
+# Allow for custom compiler to be specified.
+RbConfig::MAKEFILE_CONFIG['CC'] = ENV['CC'] if ENV['CC']
+
+# NOTE: use GCC flags unless Visual C compiler is used
+$CFLAGS << '-Wall ' if (RbConfig::MAKEFILE_CONFIG['CC'] =~ /gcc/ && RUBY_PLATFORM !~ /mswin/ )
+
+$CFLAGS << '-g ' + `xml2-config --cflags`.chomp + " " + `xslt-config --cflags`.chomp
+
create_header()
create_makefile("xml/xslt_lib")
The text was updated successfully, but these errors were encountered:
The forcing of some compiler options can be bad. In the case of -Wall. This is GCC centric and would cause compilation on other platforms to fail (i.e. Solaris and Windows). The following patch might be a solution.
The text was updated successfully, but these errors were encountered: