Intel® Makers
Intel® Edison, Intel® Joule™, Intel® Curie™, Intel® Galileo
Announcements
Welcome - This is a Peer-to-Peer Forum only. Intel has discontinued these products but you may find support from other customers on this Forum
9868 Discussions

SD Library compilation error

FBoco
Novice
2,207 Views

I am testing a sketch and a library I wrote myself which use SD library. They run on Arduino.

When I compile for Galileo I get this error:

Arduino: 1.5.3 (Mac OS X), Board: "Intel® Galileo"

In file included from MyTest.ino:1:0:

/Users/fab/Downloads/Galileo/Arduino.app/Contents/Resources/Java/hardware/arduino/x86/libraries/SD/SD.h:5:18: fatal error: string: No such file or directory

compilation terminated.

Where am I wrong ?

0 Kudos
12 Replies
ADRIAN_B_Intel
Employee
288 Views

Hi,

When you say they run on Arduino you mean Arduino Uno?

Please attach the sketch and library or link to it so that we can replicate it here and help you.

many thanks,

-a

FBoco
Novice
288 Views

Hi Ado,

thank you for your support.

I have realized that also a very simple sketch including the SD library has compilation problems.

# include

void setup() {

// put your setup code here, to run once:

}

void loop() {

// put your main code here, to run repeatedly:

}

This is the error message:

Arduino: 1.5.3 (Mac OS X), Board: "Intel® Galileo"

In file included from sketch_oct14a.ino:1:0:

.../Arduino.app/Contents/Resources/Java/hardware/arduino/x86/libraries/SD/SD.h:5:18: fatal error: string: No such file or directory

compilation terminated.

clayton_H_Intel
Employee
288 Views

 

Just as a point of reference, I do not have the problem of compiling with an the SD library included.

I am using the IDE 1.5.3 for windows (Windows 7). Maybe this is only a problem on the Mac OS?

nTier1
Beginner
288 Views

I had a similar error on my windows 7 system. It seemed to be a communication problem with the drivers. I was going to roll back the drivers and try installing them again, but the error stopped after a reboot. Not sure if this will work for the mac.

FBoco
Novice
288 Views

I have tested the code on Windows 8 and it works. Problem appears related to the IDE on MAC.

Thanks.

MARC_H_Intel
Employee
288 Views

Hi,

This is a bug in the way Yocto builds the gcc toolchain for the Mac. The net effect is that C++ .h header files are not found. As a workaround, can you please try to create a symbolic link like this?

ln -s . hardware/tools/x86/i586-poky-linux-uclibc/usr/include/c++/4.2.1/

FBoco
Novice
288 Views

Hi Marclll,

thank you so much. It works !

Fab.

MARC_H_Intel
Employee
288 Views

For future reference and documentation the number for this Mac issue is # 55636

ANaga3
Beginner
288 Views

How does one make a symbolic link? Can I just cut and past that line into my Terminal? Or, do I need to navigate to a specific folder first?

Any help would be appreciated!

CMaw
Novice
288 Views

Don't copy and paste, retype the line into terminal inside your Arduino For Galileo app folder. (mine is called ArduiG)

cd /Applications/ArduiG.app/Contents/Resources/Java

ln -s . hardware/tools/x86/i586-poky-linux-uclibc/usr/include/c++/4.2.1

Thanks to todbot who helped me figure that out.

By the way, with this solution the syntax highlighting will still not be correct.

ANaga3
Beginner
288 Views

Thank you! That worked for me.

RDutt2
Beginner
288 Views

I am attempting to run one of the included SD sketches and I had an original problem that I've past (or so I think) and a current problem that sounds like the same one being described here. However I'm on a Windows 7 machine.

So initially when I would attempt to compile a SD sketch it would stop with an error message saying Galileo board not supported. I was able to get past this error by changing the windows property on the Arduino.exe to run as administrator.

Now the compile fails is still present but stops saying "fatal error: string: No such file or directory". I don't know how to run the linker from the command line in windows7 so the answer above hasn't solved my problem.

Any suggestions or help would be appreciated.

Bob D.

Reply