tebako 0.8.0 → 0.8.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 690c1fae126210478beca87208f26cc10aaad5b7081f41d7e25bcc994677d201
4
- data.tar.gz: 6cce9afe63c5195679c8fb31a2462a52dce5e31be005e4b1187e2c95672cb2f5
3
+ metadata.gz: d3ce7f498e5f82482a720d99b95c4f5e405c595f4ded4d5dffa5ac3030679530
4
+ data.tar.gz: 7fb7a07898f02dad4bcffe7f058c142311f6c9873dfb1accb460cd9442390064
5
5
  SHA512:
6
- metadata.gz: e507d6cb7f1cae51c154c10678a14f2954bca20876950979d3c47d9cccbce098e62bfc11f0a1d0514e3de49bf5f51dc5c9acad842a34ea30bddcf1db3a481d70
7
- data.tar.gz: cf04ee58de3be8691c9f1e949707f5161d76fd0b056f039c6aa9b5cfd1261978d7458714810e7d5a62c4e73bb4eee536dc2a7a4c42646f9d283dc96c7f6f0ed3
6
+ metadata.gz: e089f8dc1edd455cb028b3ca888285b260df832228296891167bc248f2e39df650696b031c7201db0f2115e26242f2edfada4045dec1d42e82e8635cf01dd57d
7
+ data.tar.gz: 632d3337eae51876bfa9bf48a77d33a80e16b86439c66f0b406a7cf3bcb004d7f18f8a9f46bb858f8bc76cda2565078ea9883a5f1d1279ef6e3c80ff3f2808e0
data/CMakeLists.txt CHANGED
@@ -193,18 +193,18 @@ set(RUBY_STASH_DIR ${DEPS}/stash_${RUBY_VER})
193
193
  string(SUBSTRING ${RUBY_VER} 0 3 RUBY_VER_BASE)
194
194
  string(CONCAT RUBY_API_VER ${RUBY_VER_BASE} ".0")
195
195
 
196
- if(DWARFS_PRELOAD)
197
- def_ext_prj_t(LIBDWARFS_WR "0.5.5" "7bf8e5b4432f35b65f6034f614067c2018995c1bebaf935e8cdddc1a3e045c01")
198
-
199
- string(REGEX REPLACE "^([0-9]+)\\.([0-9]+)\\.([0-9]+).*" "\\1;\\2;\\3" LIBDWARFS_WR_VER_COMPONENTS ${LIBDWARFS_WR_VER})
200
-
201
- list(GET LIBDWARFS_WR_VER_COMPONENTS 0 LIBDWARFS_WR_VER_MAJOR)
202
- list(GET LIBDWARFS_WR_VER_COMPONENTS 1 LIBDWARFS_WR_VER_MINOR)
203
- list(GET LIBDWARFS_WR_VER_COMPONENTS 2 LIBDWARFS_WR_VER_PATCH)
204
- set (LIBDWARFS_WR_VER_M ${LIBDWARFS_WR_VER_MAJOR}.${LIBDWARFS_WR_VER_MINOR}.${LIBDWARFS_WR_VER_PATCH})
205
- else(DWARFS_PRELOAD)
206
- def_ext_prj_g(DWARFS_WR "v0.5.5")
207
- endif(DWARFS_PRELOAD)
196
+ #if(DWARFS_PRELOAD)
197
+ # def_ext_prj_t(LIBDWARFS_WR "0.5.8" "7bf8e5b4432f35b65f6034f614067c2018995c1bebaf935e8cdddc1a3e045c01")
198
+ #
199
+ # string(REGEX REPLACE "^([0-9]+)\\.([0-9]+)\\.([0-9]+).*" "\\1;\\2;\\3" LIBDWARFS_WR_VER_COMPONENTS ${LIBDWARFS_WR_VER})
200
+ #
201
+ # list(GET LIBDWARFS_WR_VER_COMPONENTS 0 LIBDWARFS_WR_VER_MAJOR)
202
+ # list(GET LIBDWARFS_WR_VER_COMPONENTS 1 LIBDWARFS_WR_VER_MINOR)
203
+ # list(GET LIBDWARFS_WR_VER_COMPONENTS 2 LIBDWARFS_WR_VER_PATCH)
204
+ # set (LIBDWARFS_WR_VER_M ${LIBDWARFS_WR_VER_MAJOR}.${LIBDWARFS_WR_VER_MINOR}.${LIBDWARFS_WR_VER_PATCH})
205
+ #else(DWARFS_PRELOAD)
206
+ def_ext_prj_g(DWARFS_WR "v0.5.8")
207
+ #endif(DWARFS_PRELOAD)
208
208
 
