Hi guys I am trying to compile a C program from PHP with exec and with Laravel Framework but I dont think this is the problem because I can compile and execute C programs from terminal without problems and if you know from tinker in Laravel 5 so the problem is from PHP but I can`t find the error I think the problem is form different versions of GCC but why let me compile from terminal.
I get this error when I do that from PHP. If I compile from terminal it works but from php not.
$path = public_path("testing/cosas.out");
exec("gcc testing/pruebaC.c -o testing/from.out 2>&1",$output,$status);
dd($output,$status); //is like var_dump
AND I GET THIS !!
Blockquote gcc: error trying to exec 'cc1': execvp: No such file or directory"
I checked the permissions and are right in fact I did chmod 777 in my desperation XD Also I try to reinstall everything but it doesnt work. I am frustrated guys I hope you can help me please.
Sorry for my english if I made a grammatically mistake thanks I wait for your help :D
from Compiling C from PHP with exec error trying to exec 'cc1'
No comments:
Post a Comment