lex.py: 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/lib64/xulrunner-devel-17.0.10/sdk/bin/ply/lex.py - from package: xulrunner-devel
/usr/lib/xulrunner-devel-17.0.10/sdk/bin/ply/lex.py - from package: xulrunner-devel

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

On Debian possible default full paths are:

/usr/lib/icedove-devel/sdk/bin/ply/lex.py - from package: icedove-dev

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