commit: 8cedc0877737ac4eb11bcd4c4314e63d020c877b Author: Sam James <sam <AT> gentoo <DOT> org> AuthorDate: Fri May 16 07:02:23 2025 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Fri May 16 07:03:08 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8cedc087
media-sound/linuxsampler: fix modern C issue in configure, other small bits * Filter LTO (bison ODR) * Drop obsolete --disable-static w/ EAPI 8 * Sync live ebuild (and drop workaround which was only in 9999 for bug #952945) Closes: https://bugs.gentoo.org/952945 Signed-off-by: Sam James <sam <AT> gentoo.org> .../files/linuxsampler-2.3.1-c99-configure.patch | 63 ++++++++++++++++++++++ ...r-2.3.1.ebuild => linuxsampler-2.3.1-r1.ebuild} | 14 +++-- media-sound/linuxsampler/linuxsampler-9999.ebuild | 17 +++--- 3 files changed, 84 insertions(+), 10 deletions(-) diff --git a/media-sound/linuxsampler/files/linuxsampler-2.3.1-c99-configure.patch b/media-sound/linuxsampler/files/linuxsampler-2.3.1-c99-configure.patch new file mode 100644 index 000000000000..e02e9aeb2d26 --- /dev/null +++ b/media-sound/linuxsampler/files/linuxsampler-2.3.1-c99-configure.patch @@ -0,0 +1,63 @@ +https://bugs.gentoo.org/952945 +--- a/configure.ac ++++ b/configure.ac +@@ -121,11 +121,11 @@ AC_RUN_IFELSE([AC_LANG_SOURCE([[ + #define _GNU_SOURCE 1 + #endif + #include <features.h> +-void main(void) { ++int main(void) { + #if _XOPEN_SOURCE >= 500 +-exit(0); /* UNIX98 compatible */ ++return 0; /* UNIX98 compatible */ + #else +-exit(-1); /* not UNIX98 compatible */ ++return 1; /* not UNIX98 compatible */ + #endif + } + ]])], +@@ -339,12 +339,12 @@ if test "$config_alsa_driver" = "yes"; then + AC_LANG_PUSH([C]) + AC_RUN_IFELSE([AC_LANG_SOURCE([[ + #include <alsa/asoundlib.h> +- void main(void) { ++ int main(void) { + /* ensure backward compatibility */ + #if !defined(SND_LIB_MAJOR) && defined(SOUNDLIB_VERSION_MAJOR) + #define SND_LIB_MAJOR SOUNDLIB_VERSION_MAJOR + #endif +- exit(SND_LIB_MAJOR); ++ return(SND_LIB_MAJOR); + } + ]])], + alsa_major=0, +@@ -353,12 +353,12 @@ if test "$config_alsa_driver" = "yes"; then + ) + AC_RUN_IFELSE([AC_LANG_SOURCE([[ + #include <alsa/asoundlib.h> +- void main(void) { ++ int main(void) { + /* ensure backward compatibility */ + #if !defined(SND_LIB_MINOR) && defined(SOUNDLIB_VERSION_MINOR) + #define SND_LIB_MINOR SOUNDLIB_VERSION_MINOR + #endif +- exit(SND_LIB_MINOR); ++ return(SND_LIB_MINOR); + } + ]])], + alsa_minor=0, +@@ -367,12 +367,12 @@ if test "$config_alsa_driver" = "yes"; then + ) + AC_RUN_IFELSE([AC_LANG_SOURCE([[ + #include <alsa/asoundlib.h> +- void main(void) { ++ int main(void) { + /* ensure backward compatibility */ + #if !defined(SND_LIB_SUBMINOR) && defined(SOUNDLIB_VERSION_SUBMINOR) + #define SND_LIB_SUBMINOR SOUNDLIB_VERSION_SUBMINOR + #endif +- exit(SND_LIB_SUBMINOR); ++ return(SND_LIB_SUBMINOR); + } + ]])], + alsa_subminor=0, diff --git a/media-sound/linuxsampler/linuxsampler-2.3.1.ebuild b/media-sound/linuxsampler/linuxsampler-2.3.1-r1.ebuild similarity index 90% rename from media-sound/linuxsampler/linuxsampler-2.3.1.ebuild rename to media-sound/linuxsampler/linuxsampler-2.3.1-r1.ebuild index c9fd88b64354..5dcb167c326f 100644 --- a/media-sound/linuxsampler/linuxsampler-2.3.1.ebuild +++ b/media-sound/linuxsampler/linuxsampler-2.3.1-r1.ebuild @@ -1,9 +1,9 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 -inherit autotools +inherit autotools flag-o-matic DESCRIPTION="Software audio sampler engine with professional grade features" HOMEPAGE="https://www.linuxsampler.org/" @@ -23,7 +23,8 @@ RDEPEND=" lv2? ( media-libs/lv2 ) sqlite? ( dev-db/sqlite ) " -DEPEND="${RDEPEND} +DEPEND=" + ${RDEPEND} media-libs/dssi media-libs/ladspa-sdk " @@ -36,22 +37,27 @@ PATCHES=( "${FILESDIR}/${PN}-2.0.0-nptl-hardened.patch" "${FILESDIR}/${PN}-2.0.0-lv2-automagic.patch" "${FILESDIR}/${PN}-2.1.1-fix-yyterror-not-declared.patch" + "${FILESDIR}/${PN}-2.3.1-c99-configure.patch" ) DOCS=( AUTHORS ChangeLog NEWS README ) src_prepare() { default + # Force regeneration of the file to let it build with all bison # versions, bug #556204 rm src/network/lscpparser.cpp || die + eautoreconf } src_configure() { + # bison ODR issues + filter-lto + local myeconfargs=( --disable-arts-driver - --disable-static $(use_enable alsa alsa-driver) $(use_enable jack jack-driver) $(use_enable lv2) diff --git a/media-sound/linuxsampler/linuxsampler-9999.ebuild b/media-sound/linuxsampler/linuxsampler-9999.ebuild index ff42e074adde..74c7d9fcf66f 100644 --- a/media-sound/linuxsampler/linuxsampler-9999.ebuild +++ b/media-sound/linuxsampler/linuxsampler-9999.ebuild @@ -1,9 +1,9 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 -inherit autotools subversion +inherit autotools flag-o-matic subversion DESCRIPTION="Software audio sampler engine with professional grade features" HOMEPAGE="https://www.linuxsampler.org/" @@ -15,14 +15,15 @@ IUSE="alsa doc jack lv2 sf2 sqlite" REQUIRED_USE="|| ( alsa jack )" RDEPEND=" - media-libs/libgig + >=media-libs/libgig-4.4.0 media-libs/libsndfile[-minimal] alsa? ( media-libs/alsa-lib ) jack? ( virtual/jack ) lv2? ( media-libs/lv2 ) sqlite? ( dev-db/sqlite ) " -DEPEND="${RDEPEND} +DEPEND=" + ${RDEPEND} media-libs/dssi media-libs/ladspa-sdk " @@ -34,6 +35,8 @@ BDEPEND=" PATCHES=( "${FILESDIR}/${PN}-2.0.0-nptl-hardened.patch" "${FILESDIR}/${PN}-2.0.0-lv2-automagic.patch" + "${FILESDIR}/${PN}-2.1.1-fix-yyterror-not-declared.patch" + "${FILESDIR}/${PN}-2.3.1-c99-configure.patch" ) DOCS=( AUTHORS ChangeLog NEWS README ) @@ -47,16 +50,18 @@ src_prepare() { } src_configure() { + # bison ODR issues + filter-lto + local myeconfargs=( --disable-arts-driver - --disable-static $(use_enable alsa alsa-driver) $(use_enable jack jack-driver) $(use_enable lv2) $(use_enable sqlite instruments-db) $(use_enable sf2 sf2-engine) ) - HAVE_UNIX98=1 econf "${myeconfargs[@]}" + econf "${myeconfargs[@]}" } src_compile() {
