How to fix "*** [obj/flash_board_cstartup.o] Error 2"

Hello,

I am new to ARM. Right I am trying to get up to speed with the SAM7S examples pack "at91sam7s-ek" available from the Microchip website.

When I load any project into Eclipse I get the following error After building project.

make: *** [obj/flash_board_cstartup.o] Error 2

I have checked that paths are correct and that the files are where they are supposed to be.

Is there anyone that can help me to get this running or can anyone recommend a better set of examples that actually work for the SAM7S devices.

Parents
  • I'm not familiar with Atmel projects, but since you have the GNU ARM Eclipse plug-ins installed, I guess you are trying to use them to build the project.

    In Eclipse there are two types of projects, managed and unmanaged. Unmanaged projects have their own make files, and all Eclipse has to do is to start make properly, there is not much to configure to pass the build (there are some details related to the indexer, but they are not relevant for the build).

    Managed projects are collections of source files, object files and libraries, that you want Eclipse to magically turn into a binary executable.

    For this you need to tell Eclipse where are the source files, what options to use for each separate tool (compiler, assembler, linker, etc), where are the objet files, where are the libraries, where are the linker scripts, and so on. The configuration is a bit more elaborate, but you don't have to write any make file yourself, Eclipse (in fact the GNU ARM build plug-ins) does this for you.

    From the structure of the project, I would guess it is a Makefile project, and the error seems a make error. You can still build Makefile projects as managed projects, but you need to do the configuration.

    For example, to incorporate already compiled object files, you need to add them to the linker list of 'Other objects':

    Linker_Other objects.png

    If you can provide more details about the project and the steps you did to end in this situation, maybe I can be of more help.

    Regards,

    Liviu

Reply
  • I'm not familiar with Atmel projects, but since you have the GNU ARM Eclipse plug-ins installed, I guess you are trying to use them to build the project.

    In Eclipse there are two types of projects, managed and unmanaged. Unmanaged projects have their own make files, and all Eclipse has to do is to start make properly, there is not much to configure to pass the build (there are some details related to the indexer, but they are not relevant for the build).

    Managed projects are collections of source files, object files and libraries, that you want Eclipse to magically turn into a binary executable.

    For this you need to tell Eclipse where are the source files, what options to use for each separate tool (compiler, assembler, linker, etc), where are the objet files, where are the libraries, where are the linker scripts, and so on. The configuration is a bit more elaborate, but you don't have to write any make file yourself, Eclipse (in fact the GNU ARM build plug-ins) does this for you.

    From the structure of the project, I would guess it is a Makefile project, and the error seems a make error. You can still build Makefile projects as managed projects, but you need to do the configuration.

    For example, to incorporate already compiled object files, you need to add them to the linker list of 'Other objects':

    Linker_Other objects.png

    If you can provide more details about the project and the steps you did to end in this situation, maybe I can be of more help.

    Regards,

    Liviu

Children