Problems building basic Atmel Studio 7 project (Windows 10)

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

Hi

 

I recently installed Atmel Studio 7 to my Windows 10 PC for doing my first steps with programming AVR controllers.

I created a new project selected GCC C Executable project, specified my controller typ and tried to build a default project with an empty while(1) loop.

Trying to build this project always results in the error message "recipe for target GccApplication2 failed". The error message points to line 108 of the autogenerated makefile which I didnt change.

It would be great if someone please can help me. I'm completly new to Atmel Studio.

 

The complete output looks like this:

 

------ Build started: Project: GccApplication2, Configuration: Debug AVR ------
Build started.
Project "GccApplication2.cproj" (default targets):
Target "PreBuildEvent" skipped, due to false condition; ('$(PreBuildEvent)'!='') was evaluated as (''!='').
Target "CoreBuild" in file "C:\AtmelStudio\7.0\Vs\Compiler.targets" from project "c:\users\test\Documents\Atmel Studio\7.0\GccApplication2\GccApplication2\GccApplication2.cproj" (target "Build" depends on it):
    Task "RunCompilerTask"
        Shell Utils Path C:\AtmelStudio\7.0\shellUtils
        C:\AtmelStudio\7.0\shellUtils\make.exe all --jobs 12 --output-sync
c:\users\test\Documents\Atmel Studio\7.0\GccApplication2\GccApplication2\Debug\Makefile(108,1): error: recipe for target 'GccApplication2.elf' failed
        make: *** [GccApplication2.elf] Error 1
    Done executing task "RunCompilerTask" -- FAILED.
Done building target "CoreBuild" in project "GccApplication2.cproj" -- FAILED.
Done building project "GccApplication2.cproj" -- FAILED.

Build FAILED.
========== Build: 0 succeeded or up-to-date, 1 failed, 0 skipped ==========

 

Last Edited: Mon. Jan 8, 2018 - 06:55 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Which processor are you using?  Did you make changes to Studio in any way when you created GccAplication1?  Reason I ask this is because your build output reads 'GccApplication2'.

 

I just fired up my Win10 pc and loaded up Studio7 and created a new project using a mega 328 processor and simply hit build and received no errors.

 

HEre is what Studio created:

/*
 * GccApplication1.c
 *
 * Created: 1/12/2018 9:04:32 AM
 * Author : james
 */ 

#include <avr/io.h>


int main(void)
{
    /* Replace with your application code */
    while (1) 
    {
    }
}

 

And the build output:

------ Build started: Project: GccApplication1, Configuration: Debug AVR ------

Build started.

Project "GccApplication1.cproj" (default targets):

Target "PreBuildEvent" skipped, due to false condition; ('$(PreBuildEvent)'!='') was evaluated as (''!='').

Target "CoreBuild" in file "C:\Program Files (x86)\Atmel\Studio\7.0\Vs\Compiler.targets" from project "c:\users\james\Documents\Atmel Studio\7.0\GccApplication1\GccApplication1\GccApplication1.cproj" (target "Build" depends on it):

Using "RunCompilerTask" task from assembly "C:\Program Files (x86)\Atmel\Studio\7.0\Extensions\Application\AvrGCC.dll".

Task "RunCompilerTask"

Shell Utils Path C:\Program Files (x86)\Atmel\Studio\7.0\shellUtils

C:\Program Files (x86)\Atmel\Studio\7.0\shellUtils\make.exe all --jobs 2 --output-sync 

Building file: .././main.c

Invoking: AVR/GNU C Compiler : 5.4.0

"C:\Program Files (x86)\Atmel\Studio\7.0\toolchain\avr8\avr8-gnu-toolchain\bin\avr-gcc.exe"  -x c -funsigned-char -funsigned-bitfields -DDEBUG  -I"C:\Program Files (x86)\Atmel\Studio\7.0\Packs\atmel\ATmega_DFP\1.2.150\include"  -O1 -ffunction-sections -fdata-sections -fpack-struct -fshort-enums -g2 -Wall -mmcu=atmega328p -B "C:\Program Files (x86)\Atmel\Studio\7.0\Packs\atmel\ATmega_DFP\1.2.150\gcc\dev\atmega328p" -c -std=gnu99 -MD -MP -MF "main.d" -MT"main.d" -MT"main.o"   -o "main.o" ".././main.c" 

