Files
packages/anda/apps/vlc/libidn2.patch
T
Raboneko 604624f151 [f43] add: VLC (#8519) (#8523)
* add: VLC

* cleanup: New macros and bump release down

* fix: NO

* Cleanup and check if VLC is where it thinks it is?

* cat the log to see what's wrong

* cat the log to see what's wrong

* Try to get errors from this thing

* Empty commit because GitHub is testing my patience



* Try this?

* shdfshdfhj

* Cleanup spec and see if this works

* What now

* This will have to do.

---------


(cherry picked from commit a35314d3fc)

Signed-off-by: Gilver <rockgrub@disroot.org>
Co-authored-by: Gilver <rockgrub@disroot.org>
2025-12-20 00:10:46 -06:00

50 lines
1.4 KiB
Diff

diff --git a/configure.ac b/configure.ac
index 78b9ce2..b9c1563 100644
--- a/configure.ac
+++ b/configure.ac
@@ -910,9 +910,9 @@ AM_CONDITIONAL(HAVE_MINIZIP, [ test "${have_minizip}" = "yes" ])
dnl
-dnl Domain name i18n support via GNU libidn
+dnl Domain name i18n support via GNU libidn2
dnl
-PKG_CHECK_MODULES([IDN], [libidn], [
+PKG_CHECK_MODULES([IDN], [libidn2], [
have_libidn="yes"
AC_DEFINE([HAVE_IDN], 1, [Define to 1 if you have GNU libidn.])
], [
diff --git a/src/text/url.c b/src/text/url.c
index 2eb4b8d..467b7f3 100644
--- a/src/text/url.c
+++ b/src/text/url.c
@@ -873,7 +873,7 @@ char *vlc_uri_fixup(const char *str)
}
#if defined (HAVE_IDN)
-# include <idna.h>
+# include <idn2.h>
#elif defined (_WIN32)
# include <windows.h>
# include <vlc_charset.h>
@@ -914,16 +914,13 @@ static char *vlc_idna_to_ascii (const char *idn)
#if defined (HAVE_IDN)
char *adn;
- switch (idna_to_ascii_8z(idn, &adn, IDNA_ALLOW_UNASSIGNED))
+ switch (idn2_to_ascii_8z(idn, &adn, IDN2_ALLOW_UNASSIGNED|IDN2_NFC_INPUT|IDN2_NONTRANSITIONAL))
{
- case IDNA_SUCCESS:
+ case IDN2_OK:
return adn;
- case IDNA_MALLOC_ERROR:
+ case IDN2_MALLOC:
errno = ENOMEM;
return NULL;
- case IDNA_DLOPEN_ERROR:
- errno = ENOSYS;
- return NULL;
default:
errno = EINVAL;
return NULL;