[PATCH] gnu: Add mkvtoolnix.

  • Done
  • quality assurance status badge
Details
2 participants
  • Gregor Giesen
  • Leo Famulari
Owner
unassigned
Submitted by
Gregor Giesen
Severity
normal
G
G
Gregor Giesen wrote on 20 Jun 2017 23:54
(address . guix-patches@gnu.org)
20170620215432.h6ed3xyci2gcecz2@zaehlwerk.net
Hello everybody,

I have packed mkvtoolnix along with some dependencies.

Best,
Gregor
L
L
Leo Famulari wrote on 25 Jun 2017 15:44
(name . Gregor Giesen)(address . giesen@zaehlwerk.net)(address . 27434@debbugs.gnu.org)
20170625134401.GA7385@jasmine.lan
On Tue, Jun 20, 2017 at 11:54:33PM +0200, Gregor Giesen wrote:
Toggle quote (4 lines)
> * gnu/packages/serialization.scm (nlohmann-json-cpp): New variable.
> * gnu/packages/video.scm (mkvtoolnix libmatroska): New variables.
> * gnu/packages/xml.scm (libebml): New variable.

Thank you!

I spent some time splitting this patch into "one patch per package",
which is how we like to do it.

nlohmnann-json-cpp, libebml, and libmatroska are done, in my opinion,
and I'll push them shortly.

