* [PR PATCH] lame: fix ID3 tags on musl
@ 2023-04-20 17:37 balejk
2023-04-24 16:19 ` [PR PATCH] [Closed]: " sgn
0 siblings, 1 reply; 2+ messages in thread
From: balejk @ 2023-04-20 17:37 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1677 bytes --]
There is a new pull request by balejk against master on the void-packages repository
https://github.com/balejk/void-packages lame-translit
https://github.com/void-linux/void-packages/pull/43550
lame: fix ID3 tags on musl
<!-- Uncomment relevant sections and delete options which are not applicable -->
musl's iconv does not support transliterations causing `lame` to fail to write most of the ID3 tags.
I have modified the code so that it only does transliteration if the host libc is glibc. I don't know whether there are any other iconv implementations which support this, if so, please let me know and I can try to add them, although for Void's purposes it's needless at the moment.
I have not attempted to submit the patch upstream as it seems inactive, I might try to do so later.
#### Testing the changes
- I tested the changes in this PR: **YES** (on musl)
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
#### Local build testing
- I built this PR locally for my native architecture, (x86_64-musl)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64
A patch file from https://github.com/void-linux/void-packages/pull/43550.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-lame-translit-43550.patch --]
[-- Type: text/x-diff, Size: 1946 bytes --]
From 1797153489c2cfbfcedab88f863a72f25852eb14 Mon Sep 17 00:00:00 2001
From: Karel Balej <balejk@matfyz.cz>
Date: Thu, 20 Apr 2023 19:15:09 +0200
Subject: [PATCH] lame: fix ID3 tags on musl
---
srcpkgs/lame/patches/translit.patch | 26 ++++++++++++++++++++++++++
srcpkgs/lame/template | 2 +-
2 files changed, 27 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/lame/patches/translit.patch
diff --git a/srcpkgs/lame/patches/translit.patch b/srcpkgs/lame/patches/translit.patch
new file mode 100644
index 000000000000..660c57c930d9
--- /dev/null
+++ b/srcpkgs/lame/patches/translit.patch
@@ -0,0 +1,26 @@
+--- lame/frontend/parse.c 2023-04-20 18:12:43.988212890 +0200
++++ - 2023-04-20 18:13:39.537622345 +0200
+@@ -232,7 +232,11 @@
+ dst = calloc(n+4, 4);
+ if (dst != 0) {
+ char* cur_code = nl_langinfo(CODESET);
++#ifdef __GNU_LIBRARY__
+ iconv_t xiconv = iconv_open("ISO_8859-1//TRANSLIT", cur_code);
++#else
++ iconv_t xiconv = iconv_open("ISO_8859-1", cur_code);
++#endif
+ if (xiconv != (iconv_t)-1) {
+ char* i_ptr = (char*)src;
+ char* o_ptr = dst;
+@@ -258,7 +262,11 @@
+ dst = calloc(n+4, 4);
+ if (dst != 0) {
+ char* cur_code = nl_langinfo(CODESET);
++#ifdef __GNU_LIBRARY__
+ iconv_t xiconv = iconv_open("UTF-16LE//TRANSLIT", cur_code);
++#else
++ iconv_t xiconv = iconv_open("UTF-16LE", cur_code);
++#endif
+ dst[0] = 0xff;
+ dst[1] = 0xfe;
+ if (xiconv != (iconv_t)-1) {
diff --git a/srcpkgs/lame/template b/srcpkgs/lame/template
index 7718c7720c76..5bc4247b3f43 100644
--- a/srcpkgs/lame/template
+++ b/srcpkgs/lame/template
@@ -1,7 +1,7 @@
# Template file for 'lame'
pkgname=lame
version=3.100
-revision=1
+revision=2
build_style=gnu-configure
configure_args="--enable-nasm --enable-shared"
hostmakedepends="nasm"
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PR PATCH] [Closed]: lame: fix ID3 tags on musl
2023-04-20 17:37 [PR PATCH] lame: fix ID3 tags on musl balejk
@ 2023-04-24 16:19 ` sgn
0 siblings, 0 replies; 2+ messages in thread
From: sgn @ 2023-04-24 16:19 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1522 bytes --]
There's a closed pull request on the void-packages repository
lame: fix ID3 tags on musl
https://github.com/void-linux/void-packages/pull/43550
Description:
<!-- Uncomment relevant sections and delete options which are not applicable -->
musl's iconv does not support transliterations causing `lame` to fail to write most of the ID3 tags.
I have modified the code so that it only does transliteration if the host libc is glibc. I don't know whether there are any other iconv implementations which support this, if so, please let me know and I can try to add them, although for Void's purposes it's needless at the moment.
I have not attempted to submit the patch upstream as it seems inactive, I might try to do so later.
#### Testing the changes
- I tested the changes in this PR: **YES** (on musl)
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
#### Local build testing
- I built this PR locally for my native architecture, (x86_64-musl)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-04-24 16:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-04-20 17:37 [PR PATCH] lame: fix ID3 tags on musl balejk
2023-04-24 16:19 ` [PR PATCH] [Closed]: " sgn
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 NNTP newsgroup(s).