Before logging an issue, please update to the latest release of Visual Micro from the Downloads Page.

When Logging a Support Issue in the Forum, please ensure you have also:-

  • Enabled vMicro > Compiler > Show Build Properties
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic stdlib.h: No such file or directory (Read 8218 times)
Peter Wagstaff
Newbies
*
Offline


Posts: 3
Joined: Mar 30th, 2017
stdlib.h: No such file or directory
Mar 12th, 2018 at 4:26pm
Print Post  
Hi, My installation of Atmel Studio has suddenly stopped working with the error
"arduino.h: 23:20: fatal error: stdlib.h: No such file or directory"
Am I really missing this file? I have not changed anything at all and the arduino sketches compile and upload fine with Arduino IDE.  I am running AS7.0
I am just a novice user and am uncertain exactly what to do to  fix the problem.
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: stdlib.h: No such file or directory
Reply #1 - Mar 12th, 2018 at 7:24pm
Print Post  
Please post the full build output as .txt file after enabling vMicro>compiler>verbose

Thanks
  
Back to top
IP Logged
 
Peter Wagstaff
Newbies
*
Offline


Posts: 3
Joined: Mar 30th, 2017
Re: stdlib.h: No such file or directory
Reply #2 - Mar 12th, 2018 at 8:27pm
Print Post  
Hi, thanks for the reply, as I have this problem in all sketches I just compiled "Blink" to keep it short (ish) It was working fine 4 days ago and I have changed nothing (intentionally) and all my sketches compile OK in Arduino IDE

Peter

Code
Select All
Compiling debug version of 'Blink' for 'Arduino Pro or Pro Mini w/ ATmega328P (3.3V, 8 MHz)'
Build folder: file:///C:/Users/peter/AppData/Local/Temp/VMBuilds/Blink/pro_8MHzatmega328
Additional Defines: VM_DEBUG;VM_DEBUG_ENABLE 1;VM_DEBUG_BANDWIDTH_THROTTLE_MS 50;VM_DEBUGGER_TYPE_HARDWARESERIAL 0;VM_DEBUGGER_TYPE_SOFTWARESERIAL 1;VM_DEBUGGER_TYPE_FASTSERIAL 2;VM_DEBUGGER_TYPE_USB 3;VM_DEBUGGER_TYPE_TEENSY 4;VM_DEBUGGER_TYPE_UART 5;VM_DEBUGGER_TYPE_USART 6;VM_DEBUGGER_TYPE_USBSERIAL 7;VM_DEBUGGER_TYPE_TTYUART 8;VM_DEBUGGER_TYPE_NET_CONSOLE 9;VM_DEBUGGER_TYPE_Uart 10;VM_DEBUGGER_TYPE_COSA 11;VM_DEBUGGER_TYPE_CDCSerialClass 12;VM_DEBUGGER_TYPE_HARDWARESERIAL1 13;VM_DEBUGGER_TYPE_HARDWARESERIAL2 14;VM_DEBUGGER_TYPE_HARDWARESERIAL3 15;VM_DEBUGGER_TYPE VM_DEBUGGER_TYPE_HARDWARESERIAL;VM_DEBUG_BREAKPAUSE;
Architecture Tools: mel3.5.3-arduino/bin/
GCC: 4.9.2
Sketchbook: file:\\\D:\Documents\Arduino
Sketch Include Paths
Core Include Paths
Include Path ores\arduino'
Include Path ariants\eightanaloginputs'
tmel3.5.3-arduino\bin\avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -flto -w -x c++ -E -CC -mmcu=atmega328p -DF_CPU=8000000L -DARDUINO=10805 -DARDUINO_AVR_PRO -DARDUINO_ARCH_AVR \cores\arduino" \variants\eightanaloginputs" "C:\Users\peter\AppData\Local\Temp\VMBuilds\Blink\pro_8MHzatmega328\Blink.cpp" -o "nul"
tmel3.5.3-arduino\bin\avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -flto -w -x c++ -E -CC -mmcu=atmega328p -DF_CPU=8000000L -DARDUINO=10805 -DARDUINO_AVR_PRO -DARDUINO_ARCH_AVR \cores\arduino" \variants\eightanaloginputs" "C:\Users\peter\AppData\Local\Temp\VMBuilds\Blink\pro_8MHzatmega328\Blink.cpp" -o "nul"

Blink.ino: In file included from

arduino.h: 23:20: fatal error: stdlib.h: No such file or directory
   #include <stdlib.h>
   compilation terminated


	An error was encountered during the 'Deep Search' discovery process.
	Either resolve the error or switch off the 'Deep Search Includes' option.
	Tip: When deep search is switched off, headers must be #included in the [project_name.ino] for all required libraries (for example: #include <SPI.h>)
	Tip: Deep search must be off if the project source contains links/shortcuts to code outside of the project structure. The source will have been #included using a relative path preceeded by ..\ (for example: #include "..\..\foo\foo.h")
Debug build failed for project 'Blink' 

« Last Edit: Mar 12th, 2018 at 10:19pm by Tim@Visual Micro »  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: stdlib.h: No such file or directory
Reply #3 - Mar 12th, 2018 at 10:21pm
Print Post  
Hi,

maybe you used board manager to update the avr tool chain.

Please delete this folder

C:\Users\peter\AppData\Roaming\arduino17\packages\arduino

Then restart the ide and try again.

Thanks

  
Back to top
IP Logged
 
Peter Wagstaff
Newbies
*
Offline


Posts: 3
Joined: Mar 30th, 2017
Re: stdlib.h: No such file or directory
Reply #4 - Mar 13th, 2018 at 12:03am
Print Post  
Hi Tim, many thanks for your help, that fixed the problem and I would never have got there without you.

All the best 
Peter
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: stdlib.h: No such file or directory
Reply #5 - Mar 13th, 2018 at 1:24pm
Print Post  
Thanks, I will look at why this happened but I think that it is always better to upgrade arduino ide instead of using board manager to install AVR.

The reason for this is that the Arduino Ide includes a version of AVR, so you end up with two different versions to maintain if you also install AVR via board manager.
  
Back to top
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint