You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

openvibe-external-application-launcher-base 560B

3 years ago
123456789101112131415161718192021222324252627282930
  1. #!/bin/bash
  2. #
  3. # This script is meant to be launched from inside an OpenViBE application (such as a scenario in Designer)
  4. #
  5. CALLCMD=$1
  6. shift
  7. ov_run_bg=0
  8. if [ "$1" == "--run-bg" ]; then
  9. ov_run_bg=1
  10. shift
  11. fi
  12. # OV_PATH_BIN overrides the CMake specified folder, if given
  13. LOCAL_BIN_PATH="@CMAKE_INSTALL_FULL_BINDIR@"
  14. if [ "$OV_PATH_BIN" != "" ]; then
  15. LOCAL_BIN_PATH="$OV_PATH_BIN"
  16. fi
  17. ret_code=0
  18. if [ $ov_run_bg == 0 ]; then
  19. eval "$LOCAL_BIN_PATH/$CALLCMD" @OV_CMD_ARGS@ $*
  20. ret_code=$?
  21. else
  22. "$LOCAL_BIN_PATH/$CALLCMD" @OV_CMD_ARGS@ $* &
  23. fi
  24. exit $ret_code