/usr/bin/mkcamlp5 is in camlp5 7.01-1build1.
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 | #!/bin/sh
# mkcamlp5.sh.tpl,v
OLIB=`ocamlc -where`
LIB=/usr/lib/ocaml/camlp5
INTERFACES=
OPTS=
INCL="-I ."
while test "" != "$1"; do
case $1 in
-I) INCL="$INCL -I $2"; shift;;
-help)
echo "Usage: mkcamlp5 [options] [files]"
echo "Options:"
echo " -I <dir> Add directory in search patch for object files"
echo
echo "All options of ocamlc are also available"
echo
echo "Files:"
echo " .cmi file Add visible interface for possible future loading"
echo " .cmo file Load this file in core"
echo " .cma file Load this file in core"
exit 0;;
-*) OPTS="$OPTS $1";;
*)
j=`basename $1 .cmi`
if test "$j.cmi" = "$1"; then
first="`expr "$j" : '\(.\)' | tr 'a-z' 'A-Z'`"
rest="`expr "$j" : '.\(.*\)'`"
INTERFACES="$INTERFACES $first$rest"
else
OPTS="$OPTS $1"
fi;;
esac
shift
done
CRC=crc_$$
set -e
trap 'rm -f $CRC.ml $CRC.cmi $CRC.cmo' 0 2
$OLIB/extract_crc -I $OLIB $INCL $INTERFACES > $CRC.ml
echo "let _ = Dynlink.add_available_units crc_unit_list" >> $CRC.ml
ocamlc -I $LIB odyl.cma camlp5.cma $CRC.ml $INCL $OPTS odyl.cmo -linkall
rm -f $CRC.ml $CRC.cmi $CRC.cmo
|