ocamllex.opt: command not found

Have You tried accessing the binary with the full path?

Maybe Your $PATH variable doesn't contain the default paths? echo $PATH should give something like:

[root@server ~]# echo $PATH
/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin

If it's empty, You may set the PATH variable with this command

export PATH="/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin"

On CentOS possible default full paths are:

/usr/bin/ocamllex.opt - from package: ocaml

You may install the required package with command yum install {package}

On Debian possible default full paths are:

/usr/bin/ocamllex.opt - from package: ocaml-native-compilers

You may install the required package with command apt-get install {package}
Error in other languages:
ocamllex.opt: bevel nie gevind nie
ocamllex.opt: comandă negăsită
ocamllex.opt: comando não encontrado
ocamllex.opt: commande introuvable
ocamllex.opt: command not found
ocamllex.opt: käsku ei ole
ocamllex.opt: không tìm thấy lệnh
ocamllex.opt: komanda nerasta
ocamllex.opt: Kommando nicht gefunden.
ocamllex.opt: kommandot finns inte
ocamllex.opt: komut yok
ocamllex.opt: nie znaleziono polecenia
ocamllex.opt: níor aimsíodh an t-ordú
ocamllex.opt: no se encontró la orden
ocamllex.opt: no s'ha trobat l'ordre
ocamllex.opt: opdracht niet gevonden
ocamllex.opt: parancs nem található
ocamllex.opt: perintah tidak ditemukan
ocamllex.opt: príkaz nenájdený
ocamllex.opt: příkaz nenalezen
ocamllex.opt: команда не найдена
ocamllex.opt: командата не е открита
ocamllex.opt: 命令找不到
ocamllex.opt: コマンドが見つかりません