You have to give him exe. permissions.
So: chmod +x new_file
When you create a new file with your gcc, this is not possible by default. Therefore, you must grant him permission to execute.
With chmod
(see this) you change file permissions.
In this particular case, you have granted execution permissions (+ [plus] means “x” means execution) to this file.
If you want to revoke this permission, you can type: chmod -x filename
source share