make: *** (file-name.o) Error 1 problem

Go To Last Post
21 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I am trying to code a program using ATMega 32 and also using winAVR .. Recently I faced a problem in eclipse that every program I try to compile gives me this error:

make: *** (file-name.o) Error 1 .

it used to happen rarely but now it happens to every program in any workstation I try to compile 

This topic has a solution.
Last Edited: Mon. Apr 2, 2018 - 08:42 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You need to get the actual full message, not just the summary. The actual message would have been on the line before that in the output.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Once again the "error list" is a source of nothing but confusion. They should just remove it or at least add a message to say "this list is in the wrong order and may not be complete, please see" Output" for real reason for failure "

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

how can I view this full message , there is no line before these two error lines

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Oh sorry this is Eclipse not AS7? It seems to suffer from the same thing, somewhere there must be a way to see all the build commands and all the output they produce, perhaps the tab called "Console" or "Problem details"? What you are looking for is the first occurrence of "error"

This reply has been marked as the solution. 
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

the problem is solved .. I actually don't know what happened .. I deactivated the windows defender in windows 10 .. and it worked for all programs ... I then activated it again and it works too .. so I really don't get how the windows defender affected it .. it's just that someone told me to disable any anti-virus I have

Last Edited: Mon. Apr 2, 2018 - 05:15 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

That seems like an extremely bad idea, I would recommend investigating further to find out what the actual failure was. I don't know how to explore further in Eclipse, but those messages are just the tail end of a list of messages. Basically, the "make" program runs, and if it encounters an error, after it has listed the error, it says "*** [filename] Error 1".

 

But that's not the relevant error, that's just make telling you that a previous program failed.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

clawson wrote:
[Eclipse] seems to suffer from the same thing

Yes, it does - I may have mentioned it before ... ?

 

somewhere there must be a way to see all the build commands and all the output they produce, perhaps the tab called "Console"

Yes, 'Console' is the one.

 

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

It's probably that your anti-virus is seeing some "suspect" patterns in the object files generated by your build.

 

This is not uncommon - I've seen it before.

 

The thing to do is to set up an "exception" for your AV to tell it to ignore the .o files (or whatever) in your build folder.

You will have to RTFM for specific details.

 

But, whatever you do, do not work with AV disabled globally!!

 

surprise

 

EDIT

 

typo

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Just wondering why someone using Windows 10 would be using Eclipse and not AS7? How, for example, do you run a simulator while using Eclipse?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I was using AS7 and it's very good .. but an instructor told me that it's better to get used to eclipse platform .. as I remember because it can include an arm toolchain.. and I found that eclipse is a very common tool used in embedded systems courses in my country (more than AS7).. these are the reasons only .. I would be glad to know your opinion about it

 

Last Edited: Mon. Apr 2, 2018 - 08:29 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1

AS7 is undoubtedly the best development system for AVR and Atmel ARM chips. But yes Eclipse is perhaps the most widely used IDE for a whole range of other chips. So I guess there's some merit in learning how to use it.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

If this is make related, then it could be that a souce file was compiled to completion, but with some error.

Second time make does not re-compile the file if it thinks the object is still up to date and you do not see the error anymore.

 

I'm using Qt Creator and it has also adopted the (mostly) useless idea of hiding a big part of error messages.

Luckily it is very easy to show the full compiler output in Qt Creator.

But when I suspect compilation problems I very quickly turn to running make from the commandline without any IDE in between.

 

On Line number 2 of your screenshot I see a [FILE NAME] ... That would not seem like proper C syntax.

Doing magic with a USD 7 Logic Analyser: https://www.avrfreaks.net/comment/2421756#comment-2421756

Bunch of old projects with AVR's: http://www.hoevendesign.com

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ali_aw1995 wrote:
an instructor told me that it's better to get used to eclipse platform .. as I remember because it can include an arm toolchain.

Of course, Atmel Studio also includes the GCC ARM toolchain - that's why they changed the name from "AVR Studio" to "Atmel Studio"

 

But the best option would be to understand how IDEs in general work - they all do the same job, and have basically the same settings to be managed.

 

If you're being led by an instructor, surely she/he could have pointed out this issue with the "Problems" list - and shown you where to find the full details?

It's such a basic issue...

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ali_aw1995 wrote:
.. as I remember because it can include an arm toolchain.. 
GNU arm GCC and FOSS arm LLVM can be a part of Microsoft Visual Studio but the functional GDB extension is not zero price (approx 100USD); the better option may be Microsoft Visual Studio Code as it has zero price extensions.

If willing to move to C# then there's a zero price FOSS (Apache) Visual Studio 2017 extension with a debugger.

 

https://marketplace.visualstudio.com/search?term=tag%3Amcu&target=VS&category=All%20categories&vsVersion=&sortBy=Relevance

https://marketplace.visualstudio.com/search?term=tag%3Agdb&target=VS&category=All%20categories&vsVersion=&sortBy=Relevance

https://marketplace.visualstudio.com/search?term=tag%3Amcu&target=VSCode&category=All%20categories&sortBy=Relevance

https://marketplace.visualstudio.com/search?term=tag%3Agdb&target=VSCode&category=All%20categories&sortBy=Relevance (Cortex-Debug, Native Debug)

C# :

nanoFramework

One small ‘step’ for a debugger, one giant leap for the embedded world!!

by José Simões

December 12, 2017

https://nanoframework.net/2017/12/12/one-small-step-for-a-debugger-one-giant-leap-for-the-embedded-world/

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

 

I am having the same error, although turning-ff Windows Defender on my WIN10 didn't work.
Below is the Screenshot of the Eclipse IDE showing both the error and Cosole window after building. I have no clue whats happening. Please someone help me.

Below is the complete output of the Console Window

 

01:39:46 **** Incremental Build of configuration Debug for project AVRCode ****
make all 
Building file: ../main.c
Invoking: AVR Compiler
avr-gcc -Wall -g2 -gstabs -O0 -fpack-struct -fshort-enums -ffunction-sections -fdata-sections -std=gnu99 -funsigned-char -funsigned-bitfields -mmcu=atmega328p -DF_CPU=16000000UL -MMD -MP -MF"main.d" -MT"main.d" -c -o "main.o" "../main.c"
make: *** [main.o] Error -1073741502

01:39:51 Build Finished (took 4s.870ms)

 

Manish Verma

Last Edited: Fri. Oct 2, 2020 - 08:11 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

That is a very strange behavior. What happened is that the avr-gcc program exited with a very strange exit status, without emitting any messages. Usually exit status is 0 for success, 1 for failure, and sometimes other small positive numbers also for failure. a large negative number is just weird.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Casting -1073741502 to unsigned 32-bit I get

0xc0000142 .

Iluvatar is the better part of Valar.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0


antiqueverma wrote:
I am having the same error

No, it's not the same error at all.

 

Your error:

 

 

The original error:

 

 

Not the same at all!

 

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Yes, this is the value ( 0xc0000142 ) Im getting in the error popup window.

Manish Verma

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Have you ever had this setup working?

 

If you run avr-gcc from the command-line, does it work?

 

antiqueverma wrote:

Below is the complete output of the Console Window

 

01:39:46 **** Incremental Build of configuration Debug for project AVRCode ****

Instead of an incremental build, what happens if you do a clean first, and then a full rebuild?

 

 

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...