LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   running a C program from shell script (https://www.linuxquestions.org/questions/linux-newbie-8/running-a-c-program-from-shell-script-643159/)

jkeertir 05-18-2008 11:36 PM

running a C program from shell script
 
Dear ALl,

I am unable to run a C program from a shell script.I have compiled a C program using gcc.I want to run this C program from a shell script .Is it possible to run a C program from shell script.

Please can anyone help me to solve this issue.

With Regards,
Keerti

chrism01 05-19-2008 12:00 AM

Well, please show us what you've tried, but basically its:

#!/bin/bash
/path/to/cprog

jkeertir 05-19-2008 12:41 AM

Dear chrism01

Thanks .it is working.I was trying it as
./path/of/cprog/
and
`. /path/of/cprog/`

With regards
keerti

H_TeXMeX_H 05-19-2008 05:05 AM

The dot '.' stands for the current directory.


All times are GMT -5. The time now is 11:40 AM.