motion.h 0.0.6 → 0.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Rakefile +1 -1
- data/lib/motion.h.rb +23 -9
- data/motion.h.gemspec +1 -1
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 511528c649ad4a3843b64b4a92f5a8f4894d6210
|
4
|
+
data.tar.gz: 3ea00c01f5388e197681382011cf57f5413a358d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1d4bc836006f18b002eb46f4879b8f9361ac3f8f202cc3797f7492242cbb6d0f716d8937259450c9225b3c15748359128b3005d6841042af9ca3a3542cacb3ac
|
7
|
+
data.tar.gz: d28c3f961aa804f253b4dd143b3c3f2e1bff62e0bb0cfa8f3fa8ec8be49a2dda7a233c48e1f1cdbe7336c3d62d997721edc20b76d5d9714eea685a41b7980c6c
|
data/Rakefile
CHANGED
data/lib/motion.h.rb
CHANGED
@@ -60,19 +60,26 @@ class MotionHeader
|
|
60
60
|
def generate_bridgesupport_file
|
61
61
|
return if File.exist?(bridgesupport_file)
|
62
62
|
Dir.mkdir(@bridgesupport_dir) unless Dir.exist?(@bridgesupport_dir)
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
end
|
63
|
+
cflags = [
|
64
|
+
"-I#{include_path}",
|
65
|
+
"-F#{frameworks_path}"
|
66
|
+
]
|
67
|
+
if product_version >= catalina_version
|
68
|
+
cflags << "--isysroot #{isysroot_dir}"
|
70
69
|
end
|
71
|
-
Bundler.
|
72
|
-
`/Library/RubyMotion/bin/gen_bridge_metadata --format complete
|
70
|
+
Bundler.with_unbundled_env do
|
71
|
+
`/Library/RubyMotion/bin/gen_bridge_metadata --format complete --64-bit --cflags '#{cflags.join(' ')}' #{@header_file} > #{bridgesupport_file}`
|
73
72
|
end
|
74
73
|
end
|
75
74
|
|
75
|
+
def catalina_version
|
76
|
+
Gem::Version.new('10.15')
|
77
|
+
end
|
78
|
+
|
79
|
+
def product_version
|
80
|
+
Gem::Version.new(`sw_vers -productVersion`)
|
81
|
+
end
|
82
|
+
|
76
83
|
def include_path
|
77
84
|
sdk_dir = sdk_dir(@config.sdk_version)
|
78
85
|
path_components = [@config.xcode_dir, *sdk_dir, 'usr', 'include', @prefix].compact
|
@@ -85,6 +92,13 @@ class MotionHeader
|
|
85
92
|
File.join(*path_components)
|
86
93
|
end
|
87
94
|
|
95
|
+
def isysroot_dir
|
96
|
+
case platform
|
97
|
+
when :ios then 'iPhoneOS'
|
98
|
+
when :osx then 'MacOSX'
|
99
|
+
end
|
100
|
+
end
|
101
|
+
|
88
102
|
def sdk_dir(sdk_version)
|
89
103
|
case platform
|
90
104
|
when :ios
|
data/motion.h.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: motion.h
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dave Lee
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-01-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -56,7 +56,7 @@ homepage: https://github.com/kastiglione/motion.h
|
|
56
56
|
licenses:
|
57
57
|
- MIT
|
58
58
|
metadata: {}
|
59
|
-
post_install_message:
|
59
|
+
post_install_message:
|
60
60
|
rdoc_options: []
|
61
61
|
require_paths:
|
62
62
|
- lib
|
@@ -71,9 +71,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
71
71
|
- !ruby/object:Gem::Version
|
72
72
|
version: '0'
|
73
73
|
requirements: []
|
74
|
-
rubyforge_project:
|
75
|
-
rubygems_version: 2.5.
|
76
|
-
signing_key:
|
74
|
+
rubyforge_project:
|
75
|
+
rubygems_version: 2.5.2.3
|
76
|
+
signing_key:
|
77
77
|
specification_version: 4
|
78
78
|
summary: Expose iOS system C libraries in RubyMotion.
|
79
79
|
test_files: []
|