Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support C++14 #202

Merged
merged 1 commit into from
Oct 6, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ cache:
matrix:
fast_finish: false

image: Visual Studio 2017

install:
- ps: wget https://gitlab.com/libeigen/eigen/-/archive/3.3.7/eigen-3.3.7.zip -outfile eigen3.zip
Expand Down
2 changes: 1 addition & 1 deletion examples/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
EIGEN_INCLUDE_DIR?=/usr/include/eigen3

CC=g++
CFLAGS=-std=c++11 -O3 -Wall -I/usr/include -I../include -I$(EIGEN_INCLUDE_DIR) -fopenmp -march=native
CFLAGS=-std=c++14 -O3 -Wall -I/usr/include -I../include -I$(EIGEN_INCLUDE_DIR) -fopenmp -march=native
LFLAGS=-L/usr/lib -lm -fopenmp

all: example-cpp
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def cythonize(x, compile_time_env=None):
if platform.system() == 'Windows':
USE_OPENMP = False
cflags_default = "-static -O3 -Wall -fPIC"
extra_link_args_CPP = ["-std=c++11 -static", "-static-libgfortran", "-static-libgcc"]
extra_link_args_CPP = ["-std=c++14 -static", "-static-libgfortran", "-static-libgcc"]
elif platform.system() == 'Darwin':
cflags_default = "-O3 -Wall -fPIC -shared -Xpreprocessor -fopenmp -lomp -mmacosx-version-min=10.9"
libraries += ["omp"]
Expand Down Expand Up @@ -123,7 +123,7 @@ def cythonize(x, compile_time_env=None):
library_dirs=['/usr/lib', '/usr/local/lib'] + LD_LIBRARY_PATH,
libraries=libraries,
language="c++",
extra_compile_args=["-std=c++11"] + CFLAGS,
extra_compile_args=["-std=c++14"] + CFLAGS,
extra_link_args=extra_link_args_CPP)
], compile_time_env={'_OPENMP': USE_OPENMP, 'LAPACKE': USE_LAPACK})
else:
Expand Down
2 changes: 1 addition & 1 deletion tests/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# limitations under the License.
EIGEN_INCLUDE_DIR ?= /usr/include/eigen3
CC = g++
CFLAGS = -std=c++11 -O3 -g -Wall -fopenmp -fPIC -I/usr/include \
CFLAGS = -std=c++14 -O3 -g -Wall -fopenmp -fPIC -I/usr/include \
-I../include -I$(EIGEN_INCLUDE_DIR) -I$(GOOGLETEST_DIR)/include \
-march=native

Expand Down