Trouble with SD logging, now got an error message I've never seen before

So i'm trying to operate an SD logger as part of a larger project, and I'm having problems making it write to a file. I tried updating the SD library, and now I have an error message I've not seen before (and don't understand!)

I'm using an Arduino Leonardo, and the Adafruit Ultimate GPS logging shield. I'm operating the GPS and data logger separately, not like the example files. The GPS was working just fine, but wasn't writing anything to the file on the SD card.

So 3 questions;

-What is this error message and how do i solve it?
-How do i make it write to the SD card?
-I've seen on forums that some say the data file must pre-exist and some say the arduino will create it, which is correct?

Here's the error message:

C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino\CDC.cpp: In member function 'available':

C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino\CDC.cpp:187:1: internal compiler error: Segmentation fault

 }

 ^

Please submit a full bug report,

with preprocessed source if appropriate.

See <http://gcc.gnu.org/bugs.html> for instructions.

lto-wrapper.exe: fatal error: C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-gcc returned 1 exit status

compilation terminated.

c:/program files (x86)/arduino/hardware/tools/avr/bin/../lib/gcc/avr/5.4.0/../../../../avr/bin/ld.exe: error: lto-wrapper failed

collect2.exe: error: ld returned 1 exit status

Multiple libraries were found for "SD.h"
 Used: F:\Documents\Arduino\libraries\SD
 Not used: C:\Program Files (x86)\Arduino\libraries\SD
exit status 1
Error compiling for board Arduino Leonardo.

and i'll attach the .cpp code file as a .txt .

Any input on both issues is much appreciated!

Data_Logger.txt (1.92 KB)

  if (SD.begin(10,11,12,13)) {

The begin() method of the SD class does not take 4 arguments.

You've apparently never heard of the F() macro. It's time you learned what it does, and why you need to use it.

You've apparently never heard of google, either, as that message has known causes.

I haven't heard of the F() macro, I'll look into it, thank you!