Skip to content

Commit 900eeb0

Browse files
authored
Python 3 updates (#4)
* updated python-config * Updated travis to use python-config for py2 * Update .travis.yml * removed future imports
1 parent 79bf73b commit 900eeb0

20 files changed

+6
-21
lines changed

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ before_install:
2828
install:
2929
# We thrown away the existing repo in Docker, and copy the new one in-place
3030
- docker exec -it app /bin/bash -c "rm -rf $DOCKER_WORKING_DIR && cp -r $DOCKER_MOUNT_DIR $DOCKER_WORKING_DIR"
31-
- docker exec -it app /bin/bash -c ". \$HOME/.bashrc_mdolab && cd $DOCKER_WORKING_DIR && cp config/defaults/config.LINUX_GFORTRAN.mk config/config.mk && make"
31+
- docker exec -it app /bin/bash -c ". \$HOME/.bashrc_mdolab && cd $DOCKER_WORKING_DIR && cp config/defaults/config.LINUX_GFORTRAN.mk config/config.mk && sed -i 's/python3-config/python-config/g' config/config.mk && make"
3232

3333
script:
3434
# We need to source the mdolab bashrc before running anything

config/defaults/config.LINUX_GFORTRAN.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ CC_FLAGS = -O2 -fPIC
1313

1414
# Define potentially different python, python-config and f2py executables:
1515
PYTHON = python
16-
PYTHON-CONFIG = python-config
16+
PYTHON-CONFIG = python3-config # use python-config for python 2
1717
F2PY = f2py
1818

1919
# Define additional flags for linking

config/defaults/config.LINUX_INTEL.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ CC_FLAGS = -O2 -fPIC
1313

1414
# Define potentially different python, python-config and f2py executables:
1515
PYTHON = python
16-
PYTHON-CONFIG = python-config
16+
PYTHON-CONFIG = python3-config # use python-config for python 2
1717
F2PY = f2py
1818

1919
# Define additional flags for linking

config/defaults/config.LINUX_INTEL_SCINET.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ CC_FLAGS = -O2 -fPIC
1313

1414
# Define potentially different python, python-config and f2py executables:
1515
PYTHON = python
16-
PYTHON-CONFIG = python-config
16+
PYTHON-CONFIG = python3-config # use python-config for python 2
1717
F2PY = f2py
1818

1919
# Define additional flags for linking

config/defaults/config.OSX_GFORTRAN.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ CC_FLAGS = -O2 -fPIC
1313

1414
# Define potentially different python, python-config and f2py executables:
1515
PYTHON = python
16-
PYTHON-CONFIG = python-config
16+
PYTHON-CONFIG = python3-config # use python-config for python 2
1717
F2PY = f2py
1818

1919
# Define additional flags for linking

python/examples/test_curve.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
from __future__ import print_function
21
# This is a test script to test the functionality of the
32
# pySpline curve class
43

python/examples/test_surf.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
from __future__ import print_function
21
# This is a test script to test the functionality of the
32
# pySpline surface
43
import numpy

python/examples/test_volume.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
from __future__ import print_function
21
# This simple script test some of the volume functionality in pySpline
32
import numpy
43
from pyspline import pySpline

python/pySpline.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@
55
Contains classes for working with B-spline :class:`Curve`, :class:`Surface` and
66
:class:`Volume`
77
"""
8-
from __future__ import print_function
9-
from __future__ import division
108

119
# ===========================================================================
1210
# External Python modules

python/reg_tests/mdo_regression_helper.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
from __future__ import print_function
21
# This file contains two functions to help regression testing. The
32
# first is used to format float values with a specified absolute and
43
# relative tolerance. This information is used by the second function

0 commit comments

Comments
 (0)