public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Brian Dolbec" <dolsen@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/mirrorselect:master commit in: /
Date: Sun, 10 Jul 2022 21:16:44 +0000 (UTC)	[thread overview]
Message-ID: <1657486485.5444d0ddb5268325aac63dcdeb908b614916dd0f.dolsen@gentoo> (raw)

commit:     5444d0ddb5268325aac63dcdeb908b614916dd0f
Author:     Brian Dolbec <dolsen <AT> gentoo <DOT> org>
AuthorDate: Sun Jul 10 20:54:45 2022 +0000
Commit:     Brian Dolbec <dolsen <AT> gentoo <DOT> org>
CommitDate: Sun Jul 10 20:54:45 2022 +0000
URL:        https://gitweb.gentoo.org/proj/mirrorselect.git/commit/?id=5444d0dd

Revert "setup.py: Migrate from deprecated distutils to setuptools"

This reverts commit 4cd4fb6280433f301ad9159f7473dc32ceb063d6.
setuptools is installing data_file to the pkg dir inside python.
Reverting back to distutils for correct install for now.

Signed-off-by: Brian Dolbec <dolsen <AT> gentoo.org>

 setup.py | 22 +++++++++++++++++++---
 1 file changed, 19 insertions(+), 3 deletions(-)

diff --git a/setup.py b/setup.py
index 9111d5e..a9728fa 100755
--- a/setup.py
+++ b/setup.py
@@ -5,10 +5,13 @@
 import logging
 import re
 import sys
+from distutils import core, log
+from distutils.command.sdist import sdist
+from distutils.core import Command
+
 import os
 import io
 import unittest
-from setuptools import setup, Command
 
 
 __version__ = os.getenv('VERSION', default=os.getenv('PVR', default='9999'))
@@ -34,7 +37,7 @@ manpage = [os.path.join(cwd, path) for path in (
 )]
 
 
-class set_version(Command):
+class set_version(core.Command):
 	"""Set python version to our __version__."""
 	description = "hardcode scripts' version using VERSION from environment"
 	user_options = []  # [(long_name, short_name, desc),]
@@ -66,6 +69,18 @@ class set_version(Command):
 		sub(manpage, man_re)
 
 
+class x_sdist(sdist):
+	"""sdist defaulting to archive files owned by root."""
+
+	def finalize_options(self):
+		if self.owner is None:
+			self.owner = 'root'
+		if self.group is None:
+			self.group = 'root'
+
+		sdist.finalize_options(self)
+
+
 class TestCommand(Command):
 	user_options = []
 
@@ -89,7 +104,7 @@ test_data = {
 	]
 }
 
-setup(
+core.setup(
 	name='mirrorselect',
 	version=__version__,
 	description='Tool for selecting Gentoo source and rsync mirrors.',
@@ -109,6 +124,7 @@ setup(
 	),
 	cmdclass={
 		'test': TestCommand,
+		'sdist': x_sdist,
 		'set_version': set_version,
 	},
 )


             reply	other threads:[~2022-07-10 21:16 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-10 21:16 Brian Dolbec [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-08-07  0:14 [gentoo-commits] proj/mirrorselect:master commit in: / Sam James
2022-05-31 18:56 Brian Dolbec
2022-05-31  4:08 Brian Dolbec
2019-02-13  8:43 Zac Medico
2014-05-29 16:32 Brian Dolbec
2014-05-05  2:04 Brian Dolbec
2014-01-31 15:44 [gentoo-commits] proj/mirrorselect:ssl " Brian Dolbec
2014-03-02  7:44 ` [gentoo-commits] proj/mirrorselect:master " Brian Dolbec
2013-10-18 14:26 Brian Dolbec
2013-03-10 13:07 Brian Dolbec
2012-12-16  6:02 Brian Dolbec
2012-12-16  4:48 Brian Dolbec
2012-12-15 22:31 Brian Dolbec
2012-12-15 20:26 Brian Dolbec
2012-11-14 18:25 Paul Varner
2012-11-14 18:18 Paul Varner
2012-11-14 18:06 Paul Varner
2012-11-12 21:41 Brian Dolbec
2012-11-12 15:56 Brian Dolbec
2012-11-12  7:46 Brian Dolbec
2012-11-12  0:50 Brian Dolbec
2012-11-11 23:47 Brian Dolbec
2012-11-11 23:47 Brian Dolbec

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1657486485.5444d0ddb5268325aac63dcdeb908b614916dd0f.dolsen@gentoo \
    --to=dolsen@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox