diff options
| author | Nobuyoshi Nakada <[email protected]> | 2014-04-30 09:50:14 +0900 |
|---|---|---|
| committer | Nobuyoshi Nakada <[email protected]> | 2014-04-30 09:50:14 +0900 |
| commit | ab67c57f652c7c3a64ec4f4dc73259a14fb1b545 (patch) | |
| tree | d9535d70ba74920783864fa6372ec471aca5af91 /examples | |
| parent | 345f172bba2dc5a6df607dded5c4b95b0e68f9bf (diff) | |
| download | mruby-ab67c57f652c7c3a64ec4f4dc73259a14fb1b545.tar.gz mruby-ab67c57f652c7c3a64ec4f4dc73259a14fb1b545.zip | |
remove trailing spaces
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/mrbgems/c_and_ruby_extension_example/mrbgem.rake | 2 | ||||
| -rw-r--r-- | examples/mrbgems/c_extension_example/mrbgem.rake | 2 | ||||
| -rw-r--r-- | examples/mrbgems/ruby_extension_example/mrbgem.rake | 2 | ||||
| -rw-r--r-- | examples/targets/ArduinoDue.rb | 8 | ||||
| -rw-r--r-- | examples/targets/IntelGalileo.rb | 36 | ||||
| -rw-r--r-- | examples/targets/chipKitMax32.rb | 12 |
6 files changed, 31 insertions, 31 deletions
diff --git a/examples/mrbgems/c_and_ruby_extension_example/mrbgem.rake b/examples/mrbgems/c_and_ruby_extension_example/mrbgem.rake index a1f964b36..6b4595b35 100644 --- a/examples/mrbgems/c_and_ruby_extension_example/mrbgem.rake +++ b/examples/mrbgems/c_and_ruby_extension_example/mrbgem.rake @@ -1,7 +1,7 @@ MRuby::Gem::Specification.new('c_and_ruby_extension_example') do |spec| spec.license = 'MIT' spec.author = 'mruby developers' - + # Add compile flags # spec.cc.flags << '' diff --git a/examples/mrbgems/c_extension_example/mrbgem.rake b/examples/mrbgems/c_extension_example/mrbgem.rake index 3524e22f4..6e4c5b165 100644 --- a/examples/mrbgems/c_extension_example/mrbgem.rake +++ b/examples/mrbgems/c_extension_example/mrbgem.rake @@ -1,7 +1,7 @@ MRuby::Gem::Specification.new('c_extension_example') do |spec| spec.license = 'MIT' spec.author = 'mruby developers' - + # Add compile flags # spec.cc.flags << '-g' diff --git a/examples/mrbgems/ruby_extension_example/mrbgem.rake b/examples/mrbgems/ruby_extension_example/mrbgem.rake index 5624c33e9..57cf1a69e 100644 --- a/examples/mrbgems/ruby_extension_example/mrbgem.rake +++ b/examples/mrbgems/ruby_extension_example/mrbgem.rake @@ -1,7 +1,7 @@ MRuby::Gem::Specification.new('ruby_extension_example') do |spec| spec.license = 'MIT' spec.author = 'mruby developers' - + # Add compile flags # spec.cc.flags << '' diff --git a/examples/targets/ArduinoDue.rb b/examples/targets/ArduinoDue.rb index 59101c2cc..a850eabb6 100644 --- a/examples/targets/ArduinoDue.rb +++ b/examples/targets/ArduinoDue.rb @@ -18,8 +18,8 @@ MRuby::CrossBuild.new("Arduino Due") do |conf| cc.include_paths << ["#{SAM_PATH}/system/libsam", "#{SAM_PATH}/system/CMSIS/CMSIS/Include/", "#{SAM_PATH}/system/CMSIS/Device/ATMEL/", "#{SAM_PATH}/cores/arduino", "#{SAM_PATH}/libraries","#{TARGET_PATH}"] - cc.flags = %w(-g -Os -w -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 - -Dprintf=iprintf -mcpu=cortex-m3 -DF_CPU=84000000L -DARDUINO=156 -DARDUINO_SAM_DUE -DARDUINO_ARCH_SAM + cc.flags = %w(-g -Os -w -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 + -Dprintf=iprintf -mcpu=cortex-m3 -DF_CPU=84000000L -DARDUINO=156 -DARDUINO_SAM_DUE -DARDUINO_ARCH_SAM -D__SAM3X8E__ -mthumb -DUSB_PID=0x003e -DUSB_VID=0x2341 -DUSBCON -DUSB_MANUFACTURER="Unknown" -DUSB_PRODUCT="Arduino Due") cc.compile_options = "%{flags} -o %{outfile} -c %{infile}" @@ -57,12 +57,12 @@ MRuby::CrossBuild.new("Arduino Due") do |conf| conf.disable_cxx_exception #gems from core - conf.gem :core => "mruby-print" + conf.gem :core => "mruby-print" conf.gem :core => "mruby-math" conf.gem :core => "mruby-enum-ext" #light-weight regular expression - conf.gem :github => "masamitsu-murase/mruby-hs-regexp", :branch => "master" + conf.gem :github => "masamitsu-murase/mruby-hs-regexp", :branch => "master" #Arduino API #conf.gem :github =>"kyab/mruby-arduino", :branch => "master" diff --git a/examples/targets/IntelGalileo.rb b/examples/targets/IntelGalileo.rb index 0ee073344..185b6e71e 100644 --- a/examples/targets/IntelGalileo.rb +++ b/examples/targets/IntelGalileo.rb @@ -2,30 +2,30 @@ # http://arduino.cc/en/ArduinoCertified/IntelGalileo # # Requires Arduino IDE for Intel Galileo - + MRuby::CrossBuild.new("Galileo") do |conf| toolchain :gcc - + # Mac OS X # Assume you renamed Arduino.app to Arduino_Galileo.app GALILEO_ARDUINO_PATH = '/Applications/Arduino_Galileo.app/Contents/Resources/Java' # GNU Linux #ARDUINO_GALILEO_PATH = '/opt/arduino' - + GALILEO_BIN_PATH = "#{GALILEO_ARDUINO_PATH}/hardware/tools/x86/i386-pokysdk-darwin/usr/bin/i586-poky-linux-uclibc" GALILEO_SYSROOT = "#{GALILEO_ARDUINO_PATH}/hardware/tools/x86/i586-poky-linux-uclibc" GALILEO_X86_PATH = "#{GALILEO_ARDUINO_PATH}/hardware/arduino/x86" - - + + conf.cc do |cc| cc.command = "#{GALILEO_BIN_PATH}/i586-poky-linux-uclibc-gcc" cc.include_paths << ["#{GALILEO_X86_PATH}/cores/arduino", "#{GALILEO_X86_PATH}/variants/galileo_fab_d"] - cc.flags = %w(-m32 -march=i586 -c -g -Os -w + cc.flags = %w(-m32 -march=i586 -c -g -Os -w -ffunction-sections -fdata-sections -MMD -DARDUINO=153) cc.flags << "--sysroot=#{GALILEO_SYSROOT}" cc.compile_options = "%{flags} -o %{outfile} -c %{infile}" end - + conf.cxx do |cxx| cxx.command = "#{GALILEO_BIN_PATH}/i586-poky-linux-uclibc-g++" cxx.include_paths = conf.cc.include_paths.dup @@ -35,12 +35,12 @@ MRuby::CrossBuild.new("Galileo") do |conf| cxx.defines = conf.cc.defines.dup cxx.compile_options = conf.cc.compile_options.dup end - + conf.archiver do |archiver| archiver.command = "#{GALILEO_BIN_PATH}/i586-poky-linux-uclibc-ar" archiver.archive_options = 'rcs %{outfile} %{objs}' end - + conf.linker do |linker| linker.command = "#{GALILEO_BIN_PATH}/i586-poky-linux-uclibc-g++" linker.flags = %w(-m32 -march=i586) @@ -48,13 +48,13 @@ MRuby::CrossBuild.new("Galileo") do |conf| linker.flags << %w(-Os -Wl,--gc-sections) linker.libraries = %w(m pthread) end - + #no executables conf.bins = [] - + #do not build executable test conf.build_mrbtest_lib_only - + #official mrbgems conf.gem :core => "mruby-sprintf" conf.gem :core => "mruby-print" @@ -74,17 +74,17 @@ MRuby::CrossBuild.new("Galileo") do |conf| conf.gem :core => "mruby-objectspace" conf.gem :core => "mruby-fiber" conf.gem :core => "mruby-toplevel-ext" - + #lightweigh regular expression - conf.gem :github => "masamitsu-murase/mruby-hs-regexp", :branch => "master" - + conf.gem :github => "masamitsu-murase/mruby-hs-regexp", :branch => "master" + #Arduino API #conf.gem :github =>"kyab/mruby-arduino", :branch => "master" do |g| # g.cxx.include_paths << "#{GALILEO_X86_PATH}/libraries/Wire" # g.cxx.include_paths << "#{GALILEO_X86_PATH}/libraries/Servo" - + #enable unsupported Servo class # g.cxx.defines << "MRUBY_ARDUINO_GALILEO_ENABLE_SERVO" #end - -end
\ No newline at end of file + +end diff --git a/examples/targets/chipKitMax32.rb b/examples/targets/chipKitMax32.rb index 5c3a30a2b..b3a7c7c7d 100644 --- a/examples/targets/chipKitMax32.rb +++ b/examples/targets/chipKitMax32.rb @@ -13,15 +13,15 @@ MRuby::CrossBuild.new("chipKitMax32") do |conf| # GNU Linux MPIDE_PATH = '/opt/mpide-0023-linux-20120903' - PIC32_PATH = "#{MPIDE_PATH}/hardware/pic32" + PIC32_PATH = "#{MPIDE_PATH}/hardware/pic32" conf.cc do |cc| cc.command = "#{PIC32_PATH}/compiler/pic32-tools/bin/pic32-gcc" cc.include_paths << ["#{PIC32_PATH}/cores/pic32", "#{PIC32_PATH}/variants/Max32", "#{PIC32_PATH}/libraries"] - cc.flags = %w(-O2 -mno-smart-io -w -ffunction-sections -fdata-sections -g -mdebugger -Wcast-align - -fno-short-double -mprocessor=32MX795F512L -DF_CPU=80000000L -DARDUINO=23 -D_BOARD_MEGA_ + cc.flags = %w(-O2 -mno-smart-io -w -ffunction-sections -fdata-sections -g -mdebugger -Wcast-align + -fno-short-double -mprocessor=32MX795F512L -DF_CPU=80000000L -DARDUINO=23 -D_BOARD_MEGA_ -DMPIDEVER=0x01000202 -DMPIDE=23) cc.compile_options = "%{flags} -o %{outfile} -c %{infile}" @@ -51,16 +51,16 @@ MRuby::CrossBuild.new("chipKitMax32") do |conf| #no executables conf.bins = [] - #do not build test executable + #do not build test executable conf.build_mrbtest_lib_only #gems from core - conf.gem :core => "mruby-print" + conf.gem :core => "mruby-print" conf.gem :core => "mruby-math" conf.gem :core => "mruby-enum-ext" #light-weight regular expression - conf.gem :github => "masamitsu-murase/mruby-hs-regexp", :branch => "master" + conf.gem :github => "masamitsu-murase/mruby-hs-regexp", :branch => "master" #Arduino API #conf.gem :github =>"kyab/mruby-arduino", :branch => "master" |
