Skip to content

Commit

Permalink
Fix incorrect parameters in region example scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
rbx committed Nov 24, 2023
1 parent 2d27abc commit addfd07
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 32 deletions.
4 changes: 2 additions & 2 deletions examples/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ function(add_example)
set(FAIRMQ_BIN_DIR ${CMAKE_BINARY_DIR}/fairmq)
foreach(script IN LISTS scripts)
set(script_file "${script_prefix}-${script}.sh")
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/${script_file}.in" "${CMAKE_CURRENT_BINARY_DIR}/${script_file}")
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/${script_file}.in" "${CMAKE_CURRENT_BINARY_DIR}/${script_file}" @ONLY)
endforeach()

if(ARG_CONFIG)
Expand Down Expand Up @@ -119,7 +119,7 @@ function(add_example)
set(FAIRMQ_BIN_DIR ${CMAKE_INSTALL_PREFIX}/${PROJECT_INSTALL_BINDIR}/fairmq)
foreach(script IN LISTS scripts)
set(script_file "${script_prefix}-${script}.sh")
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/${script_file}.in" "${CMAKE_CURRENT_BINARY_DIR}/${script_file}_install")
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/${script_file}.in" "${CMAKE_CURRENT_BINARY_DIR}/${script_file}_install" @ONLY)
install(
PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/${script_file}_install"
DESTINATION ${PROJECT_INSTALL_BINDIR}
Expand Down
12 changes: 2 additions & 10 deletions examples/region/fairmq-start-ex-region-advanced-external.sh.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,8 @@

export FAIRMQ_PATH=@FAIRMQ_BIN_DIR@

transport="shmem"
msgSize="1000000"

if [[ $1 =~ ^[a-z]+$ ]]; then
transport=$1
fi

if [[ $2 =~ ^[0-9]+$ ]]; then
msgSize=$1
fi
transport=${1:-shmem}
msgSize=${2:-1000000}

SAMPLER="fairmq-ex-region-sampler"
SAMPLER+=" --id sampler1"
Expand Down
12 changes: 2 additions & 10 deletions examples/region/fairmq-start-ex-region-advanced.sh.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,8 @@

export FAIRMQ_PATH=@FAIRMQ_BIN_DIR@

transport="shmem"
msgSize="1000000"

if [[ $1 =~ ^[a-z]+$ ]]; then
transport=$1
fi

if [[ $2 =~ ^[0-9]+$ ]]; then
msgSize=$1
fi
transport=${1:-shmem}
msgSize=${2:-1000000}

SAMPLER="fairmq-ex-region-sampler"
SAMPLER+=" --id sampler1"
Expand Down
12 changes: 2 additions & 10 deletions examples/region/fairmq-start-ex-region.sh.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,8 @@

export FAIRMQ_PATH=@FAIRMQ_BIN_DIR@

transport="shmem"
msgSize="1000000"

if [[ $1 =~ ^[a-z]+$ ]]; then
transport=$1
fi

if [[ $2 =~ ^[0-9]+$ ]]; then
msgSize=$1
fi
transport=${1:-shmem}
msgSize=${2:-1000000}

SAMPLER="fairmq-ex-region-sampler"
SAMPLER+=" --id sampler1"
Expand Down

0 comments on commit addfd07

Please sign in to comment.