Re: [PATCH cygport] xorg.cygclass: Allow configuration of default SRC_URI compression

2022-04-13 Thread Jon Turney

On 12/04/2022 01:41, Yaakov Selkowitz wrote:

On Mon, 2022-04-11 at 13:58 +0100, Jon Turney wrote:

Historically, xorg packages were usually provided as .gz and .bz2
compressed tarballs.  The current trend is to no longer provide .bz2,
but .gz and .xz instead.  Allow the compression to be configured, with a
backwards compatible default.


If all or even most current packages use .xz, then maybe just default to that
and define XORG_SRC_COMPRESSION for the (current) exceptions?


Yeah, I went back and forth on what the default should be here.

It's only most packages, since it relies on someone remembering to 
change the compressions in AM_INIT_AUTOMAKE, which sometimes hasn't 
happened.


Changing the default changes the meaning of old .cygport files in a way 
that probably breaks them.


Re: [PATCH cygport] xorg.cygclass: Allow configuration of default SRC_URI compression

2022-04-11 Thread Yaakov Selkowitz
On Mon, 2022-04-11 at 13:58 +0100, Jon Turney wrote:
> Historically, xorg packages were usually provided as .gz and .bz2
> compressed tarballs.  The current trend is to no longer provide .bz2,
> but .gz and .xz instead.  Allow the compression to be configured, with a
> backwards compatible default.

If all or even most current packages use .xz, then maybe just default to that
and define XORG_SRC_COMPRESSION for the (current) exceptions?

-- 
Yaakov



[PATCH cygport] xorg.cygclass: Allow configuration of default SRC_URI compression

2022-04-11 Thread Jon Turney
Historically, xorg packages were usually provided as .gz and .bz2
compressed tarballs.  The current trend is to no longer provide .bz2,
but .gz and .xz instead.  Allow the compression to be configured, with a
backwards compatible default.
---
 cygclass/xorg.cygclass | 13 -
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/cygclass/xorg.cygclass b/cygclass/xorg.cygclass
index 2049fd5..519ea8f 100644
--- a/cygclass/xorg.cygclass
+++ b/cygclass/xorg.cygclass
@@ -143,11 +143,22 @@ SUMMARY="X.Org ${ORIG_PN} component"
 #  DEFINITION
 HOMEPAGE="https://www.x.org/;
 #
+
+#o* xorg.cygclass/XORG_SRC_COMPRESSION
+#  DESCRIPTION
+#  The compression extension used in the default SRC_URI, set by the xorg
+#  cygclass.  For backwards compatibility, this defaults to 'bz2', but a
+#  different value may be needed for X.Org packages which no longer provide
+#  tarballs using that compression.
+#  DEFINITION
+XORG_SRC_COMPRESSION="${XORG_SRC_COMPRESSION:-bz2}"
+#
+
 #o* xorg.cygclass/SRC_URI (xorg)
 #  DESCRIPTION
 #  Download location of the release tarball.
 #
-SRC_URI="https://www.x.org/releases/individual/${xorg_cat}/${ORIG_PN}-${PV}.tar.bz2;
+SRC_URI="https://www.x.org/releases/individual/${xorg_cat}/${ORIG_PN}-${PV}.tar.${XORG_SRC_COMPRESSION};
 
 #o* xorg.cygclass/GIT_URI (xorg)
 #  DESCRIPTION
-- 
2.35.1