/usr/bin/cduce_mktop is in cduce 0.6.0-1.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 | #!/bin/sh
FLAGS=
LINK=
NATIVE=true
while true; do
case "$1" in
-I)
FLAGS="$FLAGS -I $2"
shift
shift
;;
-p)
FLAGS="$FLAGS -I `ocamlfind query $2`"
LINK="$LINK -package $2"
shift
shift
;;
-l)
LINK="$LINK $2"
shift
shift
;;
-byte)
NATIVE=false
shift
;;
*)
break
;;
esac
done
TARG=$1
PRIMS=$2
if [ "${TARG}" = "" ] || [ "${PRIMS}" = "" ]; then
echo "Usage: cduce_mktop [(-I path | -p package | -l unit.cmo/cma/cmx/cmxa) ...] <target> <primitive file>"
exit 2
fi
if [ ${NATIVE} = "true" ]; then
CAML=ocamlopt
else
CAML=ocamlc
fi
echo "Effective flags for CDuce: $FLAGS"
echo "Effective flags for OCaml: $LINK"
exec ocamlfind $CAML -package cduce -o $TARG $FLAGS -linkpkg -pp "cduce --topstub $FLAGS" $LINK -impl $PRIMS
|