mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
media-libs/libcuefile: bump cmake_min, fix math meaning clang-22
revbump because the patch fixes runtime behaviour Closes: https://bugs.gentoo.org/953935 Signed-off-by: Nicolas PARLANT <nicolas.parlant@parhuet.fr> Part-of: https://codeberg.org/gentoo/gentoo/pulls/1291 Merges: https://codeberg.org/gentoo/gentoo/pulls/1291 Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
committed by
Sam James
parent
eb8c6856c3
commit
b8bff05b74
21
media-libs/libcuefile/files/libcuefile-477-cmake4.patch
Normal file
21
media-libs/libcuefile/files/libcuefile-477-cmake4.patch
Normal file
@@ -0,0 +1,21 @@
|
||||
Bump cmake min to 3.20 and add explicit extensions for CMP0115
|
||||
https://bugs.gentoo.org/953935
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -1,4 +1,4 @@
|
||||
-CMAKE_MINIMUM_REQUIRED(VERSION 2.4)
|
||||
+CMAKE_MINIMUM_REQUIRED(VERSION 3.20)
|
||||
|
||||
project(libcuefile C)
|
||||
|
||||
--- a/src/CMakeLists.txt
|
||||
+++ b/src/CMakeLists.txt
|
||||
@@ -1,7 +1,7 @@
|
||||
add_definitions(-DYY_NEVER_INTERACTIVE)
|
||||
include_directories(${libcuefile_SOURCE_DIR}/include)
|
||||
|
||||
-add_library(cuefile-shared SHARED cd cdtext cue_parse cue_print cue_scan cuefile time toc toc_parse toc_print toc_scan)
|
||||
+add_library(cuefile-shared SHARED cd.c cdtext.c cue_parse.c cue_print.c cue_scan.c cuefile.c time.c toc.h toc_parse.c toc_print.c toc_scan.c)
|
||||
set_target_properties(cuefile-shared PROPERTIES OUTPUT_NAME cuefile CLEAN_DIRECT_OUTPUT 1 VERSION 0.0.0 SOVERSION 0)
|
||||
|
||||
install(TARGETS cuefile-shared LIBRARY DESTINATION "lib${LIB_SUFFIX}" ARCHIVE DESTINATION "lib${LIB_SUFFIX}")
|
||||
23
media-libs/libcuefile/files/libcuefile-477-mathmeaning.patch
Normal file
23
media-libs/libcuefile/files/libcuefile-477-mathmeaning.patch
Normal file
@@ -0,0 +1,23 @@
|
||||
patch from opensuse: https://build.opensuse.org/projects/openSUSE:Leap:15.6:Update/packages/libcuefile/files/mathmeaning.patch
|
||||
clang-22 error:
|
||||
chained comparison 'X < Y <= Z' does not behave the same as a mathematical expression
|
||||
--- a/src/cd.c
|
||||
+++ b/src/cd.c
|
||||
@@ -173,7 +173,7 @@ int cd_get_ntrack (Cd *cd)
|
||||
|
||||
Track *cd_get_track (Cd *cd, int i)
|
||||
{
|
||||
- if (0 < i <= cd->ntrack)
|
||||
+ if ((0 < i) && (i <= cd->ntrack))
|
||||
return cd->track[i - 1];
|
||||
|
||||
return NULL;
|
||||
@@ -306,7 +306,7 @@ int track_get_nindex (Track *track)
|
||||
|
||||
long track_get_index (Track *track, int i)
|
||||
{
|
||||
- if (0 <= i < track->nindex)
|
||||
+ if ((0 <= i) && (i < track->nindex))
|
||||
return track->index[i];
|
||||
|
||||
return -1;
|
||||
31
media-libs/libcuefile/libcuefile-477-r4.ebuild
Normal file
31
media-libs/libcuefile/libcuefile-477-r4.ebuild
Normal file
@@ -0,0 +1,31 @@
|
||||
# Copyright 1999-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit cmake
|
||||
|
||||
# svn export http://svn.musepack.net/libcuefile/trunk libcuefile-${PV}
|
||||
# tar -cJf libcuefile-${PV}.tar.xz libcuefile-${PV}
|
||||
|
||||
DESCRIPTION="Cue File library from Musepack"
|
||||
HOMEPAGE="https://www.musepack.net/"
|
||||
SRC_URI="https://dev.gentoo.org/~ssuominen/${P}.tar.xz"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-static-libs.patch
|
||||
"${FILESDIR}"/${PN}-477-clang16.patch
|
||||
"${FILESDIR}"/${PN}-477-mathmeaning.patch
|
||||
"${FILESDIR}"/${PN}-477-cmake4.patch
|
||||
)
|
||||
|
||||
src_install() {
|
||||
cmake_src_install
|
||||
|
||||
insinto /usr/include
|
||||
doins -r include/cuetools
|
||||
}
|
||||
Reference in New Issue
Block a user