ots 0.5.1 → 0.5.2

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # OTS
2
2
 
3
- ots is an interface to libots - The [open text summarizer](http://libots.sourceforge.net/).
3
+ ots is an interface to libots - The [Open Text Summarizer](http://libots.sourceforge.net/).
4
4
 
5
5
  ## Dependencies
6
6
 
@@ -40,6 +40,11 @@ ots is an interface to libots - The [open text summarizer](http://libots.sourcef
40
40
  # install glib
41
41
  brew install glib
42
42
 
43
+ # setup the environment variables in order to install ots
44
+ export CPPFLAGS=-I/usr/local/Cellar/glib/2.30.2/include/glib-2.0/
45
+ export LDFLAGS=-L/usr/local/Cellar/glib/2.30.2/lib/
46
+ export PKG_CONFIG_PATH=/usr/local/Cellar/glib/2.30.2/lib/pkgconfig/
47
+
43
48
  # install ots
44
49
  gem install ots
45
50
 
@@ -73,7 +78,7 @@ ots is an interface to libots - The [open text summarizer](http://libots.sourcef
73
78
  article.summarize(percent: 50)
74
79
  article.summarize(sentences: 1)
75
80
 
76
- OTS.languages #=> list of supported languages dictionaries baked-in to libots
81
+ OTS.languages #=> list of supported language dictionaries baked-in to libots
77
82
  ```
78
83
 
79
84
  ## See Also
@@ -16,10 +16,20 @@ if glib_ldflags.empty?
16
16
  end
17
17
 
18
18
  dir = File.expand_path(File.dirname(__FILE__) + '/../dictionaries')
19
- $CFLAGS = glib_cflags + %Q{ -I/usr/include/libxml2 -DDICTIONARY_DIR='"#{dir}/"'}
20
- $LDFLAGS = glib_ldflags
19
+ $CFLAGS = glib_cflags + %Q{ -Ilibots -I/usr/include/libxml2 -DDICTIONARY_DIR='"#{dir}/"'}
20
+ $LDFLAGS = glib_ldflags + %Q{ -Llibots}
21
21
 
22
- find_library('glib-2.0', 'main')
23
- find_library('xml2', 'main')
22
+ find_library('glib-2.0', 'main') or raise "unable to find glib-2.0"
23
+ find_library('xml2', 'main') or raise "unable to find libxml2"
24
+
25
+ # ugly mkmf hack: manually assign source and object directories.
26
+ $srcs = Dir["{libots/*.c,*.c}"]
27
+ $objs = $srcs.map {|name| File.join(File.dirname(name), File.basename(name, ".c") + ".o")}
28
+
29
+ class File
30
+ def self.basename name
31
+ name
32
+ end
33
+ end
24
34
 
25
35
  create_makefile 'ots'
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -1,2 +1,2 @@
1
1
  #pragma once
2
- #define RUBY_OTS_VERSION "0.5.1"
2
+ #define RUBY_OTS_VERSION "0.5.2"
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 5
8
- - 1
9
- version: 0.5.1
8
+ - 2
9
+ version: 0.5.2
10
10
  platform: ruby
11
11
  authors:
12
12
  - Bharanee Rathna
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2012-01-11 00:00:00 +11:00
17
+ date: 2012-01-25 00:00:00 +11:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
@@ -53,23 +53,23 @@ extensions:
53
53
  extra_rdoc_files: []
54
54
 
55
55
  files:
56
- - ext/text.c
57
- - ext/grader-tf.c
58
- - ext/stemmer.c
59
- - ext/article.c
60
- - ext/grader-tc.c
61
- - ext/html.c
62
- - ext/grader.c
63
56
  - ext/ots.c
64
- - ext/relations.c
65
- - ext/parser.c
66
- - ext/dictionary.c
67
- - ext/highlighter.c
68
- - ext/wordlist.c
69
- - ext/grader-tc.h
57
+ - ext/libots/text.c
58
+ - ext/libots/grader-tf.c
59
+ - ext/libots/stemmer.c
60
+ - ext/libots/article.c
61
+ - ext/libots/grader-tc.c
62
+ - ext/libots/html.c
63
+ - ext/libots/grader.c
64
+ - ext/libots/relations.c
65
+ - ext/libots/parser.c
66
+ - ext/libots/dictionary.c
67
+ - ext/libots/highlighter.c
68
+ - ext/libots/wordlist.c
70
69
  - ext/ots.h
71
- - ext/libots.h
72
70
  - ext/version.h
71
+ - ext/libots/grader-tc.h
72
+ - ext/libots/libots.h
73
73
  - ext/extconf.rb
74
74
  - test/test_article.rb
75
75
  - test/test_ots.rb