From 09053a21398d1d5afb44268d7207839045184d46 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Sat, 13 Aug 2022 20:28:09 +0200 Subject: make: fix compat with setuptools >= 61 Fixes #110. --- Makefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 44d826c..02d357f 100644 --- a/Makefile +++ b/Makefile @@ -7,8 +7,10 @@ VERSION := $(shell $(PYTHON) setup.py --version) TESTFLAGS = -v define buildscript -import sys,sysconfig -print("build/lib.{}-{}.{}".format(sysconfig.get_platform(), *sys.version_info[:2])) +import sys, sysconfig, setuptools +sversion = int(setuptools.__version__.split(".")[0]) +end = sys.implementation.cache_tag if sversion >= 61 else "{}.{}".format(*sys.version_info[:2]) +print("build/lib.{}-{}".format(sysconfig.get_platform(), end)) endef builddir := $(shell $(PYTHON) -c '$(buildscript)') -- cgit v1.2.1