xot 0.2.1 → 0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/release-gem.yml +1 -1
- data/.github/workflows/test.yml +3 -0
- data/ChangeLog.md +5 -0
- data/VERSION +1 -1
- data/include/xot/windows.h +15 -0
- data/include/xot.h +2 -0
- data/lib/xot/extconf.rb +3 -3
- data/lib/xot/rake/util.rb +15 -8
- data/lib/xot/rake.rb +4 -1
- data/src/exception.cpp +1 -3
- data/src/string.cpp +1 -0
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7d11136d38c0cd9cd9dcca16148115795071e958e05ef3d5b307bd385905c1f6
|
4
|
+
data.tar.gz: 7af44d2bcd37badd34c4d5493bc21c5357fcde972b89d9a1833b1e70f5fe12d7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ca6c659c661dd12179e968b8a832951cb6a812e0f4155ebb29d807147cae2ba6960c51d823f68a47bc070db4a8070441ba22285f67975686ee31928fa1e8cb90
|
7
|
+
data.tar.gz: 9c640bcc810ff7c6143f63936f753bb544f0b939f1c15c4e685b420e614db7e8d8bdcf9b0d105089b727585d9712991dcd0a4f8fd3d183994ae368c1e66ea569
|
data/.github/workflows/test.yml
CHANGED
data/ChangeLog.md
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.3
|
data/include/xot.h
CHANGED
data/lib/xot/extconf.rb
CHANGED
@@ -29,8 +29,8 @@ module Xot
|
|
29
29
|
|
30
30
|
extensions.each do |ext|
|
31
31
|
name = ext.name.downcase
|
32
|
-
headers
|
33
|
-
|
32
|
+
headers << "#{name}.h"
|
33
|
+
local_libs << name
|
34
34
|
end
|
35
35
|
|
36
36
|
ldflags = $LDFLAGS.dup
|
@@ -45,7 +45,7 @@ module Xot
|
|
45
45
|
$CFLAGS = make_cflags $CFLAGS + ' -x c++'
|
46
46
|
$CXXFLAGS = make_cflags $CXXFLAGS + ' -x c++' if $CXXFLAGS
|
47
47
|
$LDFLAGS = make_ldflags ldflags, lib_dirs, frameworks
|
48
|
-
$LOCAL_LIBS << local_libs.map {|s| " -l#{s}"}.join
|
48
|
+
$LOCAL_LIBS << local_libs.reverse.map {|s| " -l#{s}"}.join
|
49
49
|
end
|
50
50
|
|
51
51
|
def create_makefile(*args)
|
data/lib/xot/rake/util.rb
CHANGED
@@ -55,7 +55,10 @@ module Xot
|
|
55
55
|
end
|
56
56
|
|
57
57
|
def inc_dirs()
|
58
|
-
env_array
|
58
|
+
dirs = env_array :INCDIRS, []
|
59
|
+
dirs += extensions.reverse.map {|m| m.inc_dir}.flatten
|
60
|
+
dirs << "#{env :MINGW_PREFIX}/include" if mingw?
|
61
|
+
dirs
|
59
62
|
end
|
60
63
|
|
61
64
|
def src_dirs()
|
@@ -170,11 +173,15 @@ module Xot
|
|
170
173
|
|
171
174
|
def make_cppflags_defs(defs = [])
|
172
175
|
a = defs.dup
|
173
|
-
a << $~[0].upcase if RUBY_PLATFORM =~ /mswin|ming|cygwin|darwin/i
|
174
176
|
a << (debug? ? '_DEBUG' : 'NDEBUG')
|
175
|
-
a <<
|
176
|
-
a <<
|
177
|
-
a << '
|
177
|
+
a << target.name.upcase
|
178
|
+
a << $~[0].upcase if RUBY_PLATFORM =~ /mswin|mingw|cygwin|darwin/i
|
179
|
+
a << 'WIN32' if win32?
|
180
|
+
a << 'OSX' if osx?
|
181
|
+
a << 'IOS' if ios?
|
182
|
+
a << 'GCC' if gcc?
|
183
|
+
a << 'CLANG' if clang?
|
184
|
+
a << '_USE_MATH_DEFINES' if gcc?
|
178
185
|
a
|
179
186
|
end
|
180
187
|
|
@@ -192,11 +199,11 @@ module Xot
|
|
192
199
|
end
|
193
200
|
|
194
201
|
def make_cflags(flags = '')
|
195
|
-
warning_opts
|
196
|
-
|
202
|
+
warning_opts = %w[no-unknown-pragmas]
|
203
|
+
warning_opts += %w[
|
197
204
|
no-deprecated-register
|
198
205
|
no-reserved-user-defined-literal
|
199
|
-
]
|
206
|
+
] if clang?
|
200
207
|
s = flags.dup
|
201
208
|
s << warning_opts.map {|s| " -W#{s}"}.join
|
202
209
|
s << " -arch arm64" if RUBY_PLATFORM =~ /arm64-darwin/
|
data/lib/xot/rake.rb
CHANGED
@@ -276,7 +276,7 @@ module Xot
|
|
276
276
|
desc "install packages"
|
277
277
|
task :packages do
|
278
278
|
case
|
279
|
-
when osx?
|
279
|
+
when osx? && osx.size > 0
|
280
280
|
sh %( brew install #{osx.join ' '} )
|
281
281
|
when win32? && win32.size > 0
|
282
282
|
prefix = 'MINGW_PACKAGE_PREFIX'
|
@@ -359,6 +359,9 @@ module Xot
|
|
359
359
|
end
|
360
360
|
|
361
361
|
def define_placeholder_tasks()
|
362
|
+
desc "install all external packages"
|
363
|
+
alias_task :packages
|
364
|
+
|
362
365
|
desc "setup all external libraries"
|
363
366
|
alias_task :vendor
|
364
367
|
|
data/src/exception.cpp
CHANGED
data/src/string.cpp
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xot
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: '0.3'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- xordog
|
@@ -41,6 +41,7 @@ files:
|
|
41
41
|
- include/xot/string.h
|
42
42
|
- include/xot/time.h
|
43
43
|
- include/xot/util.h
|
44
|
+
- include/xot/windows.h
|
44
45
|
- lib/xot.rb
|
45
46
|
- lib/xot/bit_flag.rb
|
46
47
|
- lib/xot/bit_flag_accessor.rb
|