title: Error while compiling with a makefile and c++11
body: <p>I currently have a problem with a C++ project I have. I need some tools provided with C++11 but when I want to compile with a Makefile, I have the error : </p>
  
  <blockquote>
    <p>error This file requires compiler and library support for the ISO C++ 2011 standard. This support is currently experimental, and must be enabled with the -std=c++11 or -std=gnu++11 compiler options.</p>
  </blockquote>
  
  <p>Here is my Makefile : </p>
  
  <pre><code>.PHONY: clean, mrproper
  
  # var
  CXX = g++
  EXEC = tablut
  LDFLAGS = 
  CXXFLAGS = -std=c++11 -Wall -Wextra 
  SRC= partie.cpp pawn.cpp playground.cpp
  OBJ= $(SRC:.c=.o)
  
  # commands
      all: $(EXEC)
  
  tablut: $(OBJ)
      $(CXX) -o tablut $(OBJ) $(LDFLAGS)
  
  %.o: %.cpp
      $(CXX) -o $@ -c $&lt; $(CXXFLAGS) 
  
  clean:
      rm -rf *.o
  
  mrproper: clean
      rm -rf tablut
  </code></pre>
  
  <p>The funny thing is that my code compile if I enter the command g++ -c std=c++11 ...</p>
  
  <p>What did I do wrong ?</p>
  
  <p><strong>NB :</strong> I tried with the flags -std=c++11, -std=c++0x and -std=gnu++11</p>