goffice 3.1.1 → 3.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/dependency-check/Rakefile +68 -0
- data/lib/goffice.rb +1 -1
- data/lib/goffice/loader.rb +7 -4
- data/lib/goffice/version.rb +1 -1
- data/test/goffice-test-utils.rb +5 -2
- data/test/run-test.rb +6 -0
- data/test/test-data-scalar-str.rb +1 -1
- metadata +12 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cdf5849b4f57e71d04d8a5dde7ca97318322f856
|
4
|
+
data.tar.gz: e1664fb871f68e75d600a3ec66e1e6b2b20752c1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d677c3a59f7147b3ee83541dd995c54b7bfbdb2be491341a07402aca624537ab6c72770180808406cb1e061905a9b744db29208dfaedc128da16c3a9518574ea
|
7
|
+
data.tar.gz: ea2d01a9210fbade1c4793a99318cdf3d7809cd33a4c5e389e357247442247b52f08eab9eef835196ca94cacd42359f51d262ac95a4665ceb8180025f4523617
|
@@ -0,0 +1,68 @@
|
|
1
|
+
# Copyright (C) 2017 Ruby-GNOME2 Project Team
|
2
|
+
#
|
3
|
+
# This library is free software; you can redistribute it and/or
|
4
|
+
# modify it under the terms of the GNU Lesser General Public
|
5
|
+
# License as published by the Free Software Foundation; either
|
6
|
+
# version 2.1 of the License, or (at your option) any later version.
|
7
|
+
#
|
8
|
+
# This library is distributed in the hope that it will be useful,
|
9
|
+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
10
|
+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
11
|
+
# Lesser General Public License for more details.
|
12
|
+
#
|
13
|
+
# You should have received a copy of the GNU Lesser General Public
|
14
|
+
# License along with this library; if not, write to the Free Software
|
15
|
+
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
16
|
+
|
17
|
+
# Copyright (C) 2017 Ruby-GNOME2 Project Team
|
18
|
+
#
|
19
|
+
# This library is free software; you can redistribute it and/or
|
20
|
+
# modify it under the terms of the GNU Lesser General Public
|
21
|
+
# License as published by the Free Software Foundation; either
|
22
|
+
# version 2.1 of the License, or (at your option) any later version.
|
23
|
+
#
|
24
|
+
# This library is distributed in the hope that it will be useful,
|
25
|
+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
26
|
+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
27
|
+
# Lesser General Public License for more details.
|
28
|
+
#
|
29
|
+
# You should have received a copy of the GNU Lesser General Public
|
30
|
+
# License along with this library; if not, write to the Free Software
|
31
|
+
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
32
|
+
|
33
|
+
require "pkg-config"
|
34
|
+
require "native-package-installer"
|
35
|
+
|
36
|
+
case RUBY_PLATFORM
|
37
|
+
when /mingw|mswin/
|
38
|
+
task :default => "nothing"
|
39
|
+
else
|
40
|
+
task :default => "dependency:check"
|
41
|
+
end
|
42
|
+
|
43
|
+
task :nothing do
|
44
|
+
end
|
45
|
+
|
46
|
+
namespace :dependency do
|
47
|
+
desc "Check dependency"
|
48
|
+
task :check do
|
49
|
+
unless PKGConfig.check_version?("libgoffice-0.10")
|
50
|
+
goffice010_spec = {
|
51
|
+
:debian => "libgoffice-0.10-dev",
|
52
|
+
:homebrew => "goffice",
|
53
|
+
}
|
54
|
+
unless NativePackageInstaller.install(goffice08_spec)
|
55
|
+
unless PKGConfig.check_version?("libgoffice-0.8")
|
56
|
+
goffice08_spec = {
|
57
|
+
:debian => "libgoffice-0.8-dev",
|
58
|
+
:redhat => "goffice08-devel",
|
59
|
+
:homebrew => "goffice",
|
60
|
+
}
|
61
|
+
unless NativePackageInstaller.install(goffice08_spec)
|
62
|
+
exit(false)
|
63
|
+
end
|
64
|
+
end
|
65
|
+
end
|
66
|
+
end
|
67
|
+
end
|
68
|
+
end
|
data/lib/goffice.rb
CHANGED
data/lib/goffice/loader.rb
CHANGED
@@ -27,10 +27,13 @@ module GOffice
|
|
27
27
|
|
28
28
|
def define_version(repository, namespace)
|
29
29
|
major, minor, micro = repository.get_version(namespace).split(".")
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
30
|
+
version_module = Module.new do
|
31
|
+
const_set("MAJOR", Integer(major))
|
32
|
+
const_set("MINOR", Integer(minor))
|
33
|
+
micro = Integer(micro) unless micro.nil?
|
34
|
+
const_set("MICRO", micro)
|
35
|
+
end
|
36
|
+
@base_module.const_set("Version", version_module)
|
34
37
|
end
|
35
38
|
|
36
39
|
def require_libraries
|
data/lib/goffice/version.rb
CHANGED
data/test/goffice-test-utils.rb
CHANGED
@@ -17,7 +17,10 @@
|
|
17
17
|
require "test-unit"
|
18
18
|
|
19
19
|
module GOfficeTestUtils
|
20
|
-
|
21
|
-
|
20
|
+
private
|
21
|
+
def only_goffice_version(major, minor, micro=nil)
|
22
|
+
unless GOffice::Version.or_later?(major, minor, micro)
|
23
|
+
omit("Require GOffice >= #{major}.#{minor}.#{micro}")
|
24
|
+
end
|
22
25
|
end
|
23
26
|
end
|
data/test/run-test.rb
CHANGED
@@ -58,5 +58,11 @@ $LOAD_PATH.unshift(File.join(goffice_base, "test"))
|
|
58
58
|
require "goffice-test-utils"
|
59
59
|
|
60
60
|
require "goffice"
|
61
|
+
begin
|
62
|
+
GOffice.init
|
63
|
+
rescue GObjectIntrospection::RepositoryError
|
64
|
+
puts("Omit because typelib file doesn't exist: #{$!.message}")
|
65
|
+
exit(true)
|
66
|
+
end
|
61
67
|
|
62
68
|
exit Test::Unit::AutoRunner.run(true, File.join(goffice_base, "test"))
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: goffice
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.1.
|
4
|
+
version: 3.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- The Ruby-GNOME2 Project Team
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-04-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gsf
|
@@ -16,49 +16,51 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - '='
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 3.1.
|
19
|
+
version: 3.1.2
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - '='
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 3.1.
|
26
|
+
version: 3.1.2
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: gobject-introspection
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - '='
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 3.1.
|
33
|
+
version: 3.1.2
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - '='
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 3.1.
|
40
|
+
version: 3.1.2
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: gtk3
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
45
|
- - '='
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: 3.1.
|
47
|
+
version: 3.1.2
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - '='
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 3.1.
|
54
|
+
version: 3.1.2
|
55
55
|
description: Ruby/GOFFICE is a Ruby binding of GOFFICE.
|
56
56
|
email: ruby-gnome2-devel-en@lists.sourceforge.net
|
57
57
|
executables: []
|
58
|
-
extensions:
|
58
|
+
extensions:
|
59
|
+
- dependency-check/Rakefile
|
59
60
|
extra_rdoc_files: []
|
60
61
|
files:
|
61
62
|
- Rakefile
|
63
|
+
- dependency-check/Rakefile
|
62
64
|
- lib/goffice.rb
|
63
65
|
- lib/goffice/loader.rb
|
64
66
|
- lib/goffice/version.rb
|
@@ -67,7 +69,7 @@ files:
|
|
67
69
|
- test/test-data-scalar-str.rb
|
68
70
|
homepage: http://ruby-gnome2.sourceforge.jp/
|
69
71
|
licenses:
|
70
|
-
-
|
72
|
+
- LGPL-2.1+
|
71
73
|
metadata: {}
|
72
74
|
post_install_message:
|
73
75
|
rdoc_options: []
|