Work around XCode 14 issue with oj-introspect
What does this merge request do and why?
This MR adds a workaround for oj-introspect
compile error with XCode 14.
Log output
❯ gem install oj-introspect -v 0.7.0
Building native extensions. This could take a while...
ERROR: Error installing oj-introspect:
ERROR: Failed to build gem native extension.
current directory: /Users/tanle/.asdf/installs/ruby/2.7.5/lib/ruby/gems/2.7.0/gems/oj-introspect-0.7.0/ext/oj-introspect
/Users/tanle/.asdf/installs/ruby/2.7.5/bin/ruby -I /Users/tanle/.asdf/installs/ruby/2.7.5/lib/ruby/site_ruby/2.7.0 extconf.rb
creating Makefile
current directory: /Users/tanle/.asdf/installs/ruby/2.7.5/lib/ruby/gems/2.7.0/gems/oj-introspect-0.7.0/ext/oj-introspect
make DESTDIR\= sitearchdir\=./.gem.20221110-61802-1e0d94h sitelibdir\=./.gem.20221110-61802-1e0d94h clean
current directory: /Users/tanle/.asdf/installs/ruby/2.7.5/lib/ruby/gems/2.7.0/gems/oj-introspect-0.7.0/ext/oj-introspect
make DESTDIR\= sitearchdir\=./.gem.20221110-61802-1e0d94h sitelibdir\=./.gem.20221110-61802-1e0d94h
compiling introspect.c
linking shared-object oj/introspect/introspect_ext.bundle
Undefined symbols for architecture arm64:
"_oj_init_usual", referenced from:
_rb_new_introspect_parser in introspect.o
"_oj_parser_new", referenced from:
_rb_new_introspect_parser in introspect.o
"_oj_parser_set_option", referenced from:
_rb_new_introspect_parser in introspect.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [Makefile:262: introspect_ext.bundle] Error 1
make failed, exit code 2
Gem files will remain installed in /Users/tanle/.asdf/installs/ruby/2.7.5/lib/ruby/gems/2.7.0/gems/oj-introspect-0.7.0 for inspection.
Results logged to /Users/tanle/.asdf/installs/ruby/2.7.5/lib/ruby/gems/2.7.0/extensions/arm64-darwin-22/2.7.0/oj-introspect-0.7.0/gem_make.out
- An upstream fix has been submitted https://github.com/meinac/oj-introspect/pull/3
- A similar MR to address issues for other gems.
Impacted categories
The following categories relate to this merge request:
-
gdk-reliability - e.g. When a GDK action fails to complete. -
gdk-usability - e.g. Improvements or suggestions around how the GDK functions. -
gdk-performance - e.g. When a GDK action is slow or times out.
Merge request checklist
-
This change is backward compatible. If not, please include steps to communicate to our users. -
Tests added for new functionality. If not, please raise an issue to follow-up. -
Documentation added/updated, if needed. -
gdk doctor
test added, if needed. -
Add the ~highlight
label if this MR should be included in theCHANGELOG.md
.
Edited by Tan Le