Problem importing a project in Eclipse

ChibiOS public support forum for all topics not covered by a specific support forum.

Moderators: RoccoMarco, lbednarz, tfAteba

User avatar
Giovanni
Site Admin
Posts: 14891
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: Problem importing a project in Eclipse

Post by Giovanni »

Are you able to compile the demo from the command line?

Give the command "cs-make" to compile, "cs-make clean" to remove the temporary files.

Giovanni
Dave_fr
Posts: 27
Joined: Thu Feb 17, 2011 11:26 pm

Re: Problem importing a project in Eclipse

Post by Dave_fr »

It really looks like Eclipse can't find these header files. If I understand right, the Eclipse is supposed to know about the Chibios Library thanks of the following section in the makefile :

# Imported source files
CHIBIOS = ../..
include $(CHIBIOS)/boards/OLIMEX_SAM7_EX256/board.mk
include $(CHIBIOS)/os/hal/platforms/AT91SAM7/platform.mk
include $(CHIBIOS)/os/hal/hal.mk
include $(CHIBIOS)/os/ports/GCC/ARM/port.mk
include $(CHIBIOS)/os/kernel/kernel.mk
include $(CHIBIOS)/test/test.mk
include $(CHIBIOS)/ext/fatfs/fatfs.mk


Right ?

So now, I'm thinking that there is a problem when Eclipse tries to read this section. I looked at what liamstask said, also looked in the project settings. I found that the option "automatically generate a makefile" was ticked so I unticked suspecting this was causing Eclipse to build his own makefile and therefore forced it to ignore the demos makefile. Obviously didn't work.

I must say that I'm running out of ideas ...
Dave_fr
Posts: 27
Joined: Thu Feb 17, 2011 11:26 pm

Re: Problem importing a project in Eclipse

Post by Dave_fr »

Giovanni wrote:Are you able to compile the demo from the command line?

Give the command "cs-make" to compile, "cs-make clean" to remove the temporary files.

Giovanni


With windows CMD prompt I changed directory to the first demo "ARM7-AT91SAM7X-FATFS-GCC". Then I just typed "cs-make" and it says :

"Makefile:53: ../../ext/fatfs/fatfs.mk: No such file or directory
'test' isn't recognized as an internal command or external, an executable program or a command file.
a sub folder or a file already exists.
The path isn't accessible.
cs-make: *** No rule to make target '../../ext/fatfs/fatfs.mk'. Stop.

Typing cs-make clean doesn't make any difference...

Dave
User avatar
Giovanni
Site Admin
Posts: 14891
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: Problem importing a project in Eclipse

Post by Giovanni »

It is because FatFs is not present under ./ext, it is delivered as a zip file, you have to unzip it under ext then the demo should compile.

I think you didn't follow exactly the "import" procedure described in the guide, probably you should delete the project from Eclipse and start over.

Giovanni
Dave_fr
Posts: 27
Joined: Thu Feb 17, 2011 11:26 pm

Re: Problem importing a project in Eclipse

Post by Dave_fr »

No doubt I didn't do what I was suppose to somewhere along the line LOL

Can you please post the URL of the 'import procedure page". I must obviously not be looking at the right place. I'm looking and looking but can't find anything talking about FatFs...
User avatar
Giovanni
Site Admin
Posts: 14891
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: Problem importing a project in Eclipse

Post by Giovanni »

Wait, there are two distinct issues, the first issue is that you are unable to compile the demo from the command line. You must unpack FatFs in order to compile, read the file ./ext/readme.txt

If you are able to compile from the command line then follow this procedure in order to import the project under eclipse and be able to compile from there:
http://www.chibios.org/dokuwiki/doku.ph ... to_eclipse

Giovanni
Dave_fr
Posts: 27
Joined: Thu Feb 17, 2011 11:26 pm

Re: Problem importing a project in Eclipse

Post by Dave_fr »

Well it looks like this was a big step forward. I unpackedeverything ect...
Now, when I try to compile with the command line it doesn't complain about not finding fatfs anymore but there is still the remaining "test isn't recognize as an internal command".

Thank for your help Giovanni !
User avatar
Giovanni
Site Admin
Posts: 14891
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: Problem importing a project in Eclipse

Post by Giovanni »

Please post an image of the error, that will help me understand.

Giovanni
Dave_fr
Posts: 27
Joined: Thu Feb 17, 2011 11:26 pm

Re: Problem importing a project in Eclipse

Post by Dave_fr »

It's in French ...
Image
User avatar
Giovanni
Site Admin
Posts: 14891
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: Problem importing a project in Eclipse

Post by Giovanni »

Ok, I think you need the Unix-like commands, please install the YAGARTO-tools from here:

http://www.yagarto.de/

The tools also include make.exe, use this one when compiling. Make sure that the path of the tools is the first one in the PATH variable.

Giovanni
Post Reply