LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Closed Thread
  Search this Thread
Old 04-09-2012, 02:28 AM   #1
raju39k
LQ Newbie
 
Registered: Apr 2012
Posts: 4

Rep: Reputation: Disabled
Post Make file error make: *** [exec] Error 12


While i am running my make file i am getting the following error


$ make -f AIQ2.make
make: Warning: File `AIQ2.make' has modification time 8.4e+02 s in the future
gcc AIQ2.c -o AIQ2
echo "Compile Completed"
Compile Completed
./AIQ2 < input.txt > output.txt
make: *** [exec] Error 12

Here is My makefile

all:compile exec clean

compile:
gcc AIQ2.c -o AIQ2
echo "Compile Completed"
exec:
./AIQ2 < input.txt > output.txt
cat output.txt
clean:
rm AIQ2 output.txt
echo "Clean completed"


Here is my C program:


#include "AIQ2.h"
main()
{
char c;
printf("(a) Print the word \"hello\"\n");
printf("(b) Print the number \"2\"\n");
printf("(c) Print \"Good choice\"\n");
printf("(d) Do nothing\n\n");
printf("Enter choice:");
scanf("%c",&c);
printf("\nYour Choice is :%c",c);
printf("\nOutput is :");
switch(c)
{
case 'a'rintf("hello\n");
break;
case 'b'rintf("2\n");
break;
case 'c'rintf("Good choice\n");
break;
case 'd':break;
default rintf("You have selected an invalid option\n");
return 0;
}
}
 
Old 04-09-2012, 02:32 AM   #2
Nylex
LQ Addict
 
Registered: Jul 2003
Location: London, UK
Distribution: Slackware
Posts: 7,464

Rep: Reputation: Disabled
Please don't post the same thread more than once. I've reported this as a duplicate. The original is here.
 
Old 04-09-2012, 02:49 AM   #3
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place. This thread is being closed because it is a duplicate.

If you want to change or add information to your original post, you can use the EDIT button in the lower-right corner of the post itself.
 
  


Closed Thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Make file Error. pinga123 Linux - Newbie 1 11-30-2011 05:50 AM
make with make file yields error: /usr/bin/javac: cannot execute binary file bweaver Ubuntu 4 11-19-2010 02:58 PM
RH9 make menuconfig error: make[1]: *** [lxdialog] Error 1 rrochele Linux - Kernel 3 02-07-2007 03:39 PM
ERROR in make file sajjadc Linux - Kernel 1 04-30-2006 07:22 AM
file-4.10 make error alexchao Linux From Scratch 2 05-25-2005 08:24 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:01 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration