Merge branch 'master' of ecommons@wax.hive:bdberl
Conflicts: Rakefile
This commit is contained in:
commit
695597a10e
3 changed files with 33 additions and 9 deletions
21
Rakefile
21
Rakefile
|
@ -41,11 +41,16 @@ task :int_test do
|
||||||
run_tests "int_test", "+A10"
|
run_tests "int_test", "+A10"
|
||||||
end
|
end
|
||||||
|
|
||||||
# task :compile_perf_tests do
|
task :package => [:compile] do
|
||||||
# do_compile_tests("perftest")
|
app = File.basename(APP, ".app")
|
||||||
# end
|
vsn = erl_app_version(app)
|
||||||
#
|
target_dir = "#{app}-#{vsn}"
|
||||||
# desc "Run performance tests"
|
Dir.mkdir target_dir
|
||||||
# task :perftest => [:compile, :compile_perf_tests] do
|
cp_r 'ebin', target_dir
|
||||||
# run_tests "perftest", "+A10"
|
cp_r 'include', target_dir
|
||||||
# end
|
cp_r 'src', target_dir
|
||||||
|
cp_r 'priv', target_dir
|
||||||
|
Dir.mkdir "#{target_dir}/priv/bin"
|
||||||
|
cp_r Dir.glob('c_src/system/bin/*'), "#{target_dir}/priv/bin"
|
||||||
|
puts "Packaged to #{target_dir}"
|
||||||
|
end
|
||||||
|
|
20
base.rake
20
base.rake
|
@ -73,6 +73,26 @@ def erl_app_modules(app)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def erl_app_version(app)
|
||||||
|
script = <<-ERL
|
||||||
|
ok = application:load(#{app}),
|
||||||
|
{ok, Vsn} = application:get_key(#{app}, vsn),
|
||||||
|
io:format("~s\\n", [Vsn]).
|
||||||
|
ERL
|
||||||
|
output = erl_run(script, "-pa ebin")
|
||||||
|
output.strip()
|
||||||
|
end
|
||||||
|
|
||||||
|
def erl_app_version(app)
|
||||||
|
script = <<-ERL
|
||||||
|
ok = application:load(#{app}),
|
||||||
|
{ok, Vsn} = application:get_key(#{app}, vsn),
|
||||||
|
io:format("~s\\n", [Vsn]).
|
||||||
|
ERL
|
||||||
|
output = erl_run(script, "-pa ebin")
|
||||||
|
output.strip()
|
||||||
|
end
|
||||||
|
|
||||||
def erts_dir()
|
def erts_dir()
|
||||||
script = <<-ERL
|
script = <<-ERL
|
||||||
io:format("~s\n", [lists:concat([code:root_dir(), "/erts-", erlang:system_info(version)])])
|
io:format("~s\n", [lists:concat([code:root_dir(), "/erts-", erlang:system_info(version)])])
|
||||||
|
|
|
@ -22,7 +22,6 @@ tar -xzf db-${DB_VER}.tar.gz && \
|
||||||
(cd db-${DB_VER}/build_unix && \
|
(cd db-${DB_VER}/build_unix && \
|
||||||
../dist/configure --prefix=$WORKDIR --disable-shared --with-pic && make && ranlib libdb-*.a && make install) && \
|
../dist/configure --prefix=$WORKDIR --disable-shared --with-pic && make && ranlib libdb-*.a && make install) && \
|
||||||
mkdir -p $TARGETDIR/utils && \
|
mkdir -p $TARGETDIR/utils && \
|
||||||
cp $WORKDIR/bin/* $TARGETDIR/utils && \
|
|
||||||
rm -rf db-${DB_VER}
|
rm -rf db-${DB_VER}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue