Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

media-sound/drumkv1-0.9.21 fails to build (fix included) #559

Open
cbirchinger opened this issue Feb 6, 2024 · 2 comments · May be fixed by #561
Open

media-sound/drumkv1-0.9.21 fails to build (fix included) #559

cbirchinger opened this issue Feb 6, 2024 · 2 comments · May be fixed by #561
Assignees

Comments

@cbirchinger
Copy link

checking for x86_64-pc-linux-gnu-qmake-qt5... no
checking for qmake-qt5... no
checking for x86_64-pc-linux-gnu-qmake-qt6... no
checking for qmake-qt6... no
checking for Qt major version... ./configure: line 5314: no: command not found
0
configure: error: qmake-qt5 not found in current PATH. Maybe QT development environment isn't available. (qt5-devel)

That's a very common issue because the current Gentoo QT5 install doesn't have qmake-qt5 but qmake5.
Having it use plain qmake and depending on having the correct PATH will also work.

The following in the src_configure section will work around these issues. It's also done this way in certain upstream ebuilds:

inherit qmake-utils
[...]
src_configure() {
  export PATH="$(qt5_get_bindir):${PATH}"
[...]
@cbirchinger
Copy link
Author

If you want, i did an initial ebuild for drumkv1-0.9.34.ebuild which switched to CMake and QT6, so it's quite different.
I haven't tested all possible use flag combinations or the 9999 live build variant.

# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

inherit cmake xdg-utils

DESCRIPTION="An old-school all-digital drum-kit sampler synthesizer with stereo fx"
HOMEPAGE="http://drumkv1.sourceforge.net/"
if [[ ${PV} == *9999 ]]; then
        inherit git-r3
        EGIT_REPO_URI="https://github.com/rncbc/${PN}.git"
        KEYWORDS=""
else
        MY_PV=$(ver_rs 1- _)
        SRC_URI="https://github.com/rncbc/${PN}/archive/${PN}_${MY_PV}.tar.gz -> ${P}.tar.gz"
        KEYWORDS="~amd64"
        RESTRICT="mirror"
        S="${WORKDIR}/${PN}-${PN}_${MY_PV}"
fi
LICENSE="GPL-2+"
SLOT="0"

IUSE="standalone alsa lv2 osc"
REQUIRED_USE="
        || ( standalone lv2 )
        alsa? ( standalone )"

RDEPEND="
        dev-qt/qtbase:6=[gui]
        media-libs/libsndfile
        standalone? ( virtual/jack )
        alsa? ( media-libs/alsa-lib )
        lv2? ( media-libs/lv2 )
        osc? ( media-libs/liblo )
"
DEPEND="${RDEPEND}"

src_prepare() {
        # -DCMAKE_BUILD_TYPE=Debug and -DCONFIG_DEBUG=1 wont prevent stripping for some reason
        sed -e 's/COMMAND strip/COMMAND true/' \
                -i src/CMakeLists.txt || die

        cmake_src_prepare
}

src_configure() {
        local -a mycmakeargs=(
                -DCONFIG_ALSA_MIDI=$(usex alsa 1 0)
                -DCONFIG_JACK=$(usex standalone 1 0)
                -DCONFIG_JACK_SESSION=$(usex standalone 1 0)
                -DCONFIG_JACK_MIDI=$(usex standalone 1 0)
                -DCONFIG_LV2=$(usex lv2 1 0)
                -DCONFIG_LIBLO=$(usex osc 1 0)
        )
        cmake_src_configure
}

pkg_postinst() {
        xdg_desktop_database_update
        xdg_mimeinfo_database_update
        xdg_icon_cache_update
}

pkg_postrm() {
        xdg_desktop_database_update
        xdg_mimeinfo_database_update
        xdg_icon_cache_update
}

NexAdn added a commit to NexAdn/audio-overlay that referenced this issue Mar 30, 2024
This version fixes both build issues due to missing qmake-qt5, but also
restructures the ebuild to use upstream's CMake build system and support
both Qt5 and Qt6.

Closes: gentoo-audio#559
@NexAdn
Copy link
Member

NexAdn commented Mar 30, 2024

Thank you for your contribution. I've used this to restructure the current ebuilds. Please have a look at PR #561 and see if it works on your machine. Thanks!

@NexAdn NexAdn self-assigned this Mar 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

2 participants