Error when compiling makefile

hai…all,

I just install the QNX Momentic IDE 6.3 trial version for windows host.I try to make simple hello world program using C++ languge. The Problem is
when compile it error found in makefile.

***commands comence before first target. Stop

after i readjust the makefile still error on it, but different which:

***need separator. Stop

the make file was:

[b]all:hello.exe

clean:
   rm hello.exe main.o

hello.exe: main.o
   gcc -g -o hello main.o

main.o:
   gcc -c -g main.cpp[/b]

Its really confused me because all the source code in c++ and makefile refer from its help manual.
could anyone show me, the rules to create makefile for simple C++ proram.(etc Hello World) in QNX Momentics 6.3.?? How to solve this?
could any one suggest web pages for beginner?

all:hello.exe

clean:
rm hello.exe main.o

hello.exe: main.o
gcc -g -o hello.exe main.o

main.o: main.cpp
gcc -c -g main.cpp

The tabs are important

[b]Author Message
mario
Posted: Dec 06, 2004 - 01:37 PM


all:hello.exe

clean:
rm hello.exe main.o

hello.exe: main.o
gcc -g -o hello.exe main.o

main.o: main.cpp
gcc -c -g main.cpp

The tabs are important [/b]

Thank you mario for give me support, I’m used tabs as you said but still error which different:

*** [clean] Error 1
*** [main.o] Error 2
make * CreateProcess((null), g++ -c -g main.cpp, …) failed. The system cannot find the file specified.

Can you help me? Any one?
What wrong with my program? :question:

Ok first try g++ -c -g main.cpp on the command line to confirm your setup is ok. With what editor are you creating the file. I get the filling the format of your makefile is screwed up.

The fact that you had an error on [clean] is very suspicious.