Finished building: .././main.c

Building target: GccApplication1.elf

Invoking: AVR/GNU Linker : 5.4.0

"C:\Program Files (x86)\Atmel\Studio\7.0\toolchain\avr8\avr8-gnu-toolchain\bin\avr-gcc.exe" -o GccApplication1.elf  main.o   -Wl,-Map="GccApplication1.map" -Wl,--start-group -Wl,-lm  -Wl,--end-group -Wl,--gc-sections -mmcu=atmega328p -B "C:\Program Files (x86)\Atmel\Studio\7.0\Packs\atmel\ATmega_DFP\1.2.150\gcc\dev\atmega328p"  

Finished building target: GccApplication1.elf

"C:\Program Files (x86)\Atmel\Studio\7.0\toolchain\avr8\avr8-gnu-toolchain\bin\avr-objcopy.exe" -O ihex -R .eeprom -R .fuse -R .lock -R .signature -R .user_signatures  "GccApplication1.elf" "GccApplication1.hex"

"C:\Program Files (x86)\Atmel\Studio\7.0\toolchain\avr8\avr8-gnu-toolchain\bin\avr-objcopy.exe" -j .eeprom  --set-section-flags=.eeprom=alloc,load --change-section-lma .eeprom=0  --no-change-warnings -O ihex "GccApplication1.elf" "GccApplication1.eep" || exit 0

"C:\Program Files (x86)\Atmel\Studio\7.0\toolchain\avr8\avr8-gnu-toolchain\bin\avr-objdump.exe" -h -S "GccApplication1.elf" > "GccApplication1.lss"

"C:\Program Files (x86)\Atmel\Studio\7.0\toolchain\avr8\avr8-gnu-toolchain\bin\avr-objcopy.exe" -O srec -R .eeprom -R .fuse -R .lock -R .signature -R .user_signatures "GccApplication1.elf" "GccApplication1.srec"

"C:\Program Files (x86)\Atmel\Studio\7.0\toolchain\avr8\avr8-gnu-toolchain\bin\avr-size.exe" "GccApplication1.elf"

   text    data     bss     dec     hex filename

    134       0       0     134      86 GccApplication1.elf

Done executing task "RunCompilerTask".

Using "RunOutputFileVerifyTask" task from assembly "C:\Program Files (x86)\Atmel\Studio\7.0\Extensions\Application\AvrGCC.dll".

Task "RunOutputFileVerifyTask"

Program Memory Usage : 134 bytes   0.4 % Full

Data Memory Usage : 0 bytes   0.0 % Full

Done executing task "RunOutputFileVerifyTask".

Done building target "CoreBuild" in project "GccApplication1.cproj".

Target "PostBuildEvent" skipped, due to false condition; ('$(PostBuildEvent)' != '') was evaluated as ('' != '').

Target "Build" in file "C:\Program Files (x86)\Atmel\Studio\7.0\Vs\Avr.common.targets" from project "c:\users\james\Documents\Atmel Studio\7.0\GccApplication1\GccApplication1\GccApplication1.cproj" (entry point):

Done building target "Build" in project "GccApplication1.cproj".

Done building project "GccApplication1.cproj".

 

Build succeeded.

========== Build: 1 succeeded or up-to-date, 0 failed, 0 skipped ==========

 

 

So my main question is did you change anything in the Studio configuration?

 

Jim 

If you want a career with a known path - become an undertaker. Dead people don't sue! - Kartman

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB user

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

12 cores? you lucky person :) 

 

Do a rebuild and post the output...

:: Morten

 

(yes, I work for Atmel, yes, I do this in my spare time, now stop sending PMs)