GithubHelp home page GithubHelp logo

Comments (3)

take-cheeze avatar take-cheeze commented on July 4, 2024

@torsakch I don't know if you're still working on this but you need to build onigmo or oniguruma for all architecture used in iOS development.
And x86_64 seems to be the simulator of iOS so you need to build either of onig library with x86_64 that iOS simulator build accepts to make it link.

from mruby-onig-regexp.

take-cheeze avatar take-cheeze commented on July 4, 2024

Closing since no response from the issue submitter.

from mruby-onig-regexp.

Dan2552 avatar Dan2552 commented on July 4, 2024

I'm having this issue too, build_config.rb is simply:

MRuby::Build.new do |conf|
  toolchain :clang
  conf.gem :mgem => 'mruby-onig-regexp'
  conf.gembox 'default'
end

also tried

CC = `xcrun -find clang`.strip
def sdk_path(device); `xcrun --sdk #{device} --show-sdk-path`.strip end
MACOS_FLAGS = %W(-Os -arch x86_64 -isysroot #{sdk_path 'macosx'})

MRuby::Build.new do |conf|
  toolchain :clang
  conf.gem :mgem => 'mruby-onig-regexp'
  conf.gembox 'default'

  conf.cc do |cc|
    cc.command = CC
    cc.flags = MACOS_FLAGS
  end

  conf.linker do |linker|
    linker.command = CC
    linker.flags = MACOS_FLAGS
  end
end

compile and running machine is the same macOS machine (not trying iOS or anything special)

to compile mruby, I'm running

  rake deep_clean
  rake all

don't know if it's relevant, but building ruby files like

./mruby/bin/mrbc \
  -g \
  -Bapp \
  -o./app.c \
  app.rb

and trying to compile the binary using

clang output.c \
  -o./output \
  -I./mruby/include \
  -lmruby \
  -L./mruby/build/host/lib/

and also tried

$(xcrun -find clang) output.c \
  -o./output \
  -I./mruby/include \
  -lmruby \
  -L./mruby/build/host/lib/ \
  -Os -arch x86_64 -isysroot $(xcrun --sdk macosx --show-sdk-path)

from mruby-onig-regexp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.