Skip to content
This repository was archived by the owner on Jan 30, 2023. It is now read-only.

Commit 0dd9c50

Browse files
author
Matthias Koeppe
committed
Respect environment variable MAKE
1 parent 3a8cc0e commit 0dd9c50

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/setup.py

+5-4
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@
22
from __future__ import print_function
33

44
import os, sys, time, errno, platform, subprocess, glob
5-
from distutils.core import setup
6-
5+
from distutils.core import setup, DistutilsSetupError
76

87
def excepthook(*exc):
98
"""
@@ -107,9 +106,11 @@ def excepthook(*exc):
107106
### Generate some Python/Cython sources
108107
#########################################################
109108

110-
status = subprocess.call("make -f generate_py_source.mk", shell=True)
109+
make = os.environ.get("MAKE", 'make')
110+
make_cmdline = make + " -f generate_py_source.mk"
111+
status = subprocess.call(make_cmdline, shell=True)
111112
if status != 0:
112-
raise DistutilsSetupError("make -f generate_py_source.mk failed")
113+
raise DistutilsSetupError("{} failed".format(make_cmdline))
113114

114115
#########################################################
115116
### Testing related stuff

0 commit comments

Comments
 (0)