Toggle quote (5 lines)
> +(define-public mkvtoolnix
> + (package
> + (name "mkvtoolnix")
> + (version "12.0.0")

When I built and ran mkvtoolnix-gui, it told me there was a new version
available (13.0.0). Can we use that version instead?

Toggle quote (6 lines)
> + (source
> + (origin
> + (method url-fetch)
> + (uri (string-append "https://mkvtoolnix.download/sources/"
> + name "-" version ".tar.xz"))

I noticed it includes some files in 'lib/', and at least some of them
appear to be bundled copies of 3rd-party libraries:

$ ls -l mkvtoolnix-12.0.0/lib
total 4
drwxr-xr-x 1 leo leo 116 May 20 13:25 avilib-0.6.10
drwxr-xr-x 1 leo leo 66 May 20 13:25 boost
drwxr-xr-x 1 leo leo 194 May 20 13:25 libebml
drwxr-xr-x 1 leo leo 236 May 20 13:25 libmatroska
drwxr-xr-x 1 leo leo 120 May 20 13:25 librmff
drwxr-xr-x 1 leo leo 70 May 20 13:25 nlohmann-json
drwxr-xr-x 1 leo leo 26 May 20 13:25 pugixml
-rw-r--r-- 1 leo leo 244 May 20 13:25 Rakefile
drwxr-xr-x 1 leo leo 18 May 20 13:25 utf8-cpp

After removing libebml, libmatroska, and nlohmann-json in an "origin
snippet" [0], mkvtoolnix still builds. We don't like to use or
distribute bundled libraries if we can help it. I didn't have time yet
to investigate the other directories in that list.

Toggle quote (12 lines)
> + (native-inputs
> + `(("docbook-xsl" ,docbook-xsl)
> + ("gettext" ,gettext-minimal)
> + ("googletest" ,googletest)
> + ("libxslt" ,libxslt)
> + ("nlohmann-json-cpp" ,nlohmann-json-cpp)
> + ("perl" ,perl)
> + ("pkg-config" ,pkg-config)
> + ("po4a" ,po4a)
> + ("ruby" ,ruby)
> + ("zsh", zsh)))

Does it need to use Zsh while building? Native-inputs are basically
build-time dependencies, and it's definitely unusual to require Zsh, so
that's why I'm asking. I removed Zsh from this list and the resulting
mkvtoolnix-gui seems to start without any problems.
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEsFFZSPHn08G5gDigJkb6MLrKfwgFAllPvgwACgkQJkb6MLrK
fwjsFRAAiWDllL4xYP2U0Bx7XxNBlKvlwC7EIpuwnyoGE91brvyBcuPGJ0VeM1W1
tMh1rfIbadlTcnmqWSC9QTKkWQ0xpI+fpIXXGcaojJ5f04e+7VReYf/Vacvxd8WJ
nmsFkIuV0FL6szPvrVuX1RX5AoryWdFSPgCPqnOoXXojf+yhhTyznOPRxOwINNWc
/ho8tiPw83YvjceLmLI80m7JXww6qRSRSlw2Y9iD1UHhMN1Q/v2d4kJV8DhI1DQO
5CGhejYETo7BQldoTjcRZHk/E0MpqFdnO2DpCMb7b+JsxIlz4v23nYtzMXQDy9H5
j1Nd+vQkdkqAqDWBnPEfmoXWeuUET8fISFuLqv8RBqKSukLH0nPVJN7W38+ChYts
KRMuJnGurJDD/UME10nzep9SKWEfJqCWy6d/s2UA9YfxN9RfqFIxJegF8d1ZktI6
+48q7u/eGFYiGHXXCRnpgUgjGeyS7Q9Fz0x2WeoOpmgK2xIk2ejUHbR7EHkPf/ds
vNPxBrFWxUHF2TCgND73zHp4M+FRrKSxO8q20V4BjonXfGxcHCDyPWPY9GGCKV/e
2tSZuE0Ahaphfh0mCElnVhZ4edYUL96FEaI/dwodczu+a7QU6Mpik3VZ7/YPSQDJ
1x1CuZ+l4EZyXesRu0VKrSBLz9nFD9Mo7teh+FCJsRwzwBQUG+E=
=I7OO
-----END PGP SIGNATURE-----


L
L
Leo Famulari wrote on 25 Jun 2017 16:00
(name . Gregor Giesen)(address . giesen@zaehlwerk.net)(address . 27434@debbugs.gnu.org)
20170625140025.GA9559@jasmine.lan
On Tue, Jun 20, 2017 at 11:54:33PM +0200, Gregor Giesen wrote:
Toggle quote (5 lines)
> + (description
> + "JSON library for C++ trying to accomplish “Intuitive syntax”,
> +“Trivial integration”, and “Serious testing”.
> +However, “Memory efficiency” and “Speed” have not been primary goals.")

Most programs like to claim they were created with efficiency and speed
in mind, and I always thought it was funny, as if anyone would claim
otherwise. There's a first time for everything :)

One question about this package:

Toggle quote (4 lines)
> + (description
> + "libebml is a C++ library to read and write EBML files.
> +EBML (Extensible Binary Meta Language) is a binary pendant to XML.")

What does "binary pendant to XML" mean? I'm not familiar with this
phrase.
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEsFFZSPHn08G5gDigJkb6MLrKfwgFAllPwfgACgkQJkb6MLrK
fwg5aw/9Gh914/9qLRMO+h4duXTqSt58dc9l5J6zpjfI6ZgHMXRnnmKHg1EchC1i
oN0U0+xb/s4vpSQdDfq9KTac2rk+zhvH+z0wvkOP3z4RBUmDLDvslvtFT4irnxw+
tEJfWzqzyaryy9DWWbdTGLDvVvNY/eezXQVTyUrlmC+4QMgkN09DgQ3EhexE0cT4
X1/V4JNi2dD9HZvrxR70SysgriTmV/+Jojz1QrNAb+qq0w5RdpBPGhD39im3hgBi
0rvYnQN140PpTL3g+WwB6ONCLPIvAkWrUz15xAHkN1HGdxwz4Iovo4lionTknvKK
IsQ/2xPaXef7y086YA/OE69wJpoymbkUks4aFsponl8KAddcawcNdhbN+FpH7GHW
gwM9yT3O4Yrda9lc3uY6Wm/XgSf7LARsuyN4TU++IypPq6J3ldKZ/j5cnUY2/fZK
xX92+nkE9dn93mQkyXGH9ymbJ5bCuMvpmPVJkkpdPEDPemj6q8DmBZJMlNwHpILv
qR+ziLqlIzXmbAxRbGu0qgTwvejjrlfQox7bfxuPFJksR9AepV/9T1ETr4Sv19YF
BhcyxFwiJLkhUUUOCQIwDLTm8Fw2Y9+B1o4+6FpPxOuCAADWohxNiqFVGB/gZDXt
Cp9VInhES2rrlY4ELV5NeEVppAOSONXiM6gOXvldIhqYwqIe18M=
=pCy/
-----END PGP SIGNATURE-----


G
G
Gregor Giesen wrote on 25 Jun 2017 16:50
(name . Leo Famulari)(address . leo@famulari.name)(address . 27434@debbugs.gnu.org)
20170625145037.g2zo6avd6uflhu3t@zaehlwerk.net
Dear Leo,

thank you for taking your time for this blob of packages.

On Sun, Jun 25, 2017 at 09:44:01AM -0400, Leo Famulari wrote:
Toggle quote (2 lines)
> I spent some time splitting this patch into "one patch per package",
> which is how we like to do it.
Sorry, I wasn't aware of it. Won't happen again.

Toggle quote (2 lines)
> nlohmnann-json-cpp, libebml, and libmatroska are done, in my opinion,
> and I'll push them shortly.
Thank you!

Toggle quote (7 lines)
> > +(define-public mkvtoolnix
> > + (package
> > + (name "mkvtoolnix")
> > + (version "12.0.0")
>
> When I built and ran mkvtoolnix-gui, it told me there was a new version
> available (13.0.0). Can we use that version instead?
Yes, in fact, it has been released today.

Toggle quote (19 lines)
> I noticed it includes some files in 'lib/', and at least some of them
> appear to be bundled copies of 3rd-party libraries:
>
> $ ls -l mkvtoolnix-12.0.0/lib
> total 4
> drwxr-xr-x 1 leo leo 116 May 20 13:25 avilib-0.6.10
> drwxr-xr-x 1 leo leo 66 May 20 13:25 boost
> drwxr-xr-x 1 leo leo 194 May 20 13:25 libebml
> drwxr-xr-x 1 leo leo 236 May 20 13:25 libmatroska
> drwxr-xr-x 1 leo leo 120 May 20 13:25 librmff
> drwxr-xr-x 1 leo leo 70 May 20 13:25 nlohmann-json
> drwxr-xr-x 1 leo leo 26 May 20 13:25 pugixml
> -rw-r--r-- 1 leo leo 244 May 20 13:25 Rakefile
> drwxr-xr-x 1 leo leo 18 May 20 13:25 utf8-cpp
>
> After removing libebml, libmatroska, and nlohmann-json in an "origin
> snippet" [0], mkvtoolnix still builds. We don't like to use or
> distribute bundled libraries if we can help it. I didn't have time yet
> to investigate the other directories in that list.
That is not very clean indeed. I just had had a look at the configure
output and tried bundling those mentioned. It seems that I missed some.
Let me have another go and try to bundle or disable those dependencies.
E.g. librmff seems to be an ancient library for Real Media files; I
rather want to disable it.

Toggle quote (16 lines)
> > + (native-inputs
> > + `(("docbook-xsl" ,docbook-xsl)
> > + ("gettext" ,gettext-minimal)
> > + ("googletest" ,googletest)
> > + ("libxslt" ,libxslt)
> > + ("nlohmann-json-cpp" ,nlohmann-json-cpp)
> > + ("perl" ,perl)
> > + ("pkg-config" ,pkg-config)
> > + ("po4a" ,po4a)
> > + ("ruby" ,ruby)
> > + ("zsh", zsh)))
>
> Does it need to use Zsh while building? Native-inputs are basically
> build-time dependencies, and it's definitely unusual to require Zsh, so
> that's why I'm asking. I removed Zsh from this list and the resulting
> mkvtoolnix-gui seems to start without any problems.
I recall some warning about ‘zsh’, but you are right we do not really
need it.

On Sun, Jun 25, 2017 at 10:00:25AM -0400, Leo Famulari wrote:
Toggle quote (9 lines)
> On Tue, Jun 20, 2017 at 11:54:33PM +0200, Gregor Giesen wrote:
> > + (description
> > + "JSON library for C++ trying to accomplish “Intuitive syntax”,
> > +“Trivial integration”, and “Serious testing”.
> > +However, “Memory efficiency” and “Speed” have not been primary goals.")
>
> Most programs like to claim they were created with efficiency and speed
> in mind, and I always thought it was funny, as if anyone would claim
> otherwise. There's a first time for everything :)
Yeah, I was surprised, too. However, the developer seems to be a humble guy...
Toggle quote (8 lines)
> One question about this package:
>
> > + (description
> > + "libebml is a C++ library to read and write EBML files.
> > +EBML (Extensible Binary Meta Language) is a binary pendant to XML.")
>
> What does "binary pendant to XML" mean? I'm not familiar with this
> phrase.
I also never heard of it, but I understand that this is a binary language
in which you can store the same data structures like XML is able to. This
is probably a bit smaller and has less overhead.

Best,
Gregor
G
G
Gregor Giesen wrote on 25 Jun 2017 17:43
(name . Leo Famulari)(address . leo@famulari.name)(address . 27434@debbugs.gnu.org)
20170625154331.apcegxmnxxuqv7yn@zaehlwerk.net
Dear Leo,

I had another look at those libraries:

On Sun, Jun 25, 2017 at 09:44:01AM -0400, Leo Famulari wrote:
Toggle quote (8 lines)
> I noticed it includes some files in 'lib/', and at least some of them
> appear to be bundled copies of 3rd-party libraries:
>
> drwxr-xr-x 1 leo leo 194 May 20 13:25 libebml -> libebml
> drwxr-xr-x 1 leo leo 236 May 20 13:25 libmatroska -> libmatroska
> drwxr-xr-x 1 leo leo 70 May 20 13:25 nlohmann-json -> nlohmann-json-cpp
> drwxr-xr-x 1 leo leo 26 May 20 13:25 pugixml -> pugixml
> drwxr-xr-x 1 leo leo 18 May 20 13:25 utf8-cpp -> utfcpp
those can be removed, they are already included in ‘inputs’ and the
configure script favours the system (guix) lib over them.

The remaining three libraries are referenced directly from the source
code. Here are comments from README.md:

Toggle quote (1 lines)
> drwxr-xr-x 1 leo leo 66 May 20 13:25 boost
Toggle snippet (8 lines)
A class, `utf8_codecvt_facet`, derived from `std::codecvt<wchar_t, char>`,
which can be used to convert utf8 data in files into `wchar_t` strings
in the application.

* License: Boost Software License - Version 1.0 (see `doc/licenses/Boost-1.0.txt`)
* URL: http://www.boost.org

The other two are some ancient and orphaned libraries for deprecated
video formats, however GPLv2/LGPLv2.1:

Toggle quote (1 lines)
> drwxr-xr-x 1 leo leo 116 May 20 13:25 avilib-0.6.10
Toggle snippet (17 lines)
Reading and writing avi files.

Copyright (C) 1999 Rainer Johanni <Rainer@Johanni.de>, originally part
of the transcode package.

* License: GNU General Public License v2
* URL: http://www.transcoding.org/

> drwxr-xr-x 1 leo leo 120 May 20 13:25 librmff
librmff is short for 'RealMedia file format access library'. It aims
at providing the programmer an easy way to read and write RealMedia
files.

* License: GNU Lesser General Public License v2.1 (see `doc/licenses/LGPL-2.1.txt`)
* URL: https://www.bunkus.org/videotools/librmff/index.html

Is it ok to just include them and adding those two licenses the package?

Best,
Gregor
L
L
Leo Famulari wrote on 30 Jun 2017 18:35
(name . Gregor Giesen)(address . giesen@zaehlwerk.net)(address . 27434@debbugs.gnu.org)
20170630163542.GA26833@jasmine.lan
On Sun, Jun 25, 2017 at 04:50:37PM +0200, Gregor Giesen wrote:
Toggle quote (7 lines)
> > Does it need to use Zsh while building? Native-inputs are basically
> > build-time dependencies, and it's definitely unusual to require Zsh, so
> > that's why I'm asking. I removed Zsh from this list and the resulting
> > mkvtoolnix-gui seems to start without any problems.
> I recall some warning about ‘zsh’, but you are right we do not really
> need it.

Those Zsh scripts seem to be used for other platforms (like MacOS and
Windows) or for developing mkvtoolnix. So I think it's okay to omit Zsh
here.
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEsFFZSPHn08G5gDigJkb6MLrKfwgFAllWfdsACgkQJkb6MLrK
fwh/sQ/+JhkCXJ/cdGKwn5PVc2Is78RFsAnuWW8kHGcoHRkk+3i4ylYmnEf+qeEx
nLPyhGJl6sIfw/Z/kQED2cSE1HtrH0B9douDY3DgAlCnp6v+TPOym2SitmPl/OqL
MW/qiw5p+Q5IWfVkDhfDMwaFbuk4b0awEBCe82FRaLw1sCzR/8vx1Mnige9qsATG
DIxIpFuKC1+RQ7e/3rapWhJoe6/kJCzMMYaHiIsYwo1FrHAQNmVyGzt7Umsh3YFO
rGUOjlu/n3aPXs7rTU0yssk6d1tbM7KvWNEE9VV9Z1vmMRhHchBJbA5DyeKcqBfh
4wompziRWJzpR2ZQsHep/qh1+0m+29TfP8b7r1QQwULU+srKRw/k2nMIx4lcKKiS
Nn/aYQklmDgp3tFfoh1kpTOt6lOroWmoi1pKFsJSTEU3+Lp7WRz70fRUvM0m4xku
yvOPuBm1UGjvkXR04kvS31FNAp76+iSBsQjfS5SF5GFF7ZF2TauU3zEfsI2AL852
Ic5NZ7+pk1gwFtr4pblrGJU4H1ucGwUajFOv4/IVgX/KI+5IzLnJJlLvjQ4n2X4O
vKqk4DQs+NySAD2cvO9YR2adRxEPAiTGUrlEKmAgf1J8JsXCRxaF3smhiYV+biQh
LI6KfEI131ylnaBiPzi5Bqr0Qwszpc1a0Yi5QkVjleBI0bVJFbg=
=qltN
-----END PGP SIGNATURE-----


L
L
Leo Famulari wrote on 30 Jun 2017 18:45
(name . Gregor Giesen)(address . giesen@zaehlwerk.net)(address . 27434-done@debbugs.gnu.org)
20170630164546.GB26833@jasmine.lan
On Sun, Jun 25, 2017 at 05:43:31PM +0200, Gregor Giesen wrote:
Toggle quote (53 lines)
> Dear Leo,
>
> I had another look at those libraries:
>
> On Sun, Jun 25, 2017 at 09:44:01AM -0400, Leo Famulari wrote:
> > I noticed it includes some files in 'lib/', and at least some of them
> > appear to be bundled copies of 3rd-party libraries:
> >
> > drwxr-xr-x 1 leo leo 194 May 20 13:25 libebml -> libebml
> > drwxr-xr-x 1 leo leo 236 May 20 13:25 libmatroska -> libmatroska
> > drwxr-xr-x 1 leo leo 70 May 20 13:25 nlohmann-json -> nlohmann-json-cpp
> > drwxr-xr-x 1 leo leo 26 May 20 13:25 pugixml -> pugixml
> > drwxr-xr-x 1 leo leo 18 May 20 13:25 utf8-cpp -> utfcpp
> those can be removed, they are already included in ‘inputs’ and the
> configure script favours the system (guix) lib over them.
>
> The remaining three libraries are referenced directly from the source
> code. Here are comments from README.md:
>
> > drwxr-xr-x 1 leo leo 66 May 20 13:25 boost
> --8<---------------cut here---------------start------------->8---
> A class, `utf8_codecvt_facet`, derived from `std::codecvt<wchar_t, char>`,
> which can be used to convert utf8 data in files into `wchar_t` strings
> in the application.
>
> * License: Boost Software License - Version 1.0 (see `doc/licenses/Boost-1.0.txt`)
> * URL: http://www.boost.org
> --8<---------------cut here----------------end-------------->8---
>
> The other two are some ancient and orphaned libraries for deprecated
> video formats, however GPLv2/LGPLv2.1:
>
> > drwxr-xr-x 1 leo leo 116 May 20 13:25 avilib-0.6.10
> --8<---------------cut here---------------start------------->8---
> Reading and writing avi files.
>
> Copyright (C) 1999 Rainer Johanni <Rainer@Johanni.de>, originally part
> of the transcode package.
>
> * License: GNU General Public License v2
> * URL: http://www.transcoding.org/
>
> > drwxr-xr-x 1 leo leo 120 May 20 13:25 librmff
> librmff is short for 'RealMedia file format access library'. It aims
> at providing the programmer an easy way to read and write RealMedia
> files.
>
> * License: GNU Lesser General Public License v2.1 (see `doc/licenses/LGPL-2.1.txt`)
> * URL: https://www.bunkus.org/videotools/librmff/index.html
> --8<---------------cut here----------------end-------------->8---
>
> Is it ok to just include them and adding those two licenses the package?

Thank you very much for investigating, and I'm sorry my response was
rather slow! I just pushed revisions of your patches, based on our
discussion, as 2973ebf504f4d958a8db40b09b210b237060fc92.
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEsFFZSPHn08G5gDigJkb6MLrKfwgFAllWgDkACgkQJkb6MLrK
fwgcGg//ZNENp02JYMqxrdFGsU6Yjhl3FNEsvJhz3v6Ep4DIJhg2baLjN6BIQkx1
C27XgEmozLFA3vGcbrPIsSIOmxHF79zHl2LdA9Gptfx9yGWgiZGTWJvG30slgxUc
eWs5k6OZiGMvM+/oDHGvQCRRgn5/xCxd2Pkg3bLhWC4NLZreXGt6esZkpQ50NrNo
rVv4UZo6OUfYBmLzrNj44NbqhPATLeznc6zfdKIdZov5dPUyYwiYy1F1yYiyc5zE
CYk0MPUTRwbuXdkmlL/ziElh0ja8FD0QQqga/zoc2TC0qTL7IsLvfCUBIq2DzHat
kibXmSRkH/IFg0+LsSgsBXlGfyZf9wr7dl3x80+lPBUQnPYYhUMNZE9lE8Zqr6+0
MQorQCGoHo6XzR1T3p6DVI18G1h+tl15AjTAmmVJMSi07igaUQ8sOrs4Vv9rqk0d
ImDiGKjnwmP6FKeYMEdWN0VUpuIh9KPS8GShreWlNaOiezM2kHc+4zSSjjc3X7OH
BVhL13q7+JERlCK/dRUgJFBtD09XRZp9tPdqZ2W4EYM/izkX4Ge/Gbs2w0jrspKc
hMKx/tASQP3FRSWnPWD3DR7F1ErhzoqU/f0uEJizko9K9IIQ/j1fyLn+IVC7VmD9
01UU0W6t9iF87ap6eZDLDHQzJxlMXtNXTwkjRJLUS/mkNJQ6nr0=
=Ean6
-----END PGP SIGNATURE-----


Closed
G
G
Gregor Giesen wrote on 30 Jun 2017 19:41
(name . Leo Famulari)(address . leo@famulari.name)(address . 27434-done@debbugs.gnu.org)
20170630174126.qwhhnqc5whtgjjpk@zaehlwerk.net
Dear Leo,

On Fri, Jun 30, 2017 at 12:45:46PM -0400, Leo Famulari wrote:
Toggle quote (3 lines)
> Thank you very much for investigating, and I'm sorry my response was
> rather slow! I just pushed revisions of your patches, based on our
> discussion, as 2973ebf504f4d958a8db40b09b210b237060fc92.
don't worry, I'm sure you guys have plenty of patches to investigate and
it was not a very important package. Thanks a lot for pushing!

Best,
Gregor
Closed
?