Forráskód Böngészése

Use c++11 flag in build files

Summary: Reflecting in build files that We are using c++11 features.

Reviewed By: piotr-bojanowski

Differential Revision: D15012079

fbshipit-source-id: bd07b135cdbb99802459a372831f08f3f40c20d4
Onur Çelebi 6 éve
szülő
commit
c3d145773a
2 módosított fájl, 5 hozzáadás és 5 törlés
  1. 1 1
      Makefile
  2. 4 4
      setup.py

+ 1 - 1
Makefile

@@ -7,7 +7,7 @@
 #
 
 CXX = c++
-CXXFLAGS = -pthread -std=c++0x -march=native
+CXXFLAGS = -pthread -std=c++11 -march=native
 OBJS = args.o matrix.o dictionary.o loss.o productquantizer.o densematrix.o quantmatrix.o vector.o model.o utils.o meter.o fasttext.o
 INCLUDES = -I.
 

+ 4 - 4
setup.py

@@ -98,15 +98,15 @@ def has_flag(compiler, flags):
 
 
 def cpp_flag(compiler):
-    """Return the -std=c++[0x/11/14] compiler flag.
-    The c++14 is preferred over c++0x/11 (when it is available).
+    """Return the -std=c++[11/14] compiler flag.
+    The c++14 is preferred over c++11 (when it is available).
     """
-    standards = ['-std=c++14', '-std=c++11', '-std=c++0x']
+    standards = ['-std=c++14', '-std=c++11']
     for standard in standards:
         if has_flag(compiler, [standard]):
             return standard
     raise RuntimeError(
-        'Unsupported compiler -- at least C++0x support '
+        'Unsupported compiler -- at least C++11 support '
         'is needed!'
     )