1--- ./setup.py.orig 2018-04-29 15:47:33.000000000 -0700
2+++ ./setup.py 2018-11-11 09:41:58.097682221 -0800
3@@ -458,8 +458,6 @@
4 if not cross_compiling:
5 add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib')
6 add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
7- if cross_compiling:
8- self.add_gcc_paths()
9 self.add_multiarch_paths()
10
11 # Add paths specified in the environment variables LDFLAGS and
12@@ -517,7 +515,10 @@
13 # be assumed that no additional -I,-L directives are needed.
14 inc_dirs = self.compiler.include_dirs[:]
15 lib_dirs = self.compiler.library_dirs[:]
16- if not cross_compiling:
17+ if cross_compiling:
18+ inc_dirs = []
19+ lib_dirs = []
20+ else:
21 for d in (
22 '/usr/include',
23 ):
24@@ -582,6 +584,8 @@ class PyBuildExt(build_ext):
25 # Some modules that are normally always on:
26 #exts.append( Extension('_weakref', ['_weakref.c']) )
27
28+ self.compiler.library_dirs = lib_dirs + [ '.' ]
29+
30 # array objects
31 exts.append( Extension('array', ['arraymodule.c']) )
32