Skip to content

Commit

Permalink
Add benchmarks for docker compose and tooling.
Browse files Browse the repository at this point in the history
  • Loading branch information
viferga committed Mar 21, 2020
1 parent 2094cbe commit 6e54bd8
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ services:
args:
METACALL_PATH: $METACALL_PATH
METACALL_BUILD_TYPE: $METACALL_CORE_BUILD_TYPE
METACALL_BUILD_OPTIONS: root python ruby netcore2 nodejs file examples distributable tests scripts ports dynamic install pack # v8 coverage
METACALL_BUILD_OPTIONS: root python ruby netcore2 nodejs file examples distributable tests benchmarks scripts ports dynamic install pack # v8 coverage
environment:
DEBIAN_FRONTEND: noninteractive
LTTNG_UST_REGISTER_TIMEOUT: 0
Expand Down
51 changes: 50 additions & 1 deletion tools/metacall-configure.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ BUILD_FILE=0
BUILD_SCRIPTS=0
BUILD_EXAMPLES=0
BUILD_DISTRIBUTABLE=0
BUILD_TESTS=0
BUILD_BENCHMARKS=0
BUILD_PORTS=0
BUILD_COVERAGE=0

Expand Down Expand Up @@ -95,6 +97,14 @@ sub_options() {
echo "Build distributable libraries"
BUILD_DISTRIBUTABLE=1
fi
if [ "$option" = 'tests' ]; then
echo "Build all tests"
BUILD_TESTS=1
fi
if [ "$option" = 'benchmarks' ]; then
echo "Build all benchmarks"
BUILD_BENCHMARKS=1
fi
if [ "$option" = 'ports' ]; then
echo "Build all ports"
BUILD_PORTS=1
Expand Down Expand Up @@ -126,6 +136,10 @@ sub_configure() {
if [ $BUILD_SCRIPTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_SCRIPTS_PY=On"
fi

if [ $BUILD_PORTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_PORTS_PY=On"
fi
fi

# Ruby
Expand All @@ -135,6 +149,10 @@ sub_configure() {
if [ $BUILD_SCRIPTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_SCRIPTS_RB=On"
fi

if [ $BUILD_PORTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_PORTS_RB=On"
fi
fi

# NetCore
Expand All @@ -146,6 +164,10 @@ sub_configure() {
if [ $BUILD_SCRIPTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_SCRIPTS_CS=On"
fi

if [ $BUILD_PORTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_PORTS_CS=On"
fi
fi

# NetCore 2
Expand All @@ -157,6 +179,10 @@ sub_configure() {
if [ $BUILD_SCRIPTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_SCRIPTS_CS=On"
fi

if [ $BUILD_PORTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_PORTS_CS=On"
fi
fi

# V8
Expand All @@ -166,6 +192,10 @@ sub_configure() {
if [ $BUILD_SCRIPTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_SCRIPTS_JS=On"
fi

if [ $BUILD_PORTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_PORTS_JS=On"
fi
fi

# NodeJS
Expand All @@ -175,6 +205,10 @@ sub_configure() {
if [ $BUILD_SCRIPTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_SCRIPTS_NODE=On"
fi

if [ $BUILD_PORTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_PORTS_NODE=On"
fi
fi

# File
Expand All @@ -200,6 +234,20 @@ sub_configure() {
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_DIST_LIBS=Off"
fi

# Tests
if [ $BUILD_TESTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_TESTS=On"
else
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_TESTS=Off"
fi

# Benchmarks
if [ $BUILD_BENCHMARKS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_BENCHMARKS=On"
else
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_BENCHMARKS=Off"
fi

# Ports
if [ $BUILD_PORTS = 1 ]; then
BUILD_STRING="$BUILD_STRING -DOPTION_BUILD_PORTS=On"
Expand Down Expand Up @@ -229,14 +277,15 @@ sub_help() {
echo " python: build with python support"
echo " ruby: build with ruby support"
echo " netcore: build with netcore support"
echo " netcore: build with netcore 2 support"
echo " netcore2: build with netcore 2 support"
echo " v8: build with v8 support"
echo " nodejs: build with nodejs support"
echo " file: build with file support"
echo " scripts: build all scripts"
echo " examples: build all examples"
echo " distributable: build distributable libraries"
echo " tests: build and run all tests"
echo " benchmarks: build and run all benchmarks"
echo " install: install all libraries"
echo " static: build as static libraries"
echo " dynamic: build as dynamic libraries"
Expand Down
1 change: 1 addition & 0 deletions tools/metacall-environment.sh
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,7 @@ sub_wasm(){

# MetaCall
sub_metacall(){
# TODO: Update this or deprecate it
echo "configure metacall"
cd $ROOT_DIR
git clone --recursive https://github.com/metacall/core.git
Expand Down

0 comments on commit 6e54bd8

Please sign in to comment.