title: G++ does not seem to recognize -std=c++11
body: <p>I compile my code with the flag <code>-std=c++11</code> given, and I get all kinds of errors depicting that I should use the same flag. Also, <code>auto</code> is not recognised being a type.  </p>
  
  <p>Makefile:</p>
  
  <pre><code>GCCPATH = /path/gcc/5.3.0
  CC = $(GCCPATH)/bin/g++
  DARGS = -ggdb               #debug arguments
  CARGS = -std=c++11          #C arguments
  WARGS = -Wall -Wextra       #warning arguments
  AARGS = $(DARGS) $(CARGS) $(WARGS)  #all arguments
  GCCLIBPATH = $(GCCPATH)/lib64
  LIBS = -l curl
  LIBD = -L $(GCCLIBPATH) -Wl,-rpath=$(GCCLIBPATH)
  
  .PHONY: webspider
  
  webspider: ../title/htmlstreamparser.o filesystem.o
      $(CC) $(AARGS) -o $@ $@.cpp $+ $(LIBS) $(LIBD)
  
  filesystem:
      $(CC) $(AARGS) -c $@.cpp
  </code></pre>
  
  <p>The warnings and errors I get:</p>
  
  <pre><code>warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11
  warning: range-based ‘for’ loops only available with -std=c++11 or -std=gnu++11
  error: ‘weblink’ does not name a type
    for(auto weblink: weblinks)
  </code></pre>
  
  <p>Now my question is: What should I do to make g++ recognise this clearly given flag?<br>
  I also tried to replace it with <code>-std=c++0x</code>, to no avail.</p>
  
  <p>EDIT:<br>
  Full output of <code>make</code>:</p>
  
  <pre><code>g++    -c -o filesystem.o filesystem.cpp
  In file included from filesystem.cpp:1:0:
  filesystem.hpp:23:36: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11
     std::string dir = getCurrentPath();
                                      ^
  filesystem.cpp: In member function ‘std::__cxx11::string Filesystem::createMD5(std::__cxx11::string)’:
  filesystem.cpp:49:19: warning: range-based ‘for’ loops only available with -std=c++11 or -std=gnu++11
    for(long long c: result)
                     ^
  filesystem.cpp: In member function ‘void Filesystem::createLinkIndex(std::__cxx11::string, strVec)’:
  filesystem.cpp:57:11: error: ‘weblink’ does not name a type
    for(auto weblink: weblinks) {
             ^
  filesystem.cpp:61:1: error: expected ‘;’ before ‘}’ token
   }
   ^
  filesystem.cpp:61:1: error: expected primary-expression before ‘}’ token
  filesystem.cpp:61:1: error: expected ‘;’ before ‘}’ token
  filesystem.cpp:61:1: error: expected primary-expression before ‘}’ token
  filesystem.cpp:61:1: error: expected ‘)’ before ‘}’ token
  filesystem.cpp:61:1: error: expected primary-expression before ‘}’ token
  make: *** [filesystem.o] Error 1
  </code></pre>