execute.sh.in 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. #!@REALBASH@
  2. # StarPU --- Runtime system for heterogeneous multicore architectures.
  3. #
  4. # Copyright (C) 2020 Université de Bordeaux, CNRS (LaBRI UMR 5800), Inria
  5. #
  6. # StarPU is free software; you can redistribute it and/or modify
  7. # it under the terms of the GNU Lesser General Public License as published by
  8. # the Free Software Foundation; either version 2.1 of the License, or (at
  9. # your option) any later version.
  10. #
  11. # StarPU is distributed in the hope that it will be useful, but
  12. # WITHOUT ANY WARRANTY; without even the implied warranty of
  13. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  14. #
  15. # See the GNU Lesser General Public License in COPYING.LGPL for more details.
  16. #
  17. set -x
  18. export JULIA_LOAD_PATH=@STARPU_SRC_DIR@/julia:$JULIA_LOAD_PATH
  19. export STARPU_BUILD_DIR=@STARPU_BUILD_DIR@
  20. export STARPU_SRC_DIR=@STARPU_SRC_DIR@
  21. export STARPU_JULIA_LIB=@STARPU_BUILD_DIR@/julia/src/.libs/libstarpujulia-1.3
  22. export STARPU_JULIA_BUILD=@STARPU_BUILD_DIR@/julia
  23. export JULIA_NUM_THREADS=8
  24. srcdir=@STARPU_SRC_DIR@/julia/examples
  25. rm -f genc*.c gencuda*.cu genc*.o
  26. if test "$1" == "-calllib"
  27. then
  28. shift
  29. pwd
  30. rm -f extern_tasks.so
  31. make -f @STARPU_BUILD_DIR@/julia/src/dynamic_compiler/Makefile extern_tasks.so SOURCES_CPU=$srcdir/$1
  32. shift
  33. export JULIA_TASK_LIB=$PWD/extern_tasks.so
  34. fi
  35. srcfile=$1
  36. if test ! -f $srcdir/$srcfile
  37. then
  38. echo "Error. File $srcdir/$srcfile not found"
  39. exit 1
  40. fi
  41. shift
  42. #cd $srcdir/$(dirname $srcfile)
  43. #@JULIA@ $(basename $srcfile) $*
  44. @JULIA@ $srcdir/$srcfile $*