fiddle: configure in mflags
* ext/fiddle/extconf.rb: configure is already in mflags, use system instead of xsystem which requires a string, and logging libffi configure output. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48904 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
5856a95191
commit
96fc3108b5
@ -24,3 +24,5 @@ configure-libffi $(FFI_H):
|
|||||||
lib: $(LIBFFI_A)
|
lib: $(LIBFFI_A)
|
||||||
$(LIBFFI_A):
|
$(LIBFFI_A):
|
||||||
$(Q) $(SUBMAKE_LIBFFI)
|
$(Q) $(SUBMAKE_LIBFFI)
|
||||||
|
|
||||||
|
configure: configure-libffi
|
||||||
|
@ -80,9 +80,11 @@ create_makefile 'fiddle' do |conf|
|
|||||||
else
|
else
|
||||||
submake = "cd $(LIBFFI_DIR) && \\\n\t\t" << "#{config_string("exec")} $(MAKE)".strip
|
submake = "cd $(LIBFFI_DIR) && \\\n\t\t" << "#{config_string("exec")} $(MAKE)".strip
|
||||||
end
|
end
|
||||||
|
sep = "/"
|
||||||
|
seprpl = config_string('BUILD_FILE_SEPARATOR') {|s| sep = s; ":/=#{s}" if s != "/"} || ""
|
||||||
conf << <<-MK.gsub(/^ +/, '')
|
conf << <<-MK.gsub(/^ +/, '')
|
||||||
PWD =
|
PWD =
|
||||||
LIBFFI_CONFIGURE = $(LIBFFI_SRCDIR)/configure#{/'-C'/ =~ CONFIG['configure_args'] ? ' -C' : ''}
|
LIBFFI_CONFIGURE = $(LIBFFI_SRCDIR#{seprpl})#{sep}configure#{/'-C'/ =~ CONFIG['configure_args'] ? ' -C' : ''}
|
||||||
LIBFFI_ARCH = #{RbConfig::CONFIG['arch'].sub(/\Ax64-(?=mingw|mswin)/, 'x86_64-')}
|
LIBFFI_ARCH = #{RbConfig::CONFIG['arch'].sub(/\Ax64-(?=mingw|mswin)/, 'x86_64-')}
|
||||||
LIBFFI_SRCDIR = #{libffi_srcdir}
|
LIBFFI_SRCDIR = #{libffi_srcdir}
|
||||||
LIBFFI_DIR = #{bundled}
|
LIBFFI_DIR = #{bundled}
|
||||||
@ -94,8 +96,12 @@ create_makefile 'fiddle' do |conf|
|
|||||||
end
|
end
|
||||||
|
|
||||||
if bundled
|
if bundled
|
||||||
xsystem([$make, 'configure-libffi', *sysquote($mflags)]) or
|
args = [$make, *sysquote($mflags)]
|
||||||
|
Logging::open do
|
||||||
|
Logging.message("%p\n", args)
|
||||||
|
system(*args) or
|
||||||
raise "failed to configure libffi. Please install libffi."
|
raise "failed to configure libffi. Please install libffi."
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# :startdoc:
|
# :startdoc:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user