tre_regex 0.1.1-aarch64-linux-gnu → 0.1.2-aarch64-linux-gnu

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: 906010edc1738247cd41f4dda50da7ebe05fbcb38d9bc0f3a455fff341d13951
4
- data.tar.gz: 101fdaed5bba80ff80afe42c522896d2e15bdb7bee204b75d37babc33f12de43
3
+ metadata.gz: fd3ca1c67051a33c9fccaea5945bd28944e6a7ee121d15888ec7653c97dc387d
4
+ data.tar.gz: f1045d84b2a4018cd7f1ffae4128dfe872f8b060693673fff4a4584532125603
5
5
  SHA512:
6
- metadata.gz: ce3a608ab45eea69d96cbeacbb5b7f84eff382b1c318c958343c57bd550fa6f9bf10d6cb59d5b7dad0992d851209f8bdff9ffe85bc463afe48c18a7e4c7b42f3
7
- data.tar.gz: ab62470aa39c1abd425d04c2f9c84189a405f4d2c0d1a5ee029e1b3aa1e4b0c18b9fdf131f4e708fbc086745f04ca9df0ec718114eba9b99fb8b77bb4197ef4f
6
+ metadata.gz: fb8e2595264a8269a3e9449bf681136087e12270537ab6c0106bd0e7cab792a3c8aeee4992538529a7e07dfaebcf0799b6796af6817616672b7db7e887d128fc
7
+ data.tar.gz: eb8dcf0e22afa82fd8a03a30842b44bfb9c2e2b0cde3d24eed0b57d48b56dc0706dacdaeb74f48b670cee3c0ac1d41b0060b80af6954de99463e735dfce7ad09
@@ -6,6 +6,22 @@ require 'open-uri'
6
6
  require 'net/http'
7
7
  require 'fileutils'
8
8
 
9
+ build_env = {
10
+ 'CC' => RbConfig::CONFIG['CC'],
11
+ 'CFLAGS' => RbConfig::CONFIG['CFLAGS'],
12
+ 'CPPFLAGS' => RbConfig::CONFIG['CPPFLAGS'],
13
+ 'LDFLAGS' => RbConfig::CONFIG['LDFLAGS']
14
+ }
15
+
16
+ gnu_host = RbConfig::CONFIG['host_alias']
17
+ gnu_host = RbConfig::CONFIG['host'] if gnu_host.nil? || gnu_host.empty?
18
+
19
+ # Convert 'arm64' to 'aarch64' (Apple Silicon) and 'x64' to 'x86_64' (Windows)
20
+ gnu_host = gnu_host.sub('arm64', 'aarch64').sub(/^x64/, 'x86_64')
21
+
22
+ # Pass the translated, safe name to configure
23
+ host_flag = "--host=#{gnu_host}"
24
+
9
25
  is_windows = RbConfig::CONFIG['host_os'] =~ /mingw|mswin/
10
26
  is_darwin = RbConfig::CONFIG['host_os'].include?('darwin')
11
27
 
@@ -54,15 +70,14 @@ unless Dir.exist?(tre_src_dir)
54
70
  end
55
71
 
56
72
  # Build TRE synchronously using Ruby
57
- host_flag = enable_config('cross-build') ? "--host=#{RbConfig::CONFIG['host']} " : ''
58
- RbConfig::CONFIG['SOEXT'] || RbConfig::CONFIG['DLEXT'] || (is_windows ? 'dll' : 'so')
59
73
 
60
74
  puts '========== Building TRE =========='
61
75
  Dir.chdir(tre_src_dir) do
62
- system('./utils/autogen.sh') || raise('autogen.sh failed') unless File.exist?('configure')
76
+ system(build_env, './utils/autogen.sh') || raise('autogen.sh failed') unless File.exist?('configure')
63
77
 
64
- system("./configure #{host_flag} --enable-shared --disable-static --disable-agrep") || raise('configure failed')
65
- system('make') || raise('make failed')
78
+ system(build_env, "./configure #{host_flag} --enable-shared --disable-static --disable-agrep") ||
79
+ raise('configure failed')
80
+ system(build_env, 'make') || raise('make failed')
66
81
  end
67
82
 
68
83
  puts '========== Staging Shared Library for FFI =========='
Binary file
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module TreRegex
4
- VERSION = '0.1.1'
4
+ VERSION = '0.1.2'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tre_regex
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: aarch64-linux-gnu
6
6
  authors:
7
7
  - Oleksii Vasyliev