diff --git a/f2py-shebang.patch b/f2py-shebang.patch new file mode 100644 index 0000000..34caebd --- /dev/null +++ b/f2py-shebang.patch @@ -0,0 +1,22 @@ +diff --git a/numpy/f2py/setup.py b/numpy/f2py/setup.py +index 1fae545..96a047e 100644 +--- a/numpy/f2py/setup.py ++++ b/numpy/f2py/setup.py +@@ -53,7 +53,7 @@ def configuration(parent_package='',top_path=None): + log.info('Creating %s', target) + f = open(target,'w') + f.write('''\ +-#!/usr/bin/env %s ++#!%s + # See http://cens.ioc.ee/projects/f2py2e/ + import os, sys + for mode in ["g3-numpy", "2e-numeric", "2e-numarray", "2e-numpy"]: +@@ -77,7 +77,7 @@ else: + sys.stderr.write("Unknown mode: " + repr(mode) + "\\n") + sys.exit(1) + main() +-'''%(os.path.basename(sys.executable))) ++'''%(sys.executable)) + f.close() + return target + diff --git a/numpy.spec b/numpy.spec index 2f2f2c7..050be28 100644 --- a/numpy.spec +++ b/numpy.spec @@ -18,6 +18,7 @@ Group: Development/Languages License: BSD and Python URL: http://numeric.scipy.org/ Source0: http://downloads.sourceforge.net/numpy/%{name}-%{version}%{?relc}.tar.gz +Patch1: f2py-shebang.patch BuildRequires: python2-devel lapack-devel python-setuptools gcc-gfortran atlas-devel python-nose Requires: python-nose @@ -83,7 +84,7 @@ This package includes a version of f2py that works properly with NumPy. %prep %setup -q -n %{name}-%{version}%{?relc} - +%patch1 -p1 # workaround for rhbz#849713 # http://mail.scipy.org/pipermail/numpy-discussion/2012-July/063530.html rm numpy/distutils/command/__init__.py && touch numpy/distutils/command/__init__.py @@ -246,6 +247,7 @@ popd &> /dev/null * Tue Jul 30 2013 Tomas Tomecek - 1:1.7.1-3 - Fix rpmlint warnings - Update License +- Apply patch: change shebang of f2py to use binary directly * Sun Jun 2 2013 Orion Poplawski - 1:1.7.1-2 - Specfile cleanup (bug #969854)