Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit b719941

Browse files
committed
Use same Make as FreeType's configure to build it.
Namely, it's necessary to use `gmake` on BSD, since their `make` does not work.
1 parent fecfa1a commit b719941

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

setupext.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -597,7 +597,18 @@ def do_custom_build(self, env):
597597
"--with-png=no", "--with-harfbuzz=no", "--enable-static",
598598
"--disable-shared"],
599599
env=env, cwd=src_path)
600-
subprocess.check_call(["make"], env=env, cwd=src_path)
600+
if 'GNUMAKE' in env:
601+
make = env['GNUMAKE']
602+
elif 'MAKE' in env:
603+
make = env['MAKE']
604+
else:
605+
output = subprocess.check_output(['make', '-v'],
606+
stderr=subprocess.DEVNULL)
607+
if b'GNU' not in output and b'makepp' not in output:
608+
make = 'gmake'
609+
else:
610+
make = 'make'
611+
subprocess.check_call([make], env=env, cwd=src_path)
601612
else: # compilation on windows
602613
shutil.rmtree(src_path / "objs", ignore_errors=True)
603614
msbuild_platform = (

0 commit comments

Comments
 (0)