Skip to content

Commit

Permalink
-Os
Browse files Browse the repository at this point in the history
  • Loading branch information
hadashiA committed Sep 23, 2024
1 parent 6875307 commit 451126d
Show file tree
Hide file tree
Showing 9 changed files with 14 additions and 20 deletions.
4 changes: 3 additions & 1 deletion src/vitalrouter-mruby/build_config.android.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@
conf.gembox '../../../vitalrouter'

conf.cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
conf.cc.flags << '-Os'
end

MRuby::CrossBuild.new('android-x64') do |conf|
toolchain :android, arch: 'x86_64'
conf.gembox '../../../vitalrouter'

conf.cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
conf.cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
conf.cc.flags << '-Os'
end
4 changes: 2 additions & 2 deletions src/vitalrouter-mruby/build_config.ios.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
conf.cc do |cc|
cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
cc.command = 'xcrun'
cc.flags = %W(-sdk iphoneos clang -arch arm64 -isysroot "#{sdk}" -mios-version-min=#{IOS_VERSION_MIN} -g -O3 -Wall -Werror-implicit-function-declaration)
cc.flags = %W(-sdk iphoneos clang -arch arm64 -isysroot "#{sdk}" -mios-version-min=#{IOS_VERSION_MIN} -g -Os -Wall -Werror-implicit-function-declaration)
end

conf.linker do |linker|
Expand All @@ -23,7 +23,7 @@
conf.cc do |cc|
cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
cc.command = 'xcrun'
cc.flags = %W(-sdk iphonesimulator clang -arch x86_64 -isysroot "#{sdk}" -mios-version-min=#{IOS_VERSION_MIN} -g -O3 -Wall -Werror-implicit-function-declaration)
cc.flags = %W(-sdk iphonesimulator clang -arch x86_64 -isysroot "#{sdk}" -mios-version-min=#{IOS_VERSION_MIN} -g -Os -Wall -Werror-implicit-function-declaration)
end

conf.linker do |linker|
Expand Down
13 changes: 0 additions & 13 deletions src/vitalrouter-mruby/build_config.ios.rb.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,3 @@
mruby:
version: 3.3.0
release_no: 30300
builds:
ios-arm64:
https://github.com/suzukaze/mruby-msgpack.git:
url: https://github.com/suzukaze/mruby-msgpack.git
branch: master
commit: d2538d8d1decc45953b21f41a5e07b9404df7bf7
version: 0.0.0
ios-x64:
https://github.com/suzukaze/mruby-msgpack.git:
url: https://github.com/suzukaze/mruby-msgpack.git
branch: master
commit: d2538d8d1decc45953b21f41a5e07b9404df7bf7
version: 0.0.0
2 changes: 2 additions & 0 deletions src/vitalrouter-mruby/build_config.linux.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
conf.compilers.each do |cc|
cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
cc.flags << '-fPIC'
cc.flags << '-Os'
end

conf.archiver do |archiver|
Expand Down Expand Up @@ -35,6 +36,7 @@
conf.compilers.each do |cc|
cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
cc.flags << '-fPIC'
cc.flags << '-Os'
end

conf.archiver do |archiver|
Expand Down
1 change: 1 addition & 0 deletions src/vitalrouter-mruby/build_config.macOS.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

conf.cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
conf.cc.flags << '-arch arm64'
conf.cc.flags << '-Os'
conf.linker.flags << '-arch arm64'
end

Expand Down
4 changes: 2 additions & 2 deletions src/vitalrouter-mruby/build_config.tvOS.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
conf.cc do |cc|
cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
cc.command = 'xcrun'
cc.flags = %W(-sdk appletvos clang -arch arm64 -isysroot "#{sdk}" -g -O3 -Wall -Werror-implicit-function-declaration)
cc.flags = %W(-sdk appletvos clang -arch arm64 -isysroot "#{sdk}" -g -Os -Wall -Werror-implicit-function-declaration)
end

conf.linker do |linker|
Expand All @@ -21,7 +21,7 @@
conf.cc do |cc|
cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
cc.command = 'xcrun'
cc.flags = %W(-sdk appletvsimulator clang -arch x86_64 -isysroot "#{sdk}" -g -O3 -Wall -Werror-implicit-function-declaration)
cc.flags = %W(-sdk appletvsimulator clang -arch x86_64 -isysroot "#{sdk}" -g -Os -Wall -Werror-implicit-function-declaration)
end

conf.linker do |linker|
Expand Down
4 changes: 2 additions & 2 deletions src/vitalrouter-mruby/build_config.visionOS.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
conf.cc do |cc|
cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
cc.command = 'xcrun'
cc.flags = %W(-sdk xros clang -arch arm64 -isysroot "#{sdk}" -g -O3 -Wall -Werror-implicit-function-declaration)
cc.flags = %W(-sdk xros clang -arch arm64 -isysroot "#{sdk}" -g -Os -Wall -Werror-implicit-function-declaration)
end

conf.linker do |linker|
Expand All @@ -21,7 +21,7 @@
conf.cc do |cc|
cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
cc.command = 'xcrun'
cc.flags = %W(-sdk xrsimulator clang -arch x86_64 -isysroot "#{sdk}" -g -O3 -Wall -Werror-implicit-function-declaration)
cc.flags = %W(-sdk xrsimulator clang -arch x86_64 -isysroot "#{sdk}" -g -Os -Wall -Werror-implicit-function-declaration)
end

conf.linker do |linker|
Expand Down
1 change: 1 addition & 0 deletions src/vitalrouter-mruby/build_config.wasm.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
conf.gembox '../../../vitalrouter'

conf.cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
conf.cc.flags << '-Os'
conf.cc.command = 'emcc'
conf.linker.command = 'emcc'
conf.archiver.command = 'emar'
Expand Down
1 change: 1 addition & 0 deletions src/vitalrouter-mruby/build_config.windows.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
conf.toolchain
conf.gembox '../../../vitalrouter'
cc.defines = %w(MRB_NO_BOXING MRB_NO_STDIO)
cc.flags << '-Os'
end

0 comments on commit 451126d

Please sign in to comment.