-
Notifications
You must be signed in to change notification settings - Fork 30
/
Copy pathbuild_config.rb
60 lines (49 loc) · 1.58 KB
/
build_config.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
MRuby::Build.new do |conf|
toolchain :gcc
conf.gembox 'full-core'
#
# Recommended for mod_mruby
#
conf.gem :github => 'iij/mruby-env'
conf.gem :github => 'iij/mruby-dir'
conf.gem :github => 'iij/mruby-digest'
conf.gem :github => 'iij/mruby-process'
conf.gem :github => 'mattn/mruby-json'
conf.gem :github => 'mattn/mruby-onig-regexp'
conf.gem :github => 'matsumoto-r/mruby-vedis'
conf.gem :github => 'matsumoto-r/mruby-userdata'
conf.gem :github => 'matsumoto-r/mruby-uname'
conf.gem :github => 'matsumoto-r/mruby-localmemcache'
conf.gem :github => 'matsumoto-r/mruby-mutex'
# mod_mruby extended class
conf.gem '../mrbgems/mod_mruby_mrblib'
conf.gem '../mrbgems/rack-based-api'
# use memcached
# conf.gem :github => 'matsumoto-r/mruby-memcached'
# build error on travis ci 2014/12/01, commented out mruby-file-stat
# conf.gem :github => 'ksss/mruby-file-stat'
# use markdown on mod_mruby
# conf.gem :github => 'matsumoto-r/mruby-discount'
# have GeoIPCity.dat
# conf.gem :github => 'matsumoto-r/mruby-geoip'
# Linux only for mod_mruby
# conf.gem :github => 'matsumoto-r/mruby-capability'
# conf.gem :github => 'matsumoto-r/mruby-cgroup'
# C compiler settings
conf.cc do |cc|
if ENV['BUILD_TYPE'] == "debug"
cc.flags << '-fPIC -g3 -Wall -Werror-implicit-function-declaration'
else
cc.flags << '-fPIC'
end
if ENV['BUILD_BIT'] == "64"
cc.flags << ' -DMRB_INT64'
end
end
# Linker settings
conf.linker do |linker|
if ENV['BUILD_BIT'] == "64"
linker.flags = '-DMRB_INT64'
end
end
end