ritsu 0.5.1 → 0.5.2
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/bin/define_cpp_string +0 -0
- data/bin/ritsu +0 -0
- data/lib/ritsu/ext/cuda/src_files/target_cmake_lists.rb +1 -0
- data/lib/ritsu/ext/fake_install/src_files/project_cmake_lists.rb +1 -0
- data/lib/ritsu/external_library.rb +1 -1
- data/lib/ritsu/src_file.rb +2 -2
- data/lib/ritsu/src_files/project_cmake_lists.rb +11 -1
- metadata +8 -8
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.5.
|
1
|
+
0.5.2
|
data/bin/define_cpp_string
CHANGED
File without changes
|
data/bin/ritsu
CHANGED
File without changes
|
@@ -31,7 +31,7 @@ module Ritsu
|
|
31
31
|
|
32
32
|
def self.validate_instance(instance)
|
33
33
|
if instances.select { |x| x.name == instance.name }.length > 0
|
34
|
-
raise ArgumentError.new
|
34
|
+
raise ArgumentError.new("external library with name '#{instance.name}' already exists")
|
35
35
|
end
|
36
36
|
end
|
37
37
|
|
data/lib/ritsu/src_file.rb
CHANGED
@@ -17,7 +17,7 @@ module Ritsu
|
|
17
17
|
|
18
18
|
def initialize(src_path, owner)
|
19
19
|
if !(self.class.is_valid_src_path?(src_path))
|
20
|
-
raise ArgumentError.new
|
20
|
+
raise ArgumentError.new("'#{src_path}' is not a valid source path")
|
21
21
|
end
|
22
22
|
|
23
23
|
@src_path = src_path
|
@@ -33,7 +33,7 @@ module Ritsu
|
|
33
33
|
|
34
34
|
def self.validate_instance(instance)
|
35
35
|
if instances.select { |x| x.src_path == instance.src_path }.length > 0
|
36
|
-
raise ArgumentError.new
|
36
|
+
raise ArgumentError.new("source file with path '#{instance.src_path}' already exists")
|
37
37
|
end
|
38
38
|
end
|
39
39
|
|
@@ -61,7 +61,17 @@ module Ritsu
|
|
61
61
|
|
62
62
|
def update_block(block, options={})
|
63
63
|
block.contents.clear
|
64
|
-
@project.targets_sorted_by_topological_order
|
64
|
+
targets = @project.targets_sorted_by_topological_order
|
65
|
+
targets.sort! { |x,y|
|
66
|
+
if x.topological_order < y.topological_order
|
67
|
+
-1
|
68
|
+
elsif x.topological_order > y.topological_order
|
69
|
+
1
|
70
|
+
else
|
71
|
+
x.name <=> y.name
|
72
|
+
end
|
73
|
+
}
|
74
|
+
targets.each do |target|
|
65
75
|
block.contents << "ADD_SUBDIRECTORY(#{target.name})"
|
66
76
|
end
|
67
77
|
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ritsu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 15
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 5
|
9
|
-
-
|
10
|
-
version: 0.5.
|
9
|
+
- 2
|
10
|
+
version: 0.5.2
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- dragonmeteor
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2010-
|
18
|
+
date: 2010-09-11 00:00:00 +07:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
@@ -174,7 +174,6 @@ files:
|
|
174
174
|
- test/ritsu/external_library_test.rb
|
175
175
|
- test/ritsu/project_generators/default_generator_test.rb
|
176
176
|
- test/ritsu/project_test.rb
|
177
|
-
- test/ritsu/src_file_test.rb
|
178
177
|
- test/ritsu/src_files/cpp_file_test.rb
|
179
178
|
- test/ritsu/src_files/executable_cmake_lists_test.rb
|
180
179
|
- test/ritsu/src_files/header_file_test.rb
|
@@ -182,10 +181,11 @@ files:
|
|
182
181
|
- test/ritsu/src_files/shared_library_cmake_lists_test.rb
|
183
182
|
- test/ritsu/src_files/static_library_cmake_lists_test.rb
|
184
183
|
- test/ritsu/src_files/target_cmake_lists_test.rb
|
185
|
-
- test/ritsu/
|
184
|
+
- test/ritsu/src_file_test.rb
|
186
185
|
- test/ritsu/targets/executable_test.rb
|
187
186
|
- test/ritsu/targets/shared_library_test.rb
|
188
187
|
- test/ritsu/targets/static_library_test.rb
|
188
|
+
- test/ritsu/target_test.rb
|
189
189
|
- test/ritsu/template_policies_test.rb
|
190
190
|
- test/ritsu/utility/accessors_test.rb
|
191
191
|
- test/ritsu/utility/check_upon_add_set_test.rb
|
@@ -237,7 +237,6 @@ test_files:
|
|
237
237
|
- test/ritsu/external_library_test.rb
|
238
238
|
- test/ritsu/project_generators/default_generator_test.rb
|
239
239
|
- test/ritsu/project_test.rb
|
240
|
-
- test/ritsu/src_file_test.rb
|
241
240
|
- test/ritsu/src_files/cpp_file_test.rb
|
242
241
|
- test/ritsu/src_files/executable_cmake_lists_test.rb
|
243
242
|
- test/ritsu/src_files/header_file_test.rb
|
@@ -245,10 +244,11 @@ test_files:
|
|
245
244
|
- test/ritsu/src_files/shared_library_cmake_lists_test.rb
|
246
245
|
- test/ritsu/src_files/static_library_cmake_lists_test.rb
|
247
246
|
- test/ritsu/src_files/target_cmake_lists_test.rb
|
248
|
-
- test/ritsu/
|
247
|
+
- test/ritsu/src_file_test.rb
|
249
248
|
- test/ritsu/targets/executable_test.rb
|
250
249
|
- test/ritsu/targets/shared_library_test.rb
|
251
250
|
- test/ritsu/targets/static_library_test.rb
|
251
|
+
- test/ritsu/target_test.rb
|
252
252
|
- test/ritsu/template_policies_test.rb
|
253
253
|
- test/ritsu/utility/accessors_test.rb
|
254
254
|
- test/ritsu/utility/check_upon_add_set_test.rb
|