diff mbox series

[bug#57034] gnu: packages: Add miniz.

Message ID 20220807120201.19970-1-paren@disroot.org
State New
Headers show
Series [bug#57034] gnu: packages: Add miniz. | expand

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git-branch success View Git branch
cbaines/applying patch success View Laminar job
cbaines/issue success View issue

Commit Message

\( Aug. 7, 2022, 12:02 p.m. UTC
* gnu/packages/compression.scm (miniz): New variable.
---
 gnu/packages/compression.scm | 32 ++++++++++++++++++++++++++++++++
 1 file changed, 32 insertions(+)

Comments

Liliana Marie Prikler Aug. 7, 2022, 4:42 p.m. UTC | #1
Hi (,

last time I checked, the template was "gnu: Add PACKAGE", not "gnu:
packages: Add PACKAGE."

Am Sonntag, dem 07.08.2022 um 13:02 +0100 schrieb (:
> * gnu/packages/compression.scm (miniz): New variable.
> ---
>  gnu/packages/compression.scm | 32 ++++++++++++++++++++++++++++++++
>  1 file changed, 32 insertions(+)
> 
> diff --git a/gnu/packages/compression.scm
> b/gnu/packages/compression.scm
> index 6070c5beb1..cb1283c9a1 100644
> --- a/gnu/packages/compression.scm
> +++ b/gnu/packages/compression.scm
> @@ -35,6 +35,7 @@
>  ;;; Copyright © 2021 Simon Tournier <zimon.toutoune@gmail.com>
>  ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com>
>  ;;; Copyright © 2021 Ahmad Jarara <git@ajarara.io>
> +;;; Copyright © 2022 ( <paren@disroot.org>
>  ;;;
>  ;;; This file is part of GNU Guix.
>  ;;;
> @@ -2784,3 +2785,34 @@ (define-public fcrackzip
>      (synopsis "Zip password cracker")
>      (description "Fcrackzip is a Zip file password cracker.")
>      (license license:gpl2+)))
> +
> +(define-public miniz
> +  ;; Last release was on 27-06-2021; there have been many commits
> since
> +  ;; then.
And there might still be many more until a release.  I don't think
using untagged commits "just because" if the latest release is barely a
year old is a good idea.
> +  (let ((commit "be92575500f71dfb5ac7b0c5bb47b6e736c23039")
> +        (revision "0"))
> +    (package
> +     (name "miniz")
> +     (version (git-version "2.2.0" revision commit))
> +     (source (origin
> +              (method git-fetch)
> +              (uri (git-reference
> +                    (url "https://github.com/richgel999/miniz")
> +                    (commit commit)))
> +              (file-name (git-file-name name version))
> +              (sha256
> +               (base32
> +               
> "0w42vagcv4b0hcf0jk7vamrcpmw62dblx9856j98msdfm3qv1xzi"))))
> +     (build-system cmake-build-system)
> +     (arguments
> +      (list #:configure-flags
> +            #~(list "-DBUILD_SHARED_LIBS=ON")
> +            ;; No test target.
> +            #:tests? #f))
There is a test script you could use.
> +     (home-page "https://github.com/richgel999/miniz")
> +     (synopsis "Simple replacement for @code{zlib}")
> +     (description
> +      "@code{miniz} is a small, simple alternative to the
> @code{zlib}
> +data compression library for manipulating zlib, DEFLATE, PNG, and
> ZIP
> +files from C.")
Avoid marketing terms :)
\( Aug. 7, 2022, 4:59 p.m. UTC | #2
On Sun Aug 7, 2022 at 5:42 PM BST, Liliana Marie Prikler wrote:
> last time I checked, the template was "gnu: Add PACKAGE", not "gnu:
> packages: Add PACKAGE."
Okay, I'll remember that for next time :)

> And there might still be many more until a release.  I don't think
> using untagged commits "just because" if the latest release is barely a
> year old is a good idea.

> > +  (let ((commit "be92575500f71dfb5ac7b0c5bb47b6e736c23039")
> > +        (revision "0"))
> > +    (package
> > +     (name "miniz")
> > +     (version (git-version "2.2.0" revision commit))
> > +     (source (origin
> > +              (method git-fetch)
> > +              (uri (git-reference
> > +                    (url "https://github.com/richgel999/miniz")
> > +                    (commit commit)))
> > +              (file-name (git-file-name name version))
> > +              (sha256
> > +               (base32
> > +               
> > "0w42vagcv4b0hcf0jk7vamrcpmw62dblx9856j98msdfm3qv1xzi"))))
> > +     (build-system cmake-build-system)
> > +     (arguments
> > +      (list #:configure-flags
> > +            #~(list "-DBUILD_SHARED_LIBS=ON")
> > +            ;; No test target.
> > +            #:tests? #f))
> There is a test script you could use.
It doesn't work; I tried it.

> > +      "@code{miniz} is a small, simple alternative to the
> > @code{zlib}
> > +data compression library for manipulating zlib, DEFLATE, PNG, and
> > ZIP
> > +files from C.")
> Avoid marketing terms :)
Do 'small' and 'simple' count as marketing terms? 'smaller than zlib'
is objective fact, and 'simpler than zlib' is subjective but pretty
obvious. Maybe I could rewrite it to say 'smaller, simpler alternative'
instead?

    -- (
\( Aug. 7, 2022, 5:01 p.m. UTC | #3
On Sun Aug 7, 2022 at 5:42 PM BST, Liliana Marie Prikler wrote:
> And there might still be many more until a release.  I don't think
> using untagged commits "just because" if the latest release is barely a
> year old is a good idea.
Okay, I'll update it to use the latest release.

    -- (
Liliana Marie Prikler Aug. 7, 2022, 5:19 p.m. UTC | #4
Am Sonntag, dem 07.08.2022 um 17:59 +0100 schrieb (:
> On Sun Aug 7, 2022 at 5:42 PM BST, Liliana Marie Prikler wrote:
> > last time I checked, the template was "gnu: Add PACKAGE", not "gnu:
> > packages: Add PACKAGE."
> Okay, I'll remember that for next time :)
> 
> > And there might still be many more until a release.  I don't think
> > using untagged commits "just because" if the latest release is
> > barely a
> > year old is a good idea.
> 
> > > +  (let ((commit "be92575500f71dfb5ac7b0c5bb47b6e736c23039")
> > > +        (revision "0"))
> > > +    (package
> > > +     (name "miniz")
> > > +     (version (git-version "2.2.0" revision commit))
> > > +     (source (origin
> > > +              (method git-fetch)
> > > +              (uri (git-reference
> > > +                    (url "https://github.com/richgel999/miniz")
> > > +                    (commit commit)))
> > > +              (file-name (git-file-name name version))
> > > +              (sha256
> > > +               (base32
> > > +               
> > > "0w42vagcv4b0hcf0jk7vamrcpmw62dblx9856j98msdfm3qv1xzi"))))
> > > +     (build-system cmake-build-system)
> > > +     (arguments
> > > +      (list #:configure-flags
> > > +            #~(list "-DBUILD_SHARED_LIBS=ON")
> > > +            ;; No test target.
> > > +            #:tests? #f))
> > There is a test script you could use.
> It doesn't work; I tried it.
> 
> > > +      "@code{miniz} is a small, simple alternative to the
> > > @code{zlib}
> > > +data compression library for manipulating zlib, DEFLATE, PNG,
> > > and
> > > ZIP
> > > +files from C.")
> > Avoid marketing terms :)
> Do 'small' and 'simple' count as marketing terms? 'smaller than zlib'
> is objective fact, and 'simpler than zlib' is subjective but pretty
> obvious. Maybe I could rewrite it to say 'smaller, simpler
> alternative'
> instead?
"subjective, but pretty obvious", how so?  I think the fact that it
doesn't have its own documentation and you need to instead refer to
zlib kinda defeats that point.  Several of its README claims seem
either outdated already (the 550 lines one for example), or difficult
to guarantee forever.  I think the only claim we can reasonably make is
that it is an alternative zlib implementation, and that it supports
zlib, deflate, png and zip.

Cheers
\( Aug. 7, 2022, 5:22 p.m. UTC | #5
On Sun Aug 7, 2022 at 6:19 PM BST, Liliana Marie Prikler wrote:
> "subjective, but pretty obvious", how so?  I think the fact that it
> doesn't have its own documentation and you need to instead refer to
> zlib kinda defeats that point.  Several of its README claims seem
> either outdated already (the 550 lines one for example), or difficult
> to guarantee forever.  I think the only claim we can reasonably make is
> that it is an alternative zlib implementation, and that it supports
> zlib, deflate, png and zip.
Okay. (There is a little documentation in the headers, by the way.) :)

    -- (
Tobias Geerinckx-Rice Aug. 8, 2022, 12:36 a.m. UTC | #6
On 7 August 2022 16:42:35 UTC, Liliana Marie Prikler <liliana.prikler@gmail.com> wrote:
>> +     (synopsis "Simple replacement for @code{zlib}")
>> +     (description
>> +      "@code{miniz} is a small, simple alternative to the
>> @code{zlib}
>> +data compression library for manipulating zlib, DEFLATE, PNG, and
>> ZIP
>> +files from C.")
>Avoid marketing terms :)
 
(Small and simple are marketing terms?  Be right back; I need to update my profile...)

...no: avoid misleading or meaningless drivel, puffery, and redundancy.  Do, however, point out some basic features that might help users decide which of our oofteen deflate libraries fits their needs.  Add -er if you think it helps, or add some examples.

Otherwise, a common-sense guideline risks devolving into 'avoid adjectives; you might accidentally write a useful description'.



Kind regards,

T G-R

Sent on the go.  Excuse or enjoy my brevity.
Liliana Marie Prikler Aug. 8, 2022, 4:29 a.m. UTC | #7
Am Montag, dem 08.08.2022 um 00:36 +0000 schrieb Tobias Geerinckx-Rice:
> On 7 August 2022 16:42:35 UTC, Liliana Marie Prikler
> <liliana.prikler@gmail.com> wrote:
> > > +     (synopsis "Simple replacement for @code{zlib}")
> > > +     (description
> > > +      "@code{miniz} is a small, simple alternative to the
> > > @code{zlib}
> > > +data compression library for manipulating zlib, DEFLATE, PNG,
> > > and
> > > ZIP
> > > +files from C.")
> > Avoid marketing terms :)
>  
> (Small and simple are marketing terms?  Be right back; I need to
> update my profile...)
> 
> ...no: avoid misleading or meaningless drivel, puffery, and
> redundancy.  Do, however, point out some basic features that might
> help users decide which of our oofteen deflate libraries fits their
> needs.  Add -er if you think it helps, or add some examples.
Maybe not always, but I think in this context they are.  Especially
"simple", who decides that?  Pardon my cynicism here, but my personal
opinion w.r.t. compression libraries is that projects tend to pick the
one they're already contractually obligated to use FSVO contractually
obligated.
diff mbox series

Patch

diff --git a/gnu/packages/compression.scm b/gnu/packages/compression.scm
index 6070c5beb1..cb1283c9a1 100644
--- a/gnu/packages/compression.scm
+++ b/gnu/packages/compression.scm
@@ -35,6 +35,7 @@ 
 ;;; Copyright © 2021 Simon Tournier <zimon.toutoune@gmail.com>
 ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com>
 ;;; Copyright © 2021 Ahmad Jarara <git@ajarara.io>
+;;; Copyright © 2022 ( <paren@disroot.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -2784,3 +2785,34 @@  (define-public fcrackzip
     (synopsis "Zip password cracker")
     (description "Fcrackzip is a Zip file password cracker.")
     (license license:gpl2+)))
+
+(define-public miniz
+  ;; Last release was on 27-06-2021; there have been many commits since
+  ;; then.
+  (let ((commit "be92575500f71dfb5ac7b0c5bb47b6e736c23039")
+        (revision "0"))
+    (package
+     (name "miniz")
+     (version (git-version "2.2.0" revision commit))
+     (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/richgel999/miniz")
+                    (commit commit)))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "0w42vagcv4b0hcf0jk7vamrcpmw62dblx9856j98msdfm3qv1xzi"))))
+     (build-system cmake-build-system)
+     (arguments
+      (list #:configure-flags
+            #~(list "-DBUILD_SHARED_LIBS=ON")
+            ;; No test target.
+            #:tests? #f))
+     (home-page "https://github.com/richgel999/miniz")
+     (synopsis "Simple replacement for @code{zlib}")
+     (description
+      "@code{miniz} is a small, simple alternative to the @code{zlib}
+data compression library for manipulating zlib, DEFLATE, PNG, and ZIP
+files from C.")
+     (license license:expat))))