link_console.sh 436 B

123456789101112131415161718
  1. #!/bin/bash
  2. # This script is run by Free Oberon on Linux. Current directory of the
  3. # script will be where FreeOberon executable is located. This
  4. # particular script is for console programs.
  5. cd bin
  6. VOCDIR=../data/bin/voc
  7. CC=gcc
  8. THENAME="${1%.*}"
  9. ONAME="${THENAME##*/}"
  10. SDL2Opts=`sdl2-config --cflags --libs`
  11. shift
  12. $CC -fPIC -g -I $VOCDIR/C/include \
  13. -o $ONAME $ONAME.o \
  14. $@ \
  15. $VOCDIR/lib/libvoc-OC.a
  16. retcode=$?
  17. cd ..
  18. exit $retcode