209
209
  set(LIBYAML_RUBY_OPTION "")
210
210
  if(${RUBY_VER} VERSION_LESS "3.2.0")
data/Gemfile CHANGED
@@ -29,7 +29,3 @@ source "https://rubygems.org"
29
29
 
30
30
  # Specify your gem's dependencies in tebako.gemspec
31
31
  gemspec
32
- gem "hoe"
33
- gem "minitest"
34
- gem "rubocop", "~> 1.52"
35
- gem "rubocop-rubycw"
data/README.adoc CHANGED
@@ -10,7 +10,8 @@ Platform tests on Cirrus:
10
10
  image:https://api.cirrus-ci.com/github/tamatebako/tebako.svg?branch=main&task=ubuntu-aarch64["Ubuntu aarch64", link="https://cirrus-ci.com/github/tamatebako/tebako"]
11
11
 
12
12
  Quality:
13
- image:https://github.com/tamatebako/tebako/actions/workflows/lint.yml/badge.svg["lint", link="https://github.com/tamatebako/tebako/actions/workflows/lint.yml"]
13
+ image:https://github.com/tamatebako/tebako/actions/workflows/lint-and-rspec.yml/badge.svg["lint and rspec", link="https://github.com/tamatebako/tebako/actions/workflows/lint-and-rspec.yml"]
14
+ image:https://codecov.io/gh/tamatebako/tebako/graph/badge.svg?token=XD3emQ5qsY["Tebako cli rspec coverage", link="https://codecov.io/gh/tamatebako/tebako"]
14
15
 
15
16
  == Purpose
16
17
 
@@ -86,8 +87,8 @@ with debug information unstripped. You can opt to run 'strip -S' manually, it mo
86
87
 
87
88
  | 2.7.8 | Linux, macOS
88
89
  | 3.0.7 | Linux, macOS
89
- | 3.1.{4,5,6} | Linux, macOS, Windows
90
- | 3.2.{3,4} | Linux, macOS, Windows
90
+ | 3.1.6 | Linux, macOS, Windows
91
+ | 3.2.4 | Linux, macOS, Windows
91
92
  | 3.3.{3,4} | Linux, macOS, Windows
92
93
 
93
94
  |===
@@ -232,8 +233,6 @@ Displays the Tebako version.
232
233
  Displays the help message.
233
234
 
234
235
 
235
-
236
-
237
236
  == Usage
238
237
 
239
238
  === General
@@ -291,9 +290,6 @@ docker run -v <application_folder>:/mnt/w \
291
290
  tebako {command} {parameters}
292
291
  ----
293
292
 
294
-
295
-
296
-
297
293
  ==== Packaging from outside the container
298
294
 
299
295
  To package your application from outside the container, just run a single Docker
@@ -518,6 +514,40 @@ correct version.
518
514
  Run the following command prior to using Tebako, or add it into your shell
519
515
  profile.
520
516
 
