Skip to content

Commit 7707cb2

Browse files
committed
BLD: use CPPFLAGS environment variable
Anaconda compilers set CPPFLAGS environment variable. Use it when building and testing the package.
1 parent 38d000f commit 7707cb2

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ install:
111111
exit 1;
112112
fi
113113

114-
- $NOMC || MYCXXFLAGS="-I${MYINCLUDE} ${CXXFLAGS}"
114+
- $NOMC || MYCOMPILEFLAGS="-I${MYINCLUDE} ${CXXFLAGS} ${CPPFLAGS}"
115115
- $NOMC || MYLINKFLAGS="-L${MYLIB} ${LDFLAGS} -Wl,-rpath,${MYLIB}"
116116

117117

@@ -120,7 +120,7 @@ before_script:
120120

121121

122122
script:
123-
- $CXX -o testlib $MYCXXFLAGS testlib.cpp -lObjCryst $MYLINKFLAGS
123+
- $CXX -o testlib $MYCOMPILEFLAGS testlib.cpp -lObjCryst $MYLINKFLAGS
124124
- ./testlib
125125

126126

src/SConscript

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Import('env')
55
# Build environment configuration --------------------------------------------
66

77
# Apply CFLAGS, CXXFLAGS, LDFLAGS from the system environment.
8-
flagnames = 'CFLAGS CXXFLAGS LDFLAGS'.split()
8+
flagnames = 'CFLAGS CXXFLAGS CPPFLAGS LDFLAGS'.split()
99
env.MergeFlags([os.environ.get(n, '') for n in flagnames])
1010

1111
# Insert LIBRARY_PATH explicitly because some compilers

0 commit comments

Comments
 (0)