diff --git a/srcpkgs/lame/patches/lame-cbr-abr-quality-settings-clamp.patch b/srcpkgs/lame/patches/lame-cbr-abr-quality-settings-clamp.patch new file mode 100644 index 00000000000..4b29e0c09c0 --- /dev/null +++ b/srcpkgs/lame/patches/lame-cbr-abr-quality-settings-clamp.patch @@ -0,0 +1,19 @@ +Description: CBR: High quality settings (e.g, -q 0) degrade quality over -q 4 +Origin: https://sourceforge.net/p/lame/bugs/516/#a26d +Forwarded: https://sourceforge.net/p/lame/bugs/516/ + +--- a/libmp3lame/lame.c ++++ b/libmp3lame/lame.c +@@ -1050,6 +1050,11 @@ lame_init_params(lame_global_flags * gfp + if (gfp->quality < 0) + gfp->quality = LAME_DEFAULT_QUALITY; + ++ /* VBR and ABR don't give good results with noise shaping ++ * settings used in quality levels below 4. ++ */ ++ if (gfp->quality < 4) ++ gfp->quality = 4; + + if (cfg->vbr == vbr_off) + (void) lame_set_VBR_mean_bitrate_kbps(gfp, gfp->brate); + diff --git a/srcpkgs/lame/patches/lame-symbols.patch b/srcpkgs/lame/patches/lame-symbols.patch new file mode 100644 index 00000000000..56bdc055525 --- /dev/null +++ b/srcpkgs/lame/patches/lame-symbols.patch @@ -0,0 +1,15 @@ +Description: Add missing symbol(s) to library symbol file +Author: Fabian Greffrath +Forwarded: https://sourceforge.net/p/lame/bugs/515/ + +--- a/include/libmp3lame.sym ++++ b/include/libmp3lame.sym +@@ -193,6 +193,7 @@ hip_decode_headers + hip_decode1 + hip_decode1_headers + hip_decode1_headersB ++hip_finish_pinfo + lame_decode_init + lame_decode + lame_decode_headers + diff --git a/srcpkgs/lame/patches/translit.patch b/srcpkgs/lame/patches/translit.patch index bbcb14b3609..ba9a11dede7 100644 --- a/srcpkgs/lame/patches/translit.patch +++ b/srcpkgs/lame/patches/translit.patch @@ -3,7 +3,7 @@ @@ -232,7 +232,11 @@ dst = calloc(n+4, 4); if (dst != 0) { - char* cur_code = nl_langinfo(CODESET); + char* cur_code = currentCharacterEncoding(); +#ifdef __GLIBC__ iconv_t xiconv = iconv_open("ISO_8859-1//TRANSLIT", cur_code); +#else @@ -15,7 +15,7 @@ @@ -258,7 +262,11 @@ dst = calloc(n+4, 4); if (dst != 0) { - char* cur_code = nl_langinfo(CODESET); + char* cur_code = currentCharacterEncoding(); +#ifdef __GLIBC__ iconv_t xiconv = iconv_open("UTF-16LE//TRANSLIT", cur_code); +#else diff --git a/srcpkgs/lame/template b/srcpkgs/lame/template index 68a6746efb9..d797c9a2b1c 100644 --- a/srcpkgs/lame/template +++ b/srcpkgs/lame/template @@ -1,17 +1,20 @@ # Template file for 'lame' pkgname=lame -version=3.100 -revision=2 +version=4.0 +revision=1 build_style=gnu-configure configure_args="--enable-nasm --enable-shared" -hostmakedepends="nasm" -makedepends="ncurses-devel" +hostmakedepends="nasm pkg-config" +makedepends="ncurses-devel mpg123-devel" short_desc="Fast, high quality MP3 encoder" maintainer="Orphaned " license="LGPL-2.1-or-later" -homepage="http://lame.sourceforge.net" +homepage="https://lame.sourceforge.io/" +changelog="https://svn.code.sf.net/p/lame/svn/trunk/lame/doc/html/history.html" distfiles="${SOURCEFORGE_SITE}/lame/lame-${version}.tar.gz" -checksum=ddfe36cab873794038ae2c1210557ad34857a4b6bdc515785d1da9e175b1da1e +checksum=3df5124d5ad3a98312ffd7ba6a9b36230e4f8a3e66d3ce0f425e336c32d216eb + +CFLAGS="-Wno-implicit-function-declaration -Wno-incompatible-pointer-types" pre_configure() { if [ "${XBPS_TARGET_MACHINE%%-musl}" = "i686" ]; then