From d21302479b6b525eae3a67f664b0a96fda08b638 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eloy=20Dur=C3=A1n?= Date: Fri, 7 Feb 2014 11:25:07 +0100 Subject: [PATCH] [Vendor] Cannot reuse opts[:cflags] if it has been deleted before. --- NEWS | 2 ++ lib/motion/project/vendor.rb | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index fa7877c1..b96953e7 100644 --- a/NEWS +++ b/NEWS @@ -8,6 +8,8 @@ * Fixed a regression with specifying external templates to `motion create'. * Fixed a bug which WeakRef.new would cause a crash when passed nil, true, false, Fixnum or Float object. + * Fixed issue where `vendor_project' with `:static' did not reuse `:cflags' + for the BridgeSupport generation. = RubyMotion 2.22 = diff --git a/lib/motion/project/vendor.rb b/lib/motion/project/vendor.rb index 9a82c0b3..a4416ef1 100644 --- a/lib/motion/project/vendor.rb +++ b/lib/motion/project/vendor.rb @@ -134,7 +134,7 @@ EOS bs_file = File.join(build_dir, File.basename(@path) + '.bridgesupport') if !File.exist?(bs_file) or headers.any? { |h| File.mtime(h) > File.mtime(bs_file) } FileUtils.mkdir_p File.dirname(bs_file) - bs_cflags = (opts.delete(:bridgesupport_cflags) or opts.delete(:cflags) or '') + bs_cflags = (opts.delete(:bridgesupport_cflags) or cflags) bs_exceptions = (opts.delete(:bridgesupport_exceptions) or []) @config.gen_bridge_metadata(platform, headers, bs_file, bs_cflags, bs_exceptions) end