cancel
Showing results for 
Search instead for 
Did you mean: 

Compilation Problem

gilly_kumar
Occasional Visitor

Compilation Problem

Hi
Please help me in this regards

My Code Looks likes this

#include
main()
{
printf("Hai\n");
}

My Make File looks like this

CC=gcc

all:calc.exe

calc.exe:calc.cpp
$(CC) $(CFLAGS) -c calc.cpp -o calc.exe

clean:
echo "clean is called"



I get an Error


C:\>make all
gcc -c -I C:\Symbian\7.0s\Series60_v21_CW\Epoc32\include\libc -I C:\Symbian\7.
0s\Series60_v21_CW\Epoc32\include\libc\sys calc.cpp
In file included from calc.cpp:1:
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:145: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:146: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:147: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:161: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:162: syntax e
rror before `char'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:163: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:164: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:165: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:166: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:167: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:168: syntax e
rror before `void'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:169: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:170: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:171: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:172: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:173: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:174: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:175: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:176: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:177: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:178: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:179: syntax e
rror before `char'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:180: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:181: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:182: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:183: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:184: syntax e
rror before `char'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:185: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:186: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:187: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:188: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:189: syntax e
rror before `fread'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:190: syntax e
rror before `fwrite'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:191: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:192: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:193: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:194: syntax e
rror before `long'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:195: syntax e
rror before `void'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:196: syntax e
rror before `void'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:197: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:198: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:199: syntax e
rror before `void'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:201: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:202: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:203: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:211: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:217: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:218: syntax e
rror before `*'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:226: syntax e
rror before `void'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:233: syntax e
rror before `int'
C:\\Symbian\\7.0s\\Series60_v21_CW\\Epoc32\\include\\libc\\stdio.h:234: syntax e
rror before `int'
calc.cpp: In function `int main()':
calc.cpp:4: warning: implicit declaration of function `int printf(...)'

Please help me..

Thanks

Gilly

1 REPLY
Ralf Puchner
Honored Contributor

Re: Compilation Problem

First, gcc is not the standard cc compiler for Tru64 and as seen from the error output it is a "windows" problem and not a unix problem due to "windows"-path specifications. Seems your environment variables are not defined properly.
Help() { FirstReadManual(urgently); Go_to_it;; }