1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34
  
     | 
    
      From: Juhani Numminen <juhaninumminen0@gmail.com>
Date: Sun, 29 Mar 2020 18:30:10 +0300
Subject: python3.8-platform.dist
platform.dist was removed in python 3.8.
Origin: https://github.com/unknown-horizons/unknown-horizons/pull/2910
Bug-Debian: https://bugs.debian.org/954632
---
 setup.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/setup.py b/setup.py
index 7f7a4ba..29da82b 100755
--- a/setup.py
+++ b/setup.py
@@ -32,6 +32,8 @@ from distutils.core import setup
 from distutils.spawn import find_executable
 from shutil import copytree, rmtree
 
+import distro
+
 import horizons
 from horizons.constants import VERSION
 from horizons.ext import polib
@@ -39,7 +41,7 @@ from horizons.ext import polib
 # Ensure we are in the correct directory
 os.chdir(os.path.realpath(os.path.dirname(__file__)))
 
-if platform.dist()[0].lower() in ('debian', 'ubuntu'):
+if distro.linux_distribution(full_distribution_name=False)[0] in ('debian', 'mint', 'ubuntu'):
 	executable_path = 'games'
 else:
 	executable_path = 'bin'
 
     |