public inbox for cygwin-apps@cygwin.com
 help / color / mirror / Atom feed
* Re: [ANNOUNCEMENT] cygport 0.36.1-1
       [not found] <announce.35193db5-ad95-ce9d-53fe-4ed535da8279@dronecode.org.uk>
@ 2023-03-11 20:15 ` Marco Atzeri
  2023-03-26 16:43   ` Jon Turney
  0 siblings, 1 reply; 4+ messages in thread
From: Marco Atzeri @ 2023-03-11 20:15 UTC (permalink / raw)
  To: cygwin-apps; +Cc: Jon Turney

[-- Attachment #1: Type: text/plain, Size: 399 bytes --]

On 11.03.2023 17:29, Jon Turney via Cygwin wrote:
> 
> The following packages have been uploaded to the Cygwin distribution:
> 
> * cygport-0.36.1-1
> 

Hi Jon,

I was a bit too late...

Updating the python 3.[89] subpackages, I finally hit
a case where setup.py and setup.cfg are missing as obsolete.

Attached patch solved the issue and allowed to build
python-platformdirs-3.1.1-1


Regards
Marco

[-- Attachment #2: 0001-Allow-wheel-to-manage-project-without-setup.py-and-s.patch --]
[-- Type: text/plain, Size: 1494 bytes --]

From 4081ce236a5d8f9b76afd9c68e489600d7b434f1 Mon Sep 17 00:00:00 2001
From: Marco Atzeri <marco.atzeri@gmail.com>
Date: Sat, 11 Mar 2023 21:00:15 +0100
Subject: [PATCH] Allow wheel to manage project without setup.py and setup.cfg
 and use the pyproject.toml (PEP 518)

---
 cygclass/python-wheel.cygclass | 16 ++++++++++++----
 1 file changed, 12 insertions(+), 4 deletions(-)

diff --git a/cygclass/python-wheel.cygclass b/cygclass/python-wheel.cygclass
index 1ef23826..b0f5288a 100644
--- a/cygclass/python-wheel.cygclass
+++ b/cygclass/python-wheel.cygclass
@@ -159,9 +159,13 @@ fi
 python_wheel_compile() {
 	local ver
 
-	if [ ! -e setup.py ] && [ ! -e setup.cfg ]
+	if [ ! -e  pyproject.toml ]
 	then
-		error "No Python Distutils module detected in source tree"
+		warning "No pyproject.toml (PEP 518)  detected in source tree"
+		if [ ! -e setup.py ] && [ ! -e setup.cfg ]
+		then
+			error "No Python Distutils module detected in source tree"
+		fi
 	fi
 
 	for ver in ${PYTHON_WHEEL_VERSIONS//:/ }
@@ -189,9 +193,13 @@ python_wheel_compile() {
 python_wheel_install() {
 	local ver whl
 
-	if [ ! -e setup.py ] && [ ! -e setup.cfg ]
+	if [ ! -e  pyproject.toml ]
 	then
-		error "No Python Distutils module detected in source tree"
+		warning "No pyproject.toml (PEP 518)  detected in source tree"
+		if [ ! -e setup.py ] && [ ! -e setup.cfg ]
+		then
+			error "No Python Distutils module detected in source tree"
+		fi
 	fi
 
 	for ver in ${PYTHON_WHEEL_VERSIONS//:/ }
-- 
2.39.0


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ANNOUNCEMENT] cygport 0.36.1-1
  2023-03-11 20:15 ` [ANNOUNCEMENT] cygport 0.36.1-1 Marco Atzeri
@ 2023-03-26 16:43   ` Jon Turney
  2023-04-11  4:14     ` Marco Atzeri
  0 siblings, 1 reply; 4+ messages in thread
From: Jon Turney @ 2023-03-26 16:43 UTC (permalink / raw)
  To: cygwin-apps, Marco Atzeri

On 11/03/2023 20:15, Marco Atzeri via Cygwin-apps wrote:
> On 11.03.2023 17:29, Jon Turney via Cygwin wrote:
>>
>> The following packages have been uploaded to the Cygwin distribution:
>>
>> * cygport-0.36.1-1
>>
> 
> Hi Jon,
> 
> I was a bit too late...

No problem, I can always make more releases!

> Updating the python 3.[89] subpackages, I finally hit
> a case where setup.py and setup.cfg are missing as obsolete.
> 
> Attached patch solved the issue and allowed to build
> python-platformdirs-3.1.1-1

Thanks.

I'm not sure if always emitting a warning if pyproject.toml is missing
is good idea, so I might do a bit of tweaking, but I applied this patch.

(as that will probably warn if you ever try to build an old version of a 
project, which is still perfectly buildable due to having a setup.py)


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ANNOUNCEMENT] cygport 0.36.1-1
  2023-03-26 16:43   ` Jon Turney
@ 2023-04-11  4:14     ` Marco Atzeri
  2023-04-11 18:54       ` Jon Turney
  0 siblings, 1 reply; 4+ messages in thread
From: Marco Atzeri @ 2023-04-11  4:14 UTC (permalink / raw)
  To: Jon Turney, cygwin-apps

On 26.03.2023 18:43, Jon Turney wrote:
> On 11/03/2023 20:15, Marco Atzeri via Cygwin-apps wrote:
>> On 11.03.2023 17:29, Jon Turney via Cygwin wrote:
>>>
>>> The following packages have been uploaded to the Cygwin distribution:
>>>
>>> * cygport-0.36.1-1
>>>
>>
>> Hi Jon,
>>
>> I was a bit too late...
> 
> No problem, I can always make more releases!
> 
>> Updating the python 3.[89] subpackages, I finally hit
>> a case where setup.py and setup.cfg are missing as obsolete.
>>
>> Attached patch solved the issue and allowed to build
>> python-platformdirs-3.1.1-1
> 
> Thanks.
> 
> I'm not sure if always emitting a warning if pyproject.toml is missing
> is good idea, so I might do a bit of tweaking, but I applied this patch.
> 
> (as that will probably warn if you ever try to build an old version of a 
> project, which is still perfectly buildable due to having a setup.py)
> 

Hi Jon,

what about his form ?

     if [ ! -e  pyproject.toml ]
     then
         warning "No pyproject.toml (PEP 518)  detected in source tree"
         warning "Trying previous Distutils method."
         if [ ! -e setup.py ] && [ ! -e setup.cfg ]
         then
             error "No Python Distutils module neither pyproject.toml 
(PEP 518) detected in source tree"
         fi
     fi


I would any some version of it released before I upload the git source
that has only pyproject.toml.
Otherwise scullywag will fail the build.


Regards
Marco



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ANNOUNCEMENT] cygport 0.36.1-1
  2023-04-11  4:14     ` Marco Atzeri
@ 2023-04-11 18:54       ` Jon Turney
  0 siblings, 0 replies; 4+ messages in thread
From: Jon Turney @ 2023-04-11 18:54 UTC (permalink / raw)
  To: Marco Atzeri, cygwin-apps

On 11/04/2023 05:14, Marco Atzeri wrote:
> On 26.03.2023 18:43, Jon Turney wrote:
>> On 11/03/2023 20:15, Marco Atzeri via Cygwin-apps wrote:
>>> On 11.03.2023 17:29, Jon Turney via Cygwin wrote:
>>>>
>>>> The following packages have been uploaded to the Cygwin distribution:
>>>>
>>>> * cygport-0.36.1-1
>>>>
>>>
>>> Hi Jon,
>>>
>>> I was a bit too late...
>>
>> No problem, I can always make more releases!
>>
[...]
> 
> I would any some version of it released before I upload the git source
> that has only pyproject.toml.
> Otherwise scullywag will fail the build.

I was hoping to make a new release last weekend, but unfortunately that 
didn't happen.

Hopefully I'll have time to do one sometime this week.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-04-11 18:54 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <announce.35193db5-ad95-ce9d-53fe-4ed535da8279@dronecode.org.uk>
2023-03-11 20:15 ` [ANNOUNCEMENT] cygport 0.36.1-1 Marco Atzeri
2023-03-26 16:43   ` Jon Turney
2023-04-11  4:14     ` Marco Atzeri
2023-04-11 18:54       ` Jon Turney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).