liblouis-rb 0.1.0 → 0.1.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b811567619dd61b39776d29012570b85350c6deb556af5013f158a71d157f1f6
4
- data.tar.gz: 376cdfb35cd002795abe8c3578f991590399290e35c1832e8de761a4045ee874
3
+ metadata.gz: f5092c42026ace0663c5cf13dabc59450690dfeb3b7e510093cb17d99807c86f
4
+ data.tar.gz: 0ba100f40dcd5f31c1f6c38bd7b7e274f07d1b56d4fe0b618478091f22ee18af
5
5
  SHA512:
6
- metadata.gz: d7c9f3e92b3a845f9a6e289a38bbb6cf9d772c2de4b44581ee4392580a0ea4d97f0cfaffc4a14e32f4eb27e53e07562e2c52f1b5ed6886b8495543a7d62b135f
7
- data.tar.gz: f2121ccef2047699c4bbd2b8888061b941c01dcd1f2d810965d66f9e1ddb1af4dcc2bc465ff2722b03f31871a76d9dca297cf2d4a09eca82b58f36213990ba00
6
+ metadata.gz: 6b41a35231e8c4c1a5969b1d4b5449f9f25efd5fb3af9c8a08d6865d8cdf60d0e95cf2822bb82233815c6e3fd4924647200a9b6fece3afd166b12545cdc39637
7
+ data.tar.gz: 9c5a163c7314a71b6bb09091dbdb77366fc219f5c153833cb135fc31b4360993bd9113dbd5b139c5abe66b4d1ad8d11555f8847b635f66eac7ccfec9f7229ca3
data/README.md CHANGED
@@ -20,7 +20,7 @@ From a Git checkout:
20
20
  ```sh
21
21
  git submodule update --init --recursive
22
22
  rake gem
23
- gem install ./pkg/liblouis-rb-0.1.0.gem
23
+ gem install ./pkg/liblouis-rb-0.1.1.gem
24
24
  ```
25
25
 
26
26
  The gem includes Liblouis and its tables.
@@ -16,6 +16,11 @@ end
16
16
  liblouis_version = File.binread(configure_source)[/AC_INIT\(\[Liblouis\],\s*\[([0-9]+\.[0-9]+\.[0-9]+)\]/, 1]
17
17
  abort "Could not read the Liblouis version from configure.ac" unless liblouis_version
18
18
 
19
+ # Strict C11 hides the POSIX and BSD interfaces used by Liblouis on glibc.
20
+ $defs << "-D_DEFAULT_SOURCE=1" if RbConfig::CONFIG["host_os"].match?(/linux/)
21
+ append_cflags("-std=c11")
22
+ have_header("strings.h")
23
+
19
24
  # Encode paths as C strings in the header so the shell never splits them.
20
25
  def c_string(value)
21
26
  '"' + value.b.bytes.map { |byte| format("\\%03o", byte) }.join + '"'
@@ -39,6 +44,9 @@ File.write(
39
44
  #define LIBLOUIS_RB_TABLES_DIR #{c_string(TABLES_PATH)}
40
45
  #define LIBLOUIS_RB_DATA_DIR #{c_string(DATA_PATH)}
41
46
  #include <stdbool.h>
47
+ #ifdef HAVE_STRINGS_H
48
+ #include <strings.h>
49
+ #endif
42
50
  #endif
43
51
  CONFIG
44
52
  )
@@ -69,5 +77,4 @@ $srcs = extension_sources + liblouis_sources
69
77
  $INCFLAGS = "-I$(srcdir) -I$(srcdir)/../../vendor/liblouis/liblouis #{$INCFLAGS}"
70
78
  $defs << "-DWIDECHARS_ARE_UCS4=1"
71
79
 
72
- append_cflags("-std=c11")
73
80
  create_makefile("liblouis")
@@ -148,7 +148,7 @@ Init_liblouis(void)
148
148
  ll_eError = rb_define_class_under(ll_mLibLouis, "Error", rb_eStandardError);
149
149
  ll_eTranslationError = rb_define_class_under(ll_mLibLouis, "TranslationError", ll_eError);
150
150
 
151
- rb_define_const(ll_mLibLouis, "VERSION", rb_obj_freeze(rb_usascii_str_new_cstr("0.1.0")));
151
+ rb_define_const(ll_mLibLouis, "VERSION", rb_obj_freeze(rb_usascii_str_new_cstr("0.1.1")));
152
152
 
153
153
  rb_define_module_function(ll_mLibLouis, "version", ll_version, 0);
154
154
  rb_define_module_function(ll_mLibLouis, "table_path", ll_table_path, 0);
data/liblouis-rb.gemspec CHANGED
@@ -9,7 +9,7 @@ end
9
9
 
10
10
  Gem::Specification.new do |spec|
11
11
  spec.name = "liblouis-rb"
12
- spec.version = "0.1.0"
12
+ spec.version = "0.1.1"
13
13
  spec.authors = ["Dawid Pieper", "liblouis contributors"]
14
14
  spec.summary = "Native Ruby bindings for Liblouis"
15
15
  spec.description = <<~DESCRIPTION.strip
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: liblouis-rb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dawid Pieper