Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
how to embed mruby
Search
Tomoyuki Sahara
June 02, 2013
Programming
2
390
how to embed mruby
English translation is
https://speakerdeck.com/tsahara/how-to-embed-mruby-en
.
Tomoyuki Sahara
June 02, 2013
Tweet
Share
More Decks by Tomoyuki Sahara
See All by Tomoyuki Sahara
IPv6 家庭用ルータ SWG 報告
tsahara
0
120
IPv6 RFC 改版の提案はなぜ議論紛糾したのか?
tsahara
2
2.1k
DNS と TLS のビミョーな関係
tsahara
1
550
IPv6 Path MTU in the World and Japan
tsahara
1
20k
how to embed mruby (en)
tsahara
0
130
Other Decks in Programming
See All in Programming
『ドメイン駆動設計をはじめよう』のモデリングアプローチ
masuda220
PRO
8
540
WebフロントエンドにおけるGraphQL(あるいはバックエンドのAPI)との向き合い方 / #241106_plk_frontend
izumin5210
4
1.4k
macOS でできる リアルタイム動画像処理
biacco42
9
2.4k
Micro Frontends Unmasked Opportunities, Challenges, Alternatives
manfredsteyer
PRO
0
110
ヤプリ新卒SREの オンボーディング
masaki12
0
130
[Do iOS '24] Ship your app on a Friday...and enjoy your weekend!
polpielladev
0
110
Flutterを言い訳にしない!アプリの使い心地改善テクニック5選🔥
kno3a87
1
200
Webの技術スタックで マルチプラットフォームアプリ開発を可能にするElixirDesktopの紹介
thehaigo
2
1k
TypeScriptでライブラリとの依存を限定的にする方法
tutinoko
3
700
Make Impossible States Impossibleを 意識してReactのPropsを設計しよう
ikumatadokoro
0
240
watsonx.ai Dojo #4 生成AIを使ったアプリ開発、応用編
oniak3ibm
PRO
1
150
EMになってからチームの成果を最大化するために取り組んだこと/ Maximize team performance as EM
nashiusagi
0
100
Featured
See All Featured
The Language of Interfaces
destraynor
154
24k
Unsuck your backbone
ammeep
668
57k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
506
140k
Why You Should Never Use an ORM
jnunemaker
PRO
54
9.1k
GraphQLとの向き合い方2022年版
quramy
43
13k
jQuery: Nuts, Bolts and Bling
dougneiner
61
7.5k
Intergalactic Javascript Robots from Outer Space
tanoku
269
27k
Product Roadmaps are Hard
iamctodd
PRO
49
11k
Being A Developer After 40
akosma
87
590k
GitHub's CSS Performance
jonrohan
1030
460k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
26
2.1k
Designing on Purpose - Digital PM Summit 2013
jponch
115
7k
Transcript
mrubyͷΈࠐΈ͔ͨ ࠤݪ۩ UTBIBSB!JJKBEKQ גࣜձࣾΠϯλʔωοτΠχγΞςΟϒ $PQZSJHIU $ *OUFSOFU*OJUJBUJWF+BQBO*OD"MMSJHIUTSFTFSWFE
͡Ίʹ ࠒͷͰ͢
NSVCZͱ mruby is the lightweight implementation of the Ruby language...
https://github.com/mruby/mruby google://mruby/
CPU: ARM 32bit Memory: 128MB FlashROM: 32MB OS: NetBSD 4"8
XXXTBDNKQTBX NSVCZΛͬͨϧʔλ
ͳͥNSVCZΛͬͨͷ͔ interface.ge1.ipv4.address : 192.168.0.1/24 interface.wlan0.service : enable interface.wlan0.ssid : guest
interface.wlan0.security : wpa-psk-aes route.ipv4.0.destination : default route.ipv4.0.gateway : 100.100.0.1 dhcp.server.0.interface : wlan0 dhcp.server.0.pool.address : 192.168.0.4/24 dhcp.server.0.pool.count : 100 ίϯϑΟά ύʔζݕূධՁө mruby!
NSVCZΛಈ͔͢ CPU ARM 32bit ˡͦͦ͜͜;ͭ͏ Memory 128MB ˡ·͊·͊͋Δ FlashROM 32MB
ˡݫ͠Ί OS NetBSD ˡ͍͓ͪ͏6OJY 㲈;ͭ͏ͷ1$ ͨͩ͠ශऑ 㲈;ͭ͏ͷ1$ ͨͩ͠ශऑ 㱤ಈ͔͚ͩ͢ͳΒ͘͠ͳ͍
ͬͨ͜ͱ • ػೳ֦ு • ෆ۩߹मਖ਼ • ҆ఆ൛ϦϦʔεͷ࡞ • ϑΝʔϜΣΞͷΈೖΕ
Of cource it runs NetBSD
ιϑτΣΞͷΈࠐΈ NetBSD ϑΝʔϜΣΞ OpenSSL KAME NTPD Quagga ಠࣗιϑτΣΞ mruby
ιʔείʔυͷऔಘ % wget http://www.openssl.org/ source/openssl-1.0.1e.tar.gz
NSVCZͷ҆ఆ൛ % wget http://www.mruby.org/ source/mruby-1.0.0.tar.gz ͋Γ·ͤΜɻ
ͬͨ͜ͱ • ػೳ֦ு • ෆ۩߹मਖ਼ • ҆ఆ൛ϦϦʔεͷ࡞ ←New! • ϑΝʔϜΣΞͷΈೖΕ
NSVCZPOHJUIVC
JJKNSVCZ
ϒϥϯνຊ Ћ ϒϥϯν ༻్ NBTUFS NSVCZNSVCZ JJK ։ൃ൛ T ҆ఆ൛
ͦͷଞ QVMMSFRVFTU༻ͳͲɺ͍ࣺͯ
NSVCZNSVCZ JJKNSVCZ NBTUFS NBTUFS JJK T EBJMZ ࣗಈ EBJMZ ࣗಈ·ͨखಈ
ෆఆظ ϨϏϡʔ͖खಈ
ͬͨ͜ͱ • ػೳ֦ு • ෆ۩߹मਖ਼ • ҆ఆ൛ϦϦʔεͷ࡞ • ϑΝʔϜΣΞͷΈೖΕ
Πϯϙʔτखॱ work=$HOME/mruby-import % cd $work % git checkout -b s1
Πϯϙʔτखॱ % make % make test % ./test/posix/all.sh
Πϯϙʔτखॱ usr=$NetBSD/usr.bin/mruby % cp src/y.tab.c mrblib/mrblib.c $usr % vi $usr/Makefile
Πϯϙʔτखॱ dist=$NetBSD/dist/mruby % make clean % rm -r $dist/* %
cp -r * $dist
Πϯϙʔτखॱ % cd $dist; svn add ... % svn ci
$dist $usr
ͬͨ͜ͱ • ػೳ֦ு • ෆ۩߹मਖ਼ • ҆ఆ൛ϦϦʔεͷ࡞ • ϑΝʔϜΣΞͷΈೖΕ
Bug, Bug, Bug!
ͬͨ͜ͱ • ػೳ֦ு • ෆ۩߹मਖ਼ ←New! • ҆ఆ൛ϦϦʔεͷ࡞ • ϑΝʔϜΣΞͷΈೖΕ
҆ఆԽ w σόοάڥͷඋ w όοΫτϨʔε w lSFRVJSFzʹΑΔϞδϡʔϧׂ w ٯΞηϯϒϥ BQQNSCEVNQ
w ςετϑϨʔϜϫʔΫ NSVCZNUFTU w σόοΨ NSVCZNEFCVH
ͬͨ͜ͱ • ػೳ֦ு • ෆ۩߹मਖ਼ • ҆ఆ൛ϦϦʔεͷ࡞ • ϑΝʔϜΣΞͷΈೖΕ
ʮ͑ 3VCZͳͷʹ ͕ແ͍ͷ ʯ
ͬͨ͜ͱ • ػೳڧԽ ←New! • ෆ۩߹मਖ਼ • ҆ఆ൛ϦϦʔεͷ࡞ • ϑΝʔϜΣΞͷΈೖΕ
֦ு w6OJYґଘͷػೳͷՃ w*0 'JMF 4PDLFU 3FHFYQ &SSOP wطଘϞδϡʔϧͷڧԽ w"SSBZ
4USJOH
JJKNSVCZ mruby-io mruby-socket mruby-regexp-pcre mruby-errno mruby-simple-random mruby-env mruby-require mruby-pack mruby-mock
mruby-syslog mruby-mtest mruby-tempfile mruby-process mruby-pcap mruby-dir (more...)
ʂ • ػೳڧԽ • ෆ۩߹मਖ਼ • ҆ఆ൛ϦϦʔεͷ࡞ • ϑΝʔϜΣΞͷΈೖΕ
ࠓޙ w ΈࠐΜͩNSVCZͷ׆༻ w ࣍ͷ҆ఆ൛Tͷ࡞