517
+ ====== jemalloc Library Build
518
+
519
+ The `libdwarfs` build script creates an additional jemalloc installation on macOS. This is done to satisfy the magic applied by folly during linking but uses a static library.
520
+ If the library is created in an emulated environment (QEMU, Rosetta, etc.), there are known issues (link:https://github.com/jemalloc/jemalloc/issues/1997[jemalloc issue #1997]) where jemalloc incorrectly defines the number of significant virtual address bits (lg-vaddr parameter).
521
+
522
+ These issues can be fixed by explicitly setting the `--with-lg-vaddr` parameter for the jemalloc build. We decided not to automate this since we do not feel that we can provide reasonable test coverage. Instead, our build script accepts the `LG_VADDR` environment variable and passes it to the jemalloc build as `--with-lg-vaddr=${LG_VADDR}`.
523
+
524
+ The `LG_VADDR` parameter specifies the number of significant virtual address bits, which can vary based on the CPU architecture and emulation status.
525
+
526
+ Simple script to set `LG_VADDR`. Please note that it is provided for illustration only.
527
+
528
+ [source,sh]
529
+ ----
530
+ #!/bin/bash
531
+
532
+ # Check the CPU architecture
533
+ ARCH=$(uname -m)
534
+
535
+ # Check if running under Rosetta 2 emulation
536
+ if [[ "$ARCH" == "x86_64" && $(sysctl -n sysctl.proc_translated) == "1" ]]; then
537
+ echo "Running on Apple Silicon under Rosetta 2 emulation"
538
+ export LG_VADDR=39
539
+ elif [[ "$ARCH" == "arm64" ]]; then
540
+ echo "Running on Apple Silicon"
541
+ export LG_VADDR=39
542
+ else
543
+ echo "Running on Intel Silicon"
544
+ export LG_VADDR=48
545
+ fi
546
+
547
+ echo "Setting lg-vaddr to $LG_VADDR"
548
+ ----
549
+
550
+
521
551
  [source,sh]
522
552
  ----
523
553
  export PATH="$(brew --prefix bison)/bin:$PATH"
@@ -625,7 +655,8 @@ tebako press \
625
655
  [-R|--Ruby=<ruby-version>] \
626
656
  [-o|--output=<packaged-file-name>] \
627
657
  [-l|--log-level=<error|warn|debug|trace>] \
628
- [-D|--devmode]
658
+ [-D|--devmode] \
659
+ [-t|--tebafile=<path-to-tebafile>]
629
660
  ----
630
661
 
631
662
  Where:
@@ -634,7 +665,7 @@ Where:
634
665
  the Tebako root folder (see details in the Tebako Root Folder Selection section)
635
666
 
636
667
  `Ruby`::
637
- This parameter defines Ruby version that will be packaged (optional, defaults to
668
+ this parameter defines Ruby version that will be packaged (optional, defaults to
638
669
  `3.1.6`)
639
670
 
640
671
  `<project-root>`::
@@ -651,11 +682,16 @@ the output file name (optional, defaults to `<current folder>/<entry point base
651
682
  logging level for the Tebako built-in memory filesystem driver
652
683
  (optional, defaults to `error`)
653
684
 
685
+ `tebafile`::
686
+ the tebako configuration file (optional, defaults to `$PWD/.tebako.yml`).
687
+ Please refer to the separate section below for tebafile description.
688
+
654
689
  `devmode`:: flag that activates development mode, in which Tebako's cache and
655
690
  packaging consistency checks are relaxed.
656
691
  +
657
- NOTE: Development mode is *not intended for production use* and should only be
658
- used during development.
692
+ NOTES:
693
+ * Development mode is *not intended for production use* and should only be used during development.
694
+ * `entry-point` and `project-root-folder` are required parameters and may be provided either via command-line or in `tebafile`.
659
695
 
660
696
  [example]
661
697
  ====
@@ -690,16 +726,21 @@ based on `tebako press` may create inconsistent environment upon restore.
690
726
  $ tebako setup \
691
727
  [-p|--prefix=<tebako-root-folder>] \
692
728
  [-R|--Ruby=<ruby-version>] \
693
- [-D|--devmode]
729
+ [-D|--devmode] \
730
+ [-t|--tebafile=<path-to-tebafile>]
694
731
  ----
695
732
 
696
733
  Where:
697
734
 
698
735
  `<tebako-root-folder>`:: the Tebako root folder (see details in the Tebako Root Folder Selection section)
699
736
 
700
- `Ruby` parameter defines Ruby version that will be packaged (optional, defaults to 3.1.6)
737
+ `Ruby`:: parameter defines Ruby version that will be packaged (optional, defaults to 3.1.6)
701
738
 
702
- `devmode` flag activates development mode, in which Tebako's cache and packaging consistency checks are relaxed.
739
+ `tebafile`::
740
+ the tebako configuration file (optional, defaults to `$PWD/.tebako.yml`).
741
+ Please refer to the separate section below for tebafile description.
742
+
743
+ `devmode`:: flag activates development mode, in which Tebako's cache and packaging consistency checks are relaxed.
703
744
  Please note that this mode is not intended for production use and should only be used during development.
704
745
 
705
746
  ==== Clean
@@ -712,13 +753,18 @@ Normally you do not need to do it since tebako packager optimizes artifacts life
712
753
  [source,sh]
713
754
  ----
714
755
  $ tebako clean \
715
- [-p|--prefix=<tebako-root-folder>]
756
+ [-p|--prefix=<tebako-root-folder>] \
757
+ [-t|--tebafile=<path-to-tebafile>]
716
758
  ----
717
759
 
718
760
  Where:
719
761
 
720
762
  `<tebako-root-folder>`:: the Tebako root folder (see details in the Tebako Root Folder Selection section)
721
763
 
764
+ `tebafile`::
765
+ the tebako configuration file (optional, defaults to `$PWD/.tebako.yml`).
766
+ Please refer to the separate section below for tebafile description.
767
+
722
768
  [example]
723
769
  ====
724
770
  [source,sh]
@@ -743,7 +789,9 @@ NOTE: Compiled DwarFS libraries are not cleaned.
743
789
  ----
744
790
  $ tebako clean_ruby
745
791
  [-p|--prefix=<tebako-root-folder>] \
746
- [-R|--Ruby=<ruby-version>]
792
+ [-R|--Ruby=<ruby-version>] \
793
+ [-t|--tebafile=<path-to-tebafile>]
794
+
747
795
  ----
748
796
 
749
797
  Where:
@@ -754,6 +802,10 @@ the Tebako setup folder (optional, defaults to current folder)
754
802
  `Ruby`::
755
803
  defines Ruby version that will cleaned (optional, cleans all versions by default)
756
804
 
805
+ `tebafile`::
806
+ the tebako configuration file (optional, defaults to `$PWD/.tebako.yml`).
807
+ Please refer to the separate section below for tebafile description.
808
+
757
809
  [example]
758
810
  ====
759
811
  [source,sh]
@@ -772,6 +824,26 @@ as a cache key in CI/CD pipelines.
772
824
  $ tebako hash
773
825
  ----
774
826
 
827
+ === Tebako configuration file
828
+
829
+ It is possible to provide all or some options for the `tebako setup/press/clean/clean_ruby` commands via Tebako configuration file ('tebafile').
830
+ Tebafile is a YAML file with a single section 'options'. The options are the same as long names for the command line. For, example for the prefix option
831
+
832
+ [source]
833
+ ----
834
+ -p|--prefix=<tebako-root-folder>
835
+ ----
836
+ the key in the YAML file would be 'prefix'.
837
+
838
+ Below is an example tebafile that sets values for prefix and Ruby options
839
+ [source,yaml]
840
+ ----
841
+ options:
842
+ prefix: /tmp/tebako
843
+ Ruby: 3.2.4
844
+ ----
845
+
846
+ Please note that the options provided on the command line have preference over tebafile settings.
775
847
 
776
848
  === Image extraction
777
849
 
data/Rakefile CHANGED
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- # Copyright (c) 2023 [Ribose Inc](https://www.ribose.com).
3
+ # Copyright (c) 2023-2024 [Ribose Inc](https://www.ribose.com).
4
4
  # All rights reserved.
5
5
  # This file is a part of tebako
6
6
  #
@@ -27,10 +27,12 @@
27
27
 
28
28
  require "bundler/gem_tasks"
29
29
  require "rubocop/rake_task"
30
+ require "rspec/core/rake_task"
30
31
 
31
32
  RuboCop::RakeTask.new
33
+ RSpec::Core::RakeTask.new(:spec)
32
34
 
33
- task default: %i[rubocop]
35
+ task default: %i[rubocop spec]
34
36
 
35
37
  desc "Generate version.txt"
36
38
  task "generate_version_txt" do
data/common.env CHANGED
@@ -1,5 +1,5 @@
1
1
  BUILD_TYPE=Release
2
2
  DEPS=deps
3
3
  INCBIN_TAG=348e36b
4
- DWARFS_WR_TAG=v0.5.5
4
+ DWARFS_WR_TAG=v0.5.8
5
5
  RUBY_VER=3.1.6
data/lib/tebako/cli.rb CHANGED
@@ -40,7 +40,7 @@ require_relative "version"
40
40
  # Tebako - an executable packager
41
41
  # Implementation of tebako command-line interface
42
42
  module Tebako
43
- OPTIONS_FILE = ".tebako.yml"
43
+ DEFAULT_TEBAFILE = ".tebako.yml"
44
44
  # Tebako packager front-end
45
45
  class Cli < Thor
46
46
  package_name "Tebako"
@@ -48,7 +48,8 @@ module Tebako
48
48
  desc: "A path to tebako packaging environment, '~/.tebako' ('$HOME/.tebako') by default"
49
49
  class_option :devmode, type: :boolean, aliases: "-D", required: false,
50
50
  desc: "Developer mode, please do not use if unsure"
51
-
51
+ class_option :tebafile, type: :string, aliases: "-t", required: false,
52
+ desc: "tebako configuration file 'tebafile', '$PWD/.tebako.yml' by default"
52
53
  desc "clean", "Clean tebako packaging environment"
53
54
  def clean
54
55
  clean_cache
@@ -123,35 +124,19 @@ module Tebako
123
124
 
124
125
  def options
125
126
  original_options = super
126
-
127
- return original_options unless File.exist?(OPTIONS_FILE)
128
-
129
- defaults = ::YAML.load_file(OPTIONS_FILE) || {}
130
- Thor::CoreExt::HashWithIndifferentAccess.new(defaults.merge(original_options))
127
+ tebafile = original_options["tebafile"].nil? ? DEFAULT_TEBAFILE : original_options["tebafile"]
128
+ if File.exist?(tebafile)
129
+ Thor::CoreExt::HashWithIndifferentAccess.new(options_from_tebafile(tebafile).merge(original_options))
130
+ else
131
+ puts "Warning: Tebako configuration file '#{tebafile}' not found." unless original_options["tebafile"].nil?
132
+ original_options
133
+ end
131
134
  end
132
135
  end
133
136
 
134
- private
135
-
136
137
  no_commands do
137
- def do_press
138
- cfg_cmd = "cmake -DSETUP_MODE:BOOLEAN=OFF #{cfg_options} #{press_options}"
139
- build_cmd = "cmake --build #{output} --target tebako --parallel #{Etc.nprocessors}"
140
- merged_env = ENV.to_h.merge(b_env)
141
- Tebako.packaging_error(103) unless system(merged_env, cfg_cmd)
142
- Tebako.packaging_error(104) unless system(merged_env, build_cmd)
143
- end
144
-
145
- def do_setup
146
- cfg_cmd = "cmake -DSETUP_MODE:BOOLEAN=ON #{cfg_options}"
147
- build_cmd = "cmake --build \"#{output}\" --target setup --parallel #{Etc.nprocessors}"
148
- merged_env = ENV.to_h.merge(b_env)
149
- Tebako.packaging_error(101) unless system(merged_env, cfg_cmd)
150
- Tebako.packaging_error(102) unless system(merged_env, build_cmd)
151
- end
138
+ include Tebako::CliHelpers
139
+ include Tebako::CliRubies
152
140
  end
153
-
154
- include Tebako::CliHelpers
155
- include Tebako::CliRubies
156
141
  end
157
142
  end
@@ -55,31 +55,47 @@ module Tebako
55
55
  # So we have to use \"xxx\"
56
56
  @cfg_options ||=
57
57
  "-DCMAKE_BUILD_TYPE=Release -DRUBY_VER:STRING=\"#{ruby_ver}\" -DRUBY_HASH:STRING=\"#{ruby_hash}\" " \
58
- "-DDEPS:STRING=\"#{deps}\" -G \"#{m_files}\" -B \"#{output}\" -S \"#{source}\""
58
+ "-DDEPS:STRING=\"#{deps}\" -G \"#{m_files}\" -B \"#{output_folder}\" -S \"#{source}\""
59
59
  end
60
60
 
61
61
  def clean_cache
62
62
  puts "Cleaning tebako packaging environment"
63
63
  # Using File.join(deps, "") to ensure that the slashes are appropriate
64
- FileUtils.rm_rf([File.join(deps, ""), File.join(output, "")], secure: true)
64
+ FileUtils.rm_rf([File.join(deps, ""), File.join(output_folder, "")], secure: true)
65
65
  end
66
66
 
67
67
  def clean_output
68
68
  puts "Cleaning CMake cache and Ruby build files"
69
- # Using File.join(output, "") to ensure that the slashes are appropriate
70
69
 
71
70
  nmr = "src/_ruby_*"
72
71
  nms = "stash_*"
73
72
  FileUtils.rm_rf(Dir.glob(File.join(deps, nmr)), secure: true)
74
73
  FileUtils.rm_rf(Dir.glob(File.join(deps, nms)), secure: true)
75
74
 
76
- FileUtils.rm_rf(File.join(output, ""), secure: true)
75
+ # Using File.join(output_folder, "") to ensure that the slashes are appropriate
76
+ FileUtils.rm_rf(File.join(output_folder, ""), secure: true)
77
77
  end
78
78
 
79
79
  def deps
80
80
  @deps ||= File.join(prefix, "deps")
81
81
  end
82
82
 
83
+ def do_press
84
+ cfg_cmd = "cmake -DSETUP_MODE:BOOLEAN=OFF #{cfg_options} #{press_options}"
85
+ build_cmd = "cmake --build #{output_folder} --target tebako --parallel #{Etc.nprocessors}"
86
+ merged_env = ENV.to_h.merge(b_env)
87
+ Tebako.packaging_error(103) unless system(merged_env, cfg_cmd)
88
+ Tebako.packaging_error(104) unless system(merged_env, build_cmd)
89
+ end
90
+
91
+ def do_setup
92
+ cfg_cmd = "cmake -DSETUP_MODE:BOOLEAN=ON #{cfg_options}"
93
+ build_cmd = "cmake --build \"#{output_folder}\" --target setup --parallel #{Etc.nprocessors}"
94
+ merged_env = ENV.to_h.merge(b_env)
95
+ Tebako.packaging_error(101) unless system(merged_env, cfg_cmd)
96
+ Tebako.packaging_error(102) unless system(merged_env, build_cmd)
97
+ end
98
+
83
99
  def ensure_version_file
84
100
  version_file_path = File.join(deps, E_VERSION_FILE)
85
101
 
@@ -128,8 +144,20 @@ module Tebako
128
144
  end
129
145
  # rubocop:enable Metrics/MethodLength
130
146
 
131
- def output
132
- @output ||= File.join(prefix, "o")
147
+ def options_from_tebafile(tebafile)
148
+ ::YAML.load_file(tebafile)["options"] || {}
149
+ rescue Psych::SyntaxError => e
150
+ puts "Warning: The tebafile '#{tebafile}' contains invalid YAML syntax."
151
+ puts e.message
152
+ {}
153
+ rescue StandardError => e
154
+ puts "An unexpected error occurred while loading the tebafile '#{tebafile}'."
155
+ puts e.message
156
+ {}
157
+ end
158
+
159
+ def output_folder
160
+ @output_folder ||= File.join(prefix, "o")
133
161
  end
134
162
 
135
163
  def package
@@ -88,9 +88,23 @@ module Tebako
88
88
  SUBST
89
89
  }.freeze
90
90
 
91
- # DARWIN_CONFIGURE_PATCH = {
92
- # "EXTDLDFLAGS=\"-bundle_loader '\\$(BUILTRUBY)'\"" => ""
93
- # }.freeze
91
+ # The logic for statically linked extensions is broken entirely in the latest Ruby versions.
92
+ # The code below looks reasonble - we do not set -bundle_loader when building with -with-static-ext option
93
+ # However Gems bundled with Ruby just ignore with-static-ext option and build extensions as shared libraries
94
+ # So the -bundler_loader option is required for them to link.
95
+ # It is strange that it is disabled in any case because this option does not create any issues for static
96
+ # libraries.
97
+ # ---------------------------------------------------
98
+ # elif test "x$EXTSTATIC" = x
99
+ # then :
100
+ #
101
+ # # When building exts as bundles, a mach-o bundle needs to know its loader
102
+ # # program to bind symbols from the ruby executable
103
+ # EXTDLDFLAGS="-bundle_loader '\$(BUILTRUBY)'"
104
+
105
+ DARWIN_CONFIGURE_PATCH = {
106
+ "elif test \"x$EXTSTATIC\" = x" => "elif true"
107
+ }.freeze
94
108
 
95
109
  OPENSSL_EXTCONF_RB_SUBST = <<~SUBST
96
110
  # Start of tebako patch
@@ -137,11 +151,7 @@ module Tebako
137
151
  patch_map = get_base_patch_map(mount_point)
138
152
 
139
153
  # ....................................................
140
- # Fixing (bypassing) configure script bug where a variable is used before initialization
141
- # On MacOS it generates bod EXTDLDFLAGS WITH -bundle_loader <missing parameter>
142
- # However, it loooks likes EXTDLDFLAGS are just redundant for final Ruby linkage, so we are
143
- # just removing it on pass 2 (at least for now)
144
- # patch_map.store("configure", DARWIN_CONFIGURE_PATCH) if ostype =~ /darwin/
154
+ patch_map.store("configure", DARWIN_CONFIGURE_PATCH) if ostype =~ /darwin/
145
155
 
146
156
  # ....................................................
147
157
  # autoload :OpenSSL, "openssl"
@@ -34,13 +34,10 @@ module Tebako
34
34
  module PatchLibraries
35
35
  class << self
36
36
  # rubocop:disable Style/WordArray
37
-
38
- # NOTE: folly provides build-in implementation of jemalloc
39
-
40
37
  DARWIN_BREW_LIBS = [
41
- ["zlib", "z"], ["gdbm", "gdbm"], ["readline", "readline"], ["libffi", "ffi"],
42
- ["ncurses", "ncurses"], ["fmt", "fmt"], ["lz4", "lz4"], ["xz", "lzma"],
43
- ["libyaml", "yaml"], ["boost", "boost_chrono"], ["double-conversion", "double-conversion"]
38
+ ["zlib", "z"], ["gdbm", "gdbm"], ["readline", "readline"], ["libffi", "ffi"],
39
+ ["ncurses", "ncurses"], ["fmt", "fmt"], ["lz4", "lz4"], ["xz", "lzma"],
40
+ ["libyaml", "yaml"], ["boost", "boost_chrono"], ["double-conversion", "double-conversion"]
44
41
  ].freeze
45
42
 
46
43
  DARWIN_BREW_LIBS_PRE_31 = [["openssl@1.1", "ssl"], ["openssl@1.1", "crypto"]].freeze
@@ -26,5 +26,5 @@
26
26
  # POSSIBILITY OF SUCH DAMAGE.
27
27
 
28
28
  module Tebako
29
- VERSION = "0.8.0"
29
+ VERSION = "0.8.2"
30
30
  end
data/src/tebako-main.cpp CHANGED
@@ -145,6 +145,8 @@ extern "C" int tebako_main(int* argc, char*** argv) {
145
145
  // Nested error, no recovery :(
146
146
  }
147
147
  }
148
+
149
+ // tebako_chdir("/__tebako_memfs__/local");
148
150
  }
149
151
  return ret;
150
152
  }
data/tebako.gemspec CHANGED
@@ -51,7 +51,7 @@ Gem::Specification.new do |spec|
51
51
  spec.files = Dir.chdir(File.expand_path(__dir__)) do
52
52
  `git ls-files --recurse-submodules -z`.split("\x0").reject do |f|
53
53
  (f == __FILE__) ||
54
- f.match(%r{\A(?:(?:tests|tests-2|features|deps|output|common\.env)/|\.(?:git|cirrus|tebako|rubocop))})
54
+ f.match(%r{\A(?:(?:tests|tests-2|spec|deps|output|common\.env)/|\.(?:git|rspec|cirrus|tebako|rubocop))})
55
55
  end
56
56
  end
57
57
 
@@ -63,4 +63,12 @@ Gem::Specification.new do |spec|
63
63
 
64
64
  spec.add_dependency "thor", "~> 1.2"
65
65
  spec.add_dependency "yaml", "~> 0.2.1"
66
+
67
+ spec.add_development_dependency "hoe"
68
+ spec.add_development_dependency "minitest"
69
+ spec.add_development_dependency "rspec", "~> 3.2"
70
+ spec.add_development_dependency "rubocop", "~> 1.52"
71
+ spec.add_development_dependency "rubocop-rubycw"
72
+ spec.add_development_dependency "simplecov"
73
+ spec.add_development_dependency "simplecov-cobertura"
66
74
  end
data/version.txt CHANGED
@@ -1 +1 @@
1
- 0.8.0
1
+ 0.8.2
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tebako
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.0
4
+ version: 0.8.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-07-27 00:00:00.000000000 Z
11
+ date: 2024-08-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor
@@ -38,6 +38,104 @@ dependencies:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: 0.2.1
41
+ - !ruby/object:Gem::Dependency
42
+ name: hoe
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: minitest
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: rspec
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: '3.2'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: '3.2'
83
+ - !ruby/object:Gem::Dependency
84
+ name: rubocop
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - "~>"
88
+ - !ruby/object:Gem::Version
89
+ version: '1.52'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - "~>"
95
+ - !ruby/object:Gem::Version
96
+ version: '1.52'
97
+ - !ruby/object:Gem::Dependency
98
+ name: rubocop-rubycw
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
111
+ - !ruby/object:Gem::Dependency
112
+ name: simplecov
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ">="
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ">="
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
125
+ - !ruby/object:Gem::Dependency
126
+ name: simplecov-cobertura
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - ">="
130
+ - !ruby/object:Gem::Version
131
+ version: '0'
132
+ type: :development
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - ">="
137
+ - !ruby/object:Gem::Version
138
+ version: '0'
41
139
  description: |
42
140
  Tebako is an executable packager. It packages a set of files into a single
43
141
  executable binary that allows a user to run a selected file from the
@@ -115,7 +213,7 @@ licenses:
115
213
  metadata:
116
214
  homepage_uri: https://github.com/tamatebako/tebako
117
215
  source_code_uri: https://github.com/tamatebako/tebako
118
- post_install_message:
216
+ post_install_message:
119
217
  rdoc_options: []
120
218
  require_paths:
121
219
  - cmake
@@ -139,8 +237,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
139
237
  - !ruby/object:Gem::Version
140
238
  version: '0'
141
239
  requirements: []
142
- rubygems_version: 3.5.11
143
- signing_key:
240
+ rubygems_version: 3.3.27
241
+ signing_key:
144
242
  specification_version: 4
145
243
  summary: Packager for Ruby executables
146
244
  test_files: []