星火微课系统客户端
Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. #!/bin/sh
  2. # $Id: ps2pdfwr 9344 2009-01-10 22:11:18Z till $
  3. # Convert PostScript to PDF without specifying CompatibilityLevel.
  4. # This definition is changed on install to match the
  5. # executable name set in the makefile
  6. GS_EXECUTABLE=gs
  7. gs="`dirname $0`/$GS_EXECUTABLE"
  8. if test ! -x "$gs"; then
  9. gs="$GS_EXECUTABLE"
  10. fi
  11. GS_EXECUTABLE="$gs"
  12. OPTIONS="-dSAFER"
  13. while true
  14. do
  15. case "$1" in
  16. -?*) OPTIONS="$OPTIONS $1" ;;
  17. *) break ;;
  18. esac
  19. shift
  20. done
  21. if [ $# -lt 1 -o $# -gt 2 ]; then
  22. echo "Usage: `basename $0` [options...] (input.[e]ps|-) [output.pdf|-]" 1>&2
  23. exit 1
  24. fi
  25. infile="$1";
  26. if [ $# -eq 1 ]
  27. then
  28. case "${infile}" in
  29. -) outfile=- ;;
  30. *.eps) base=`basename "${infile}" .eps`; outfile="${base}.pdf" ;;
  31. *.ps) base=`basename "${infile}" .ps`; outfile="${base}.pdf" ;;
  32. *) base=`basename "${infile}"`; outfile="${base}.pdf" ;;
  33. esac
  34. else
  35. outfile="$2"
  36. fi
  37. # We have to include the options twice because -I only takes effect if it
  38. # appears before other options.
  39. exec "$GS_EXECUTABLE" $OPTIONS -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sstdout=%stderr "-sOutputFile=$outfile" $OPTIONS -c .setpdfwrite -f "$infile"