• R/O
  • HTTP
  • SSH
  • HTTPS

提交

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

超漢字上で、mrubyを使ってhello worldを表示させる。


Commit MetaInfo

修訂9469d73dffecda3f85374fad90c17d5787a448d4 (tree)
時間2014-07-14 00:01:57
作者ornse01 <ornse01@user...>
Commiterornse01

Log Message

add mruby build configuration file for bvgdsk.

Change Summary

差異

--- /dev/null
+++ b/src/build_config.rb
@@ -0,0 +1,113 @@
1+MRuby::Build.new do |conf|
2+ # load specific toolchain settings
3+
4+ # Gets set by the VS command prompts.
5+ if ENV['VisualStudioVersion']
6+ toolchain :visualcpp
7+ else
8+ toolchain :gcc
9+ end
10+
11+ enable_debug
12+
13+ # Use mrbgems
14+ # conf.gem 'examples/mrbgems/ruby_extension_example'
15+ # conf.gem 'examples/mrbgems/c_extension_example' do |g|
16+ # g.cc.flags << '-g' # append cflags in this gem
17+ # end
18+ # conf.gem 'examples/mrbgems/c_and_ruby_extension_example'
19+ # conf.gem :github => 'masuidrive/mrbgems-example', :branch => 'master'
20+ # conf.gem :git => 'git@github.com:masuidrive/mrbgems-example.git', :branch => 'master', :options => '-v'
21+
22+ # include the default GEMs
23+ conf.gembox 'default'
24+
25+ # C compiler settings
26+ # conf.cc do |cc|
27+ # cc.command = ENV['CC'] || 'gcc'
28+ # cc.flags = [ENV['CFLAGS'] || %w()]
29+ # cc.include_paths = ["#{root}/include"]
30+ # cc.defines = %w(DISABLE_GEMS)
31+ # cc.option_include_path = '-I%s'
32+ # cc.option_define = '-D%s'
33+ # cc.compile_options = "%{flags} -MMD -o %{outfile} -c %{infile}"
34+ # end
35+
36+ # mrbc settings
37+ # conf.mrbc do |mrbc|
38+ # mrbc.compile_options = "-g -B%{funcname} -o-" # The -g option is required for line numbers
39+ # end
40+
41+ # Linker settings
42+ # conf.linker do |linker|
43+ # linker.command = ENV['LD'] || 'gcc'
44+ # linker.flags = [ENV['LDFLAGS'] || []]
45+ # linker.flags_before_libraries = []
46+ # linker.libraries = %w()
47+ # linker.flags_after_libraries = []
48+ # linker.library_paths = []
49+ # linker.option_library = '-l%s'
50+ # linker.option_library_path = '-L%s'
51+ # linker.link_options = "%{flags} -o %{outfile} %{objs} %{libs}"
52+ # end
53+
54+ # Archiver settings
55+ # conf.archiver do |archiver|
56+ # archiver.command = ENV['AR'] || 'ar'
57+ # archiver.archive_options = 'rs %{outfile} %{objs}'
58+ # end
59+
60+ # Parser generator settings
61+ # conf.yacc do |yacc|
62+ # yacc.command = ENV['YACC'] || 'bison'
63+ # yacc.compile_options = '-o %{outfile} %{infile}'
64+ # end
65+
66+ # gperf settings
67+ # conf.gperf do |gperf|
68+ # gperf.command = 'gperf'
69+ # gperf.compile_options = '-L ANSI-C -C -p -j1 -i 1 -g -o -t -N mrb_reserved_word -k"1,3,$" %{infile} > %{outfile}'
70+ # end
71+
72+ # file extensions
73+ # conf.exts do |exts|
74+ # exts.object = '.o'
75+ # exts.executable = '' # '.exe' if Windows
76+ # exts.library = '.a'
77+ # end
78+
79+ # file separetor
80+ # conf.file_separator = '/'
81+
82+ # bintest
83+ # conf.enable_bintest = true
84+end
85+
86+# Define cross build settings
87+MRuby::CrossBuild.new('pcat') do |conf|
88+
89+ toolchain :gcc
90+
91+ # C compiler settings
92+ conf.cc do |cc|
93+ cc.command = "#{ENV['GNUi386']}/bin/gcc386"
94+ cc.flags = "-O2 -fno-strength-reduce -mpreferred-stack-boundary=2 -Wall"
95+ cc.include_paths = ["#{root}/include", "#{ENV['BD']}/include", "../src/posix_include"]
96+ cc.defines = %w(DISABLE_STDIO PCAT)
97+ end
98+
99+ # Archiver settings
100+ conf.archiver do |archiver|
101+ archiver.command = "#{ENV['GNUi386']}/bin/ar"
102+ archiver.archive_options = 'rvl %{outfile} %{objs}'
103+ end
104+
105+ conf.build_mrbtest_lib_only
106+
107+ @bins = [] # for disable to link mrbc for target.
108+#
109+# conf.gem 'examples/mrbgems/c_and_ruby_extension_example'
110+#
111+# conf.test_runner.command = 'env'
112+#
113+end