blob: c4762ac7adb74a9322711889510b2f0c4e950f3f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
|
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit cmake flag-o-matic toolchain-funcs udev xdg
DESCRIPTION="Advanced Digital DJ tool based on Qt"
HOMEPAGE="https://mixxx.org/"
if [[ ${PV} == *9999 ]] ; then
inherit git-r3
if [[ ${PV} == ?.?.9999 ]] ; then
EGIT_BRANCH=${PV%.9999}
fi
EGIT_REPO_URI="https://github.com/mixxxdj/${PN}.git"
else
SRC_URI="https://github.com/mixxxdj/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="amd64 ~arm64 x86"
fi
LICENSE="GPL-2"
SLOT="0"
IUSE="aac benchmark ffmpeg keyfinder lv2 midi modplug mp3 mp4 opus"
IUSE+=" qtkeychain rubberband shout test upower wavpack"
REQUIRED_USE="
benchmark? ( test )
qtkeychain? ( shout )
test? ( aac ffmpeg midi mp3 opus rubberband )
"
RESTRICT="!test? ( test )"
RDEPEND="
dev-db/sqlite:3
dev-libs/hidapi
dev-libs/protobuf:=
dev-qt/qt5compat:6[qml]
dev-qt/qtbase:6[concurrent,dbus,gui,icu,network,opengl,sql,sqlite,ssl,widgets,xml,X]
dev-qt/qtdeclarative:6
dev-qt/qtshadertools:6
dev-qt/qtsvg:6
media-libs/chromaprint:=
media-libs/flac:=
media-libs/libebur128:=
media-libs/libglvnd[X]
media-libs/libogg
media-libs/libsndfile
media-libs/libsoundtouch:=
media-libs/libvorbis
media-libs/portaudio
<media-libs/taglib-2
media-sound/lame
virtual/glu
virtual/libusb:1
virtual/udev
x11-libs/libX11
aac? (
media-libs/faad2
media-libs/libmp4v2
)
benchmark? (
dev-cpp/benchmark:=
dev-cpp/gtest
dev-util/google-perftools:=
)
ffmpeg? ( media-video/ffmpeg:= )
keyfinder? ( media-libs/libkeyfinder )
lv2? ( media-libs/lilv )
midi? ( media-libs/portmidi )
modplug? ( media-libs/libmodplug )
mp3? (
media-libs/libid3tag:=
media-libs/libmad
)
mp4? ( media-libs/libmp4v2 )
opus? (
media-libs/opus
media-libs/opusfile
)
qtkeychain? ( >=dev-libs/qtkeychain-0.14.2:=[qt6(+)] )
rubberband? ( media-libs/rubberband:= )
shout? ( dev-libs/openssl:= )
upower? (
dev-libs/glib:2
sys-power/upower:=
)
wavpack? ( media-sound/wavpack )
"
DEPEND="${RDEPEND}
dev-cpp/ms-gsl
test? ( dev-cpp/gtest )
"
BDEPEND="
dev-util/spirv-tools
virtual/pkgconfig
"
PATCHES=(
# Building mixxx-test target only with explicit test useflag
"${FILESDIR}"/${P}-tests.patch
# Fix strict-aliasing violations in vendored katai_cpp_stl_runtime
# https://github.com/kaitai-io/kaitai_struct_cpp_stl_runtime/commit/c01f530.patch
"${FILESDIR}"/${PN}-2.5.0-fix-strict-aliasing-kaitai.patch
)
CMAKE_SKIP_TESTS=(
# need HID controller
LegacyControllerMappingValidationTest.HidMappingsValid
# randomly fails
# https://github.com/mixxxdj/mixxx/issues/12554
EngineBufferE2ETest
)
src_configure() {
# prevent ld error as package builds static libs.
tc-is-lto && append-flags $(test-flags -ffat-lto-objects)
local mycmakeargs=(
-DBATTERY="$(usex upower)"
-DBROADCAST="$(usex shout)"
-DBUILD_SHARED_LIBS=ON
-DBUILD_TESTING="$(usex test)"
-DBUILD_BENCH="$(usex benchmark)"
# prevent duplicate call
-DCCACHE_SUPPORT=OFF
-DENGINEPRIME=OFF
-DFAAD="$(usex aac)"
-DFFMPEG="$(usex ffmpeg)"
-DGPERFTOOLS="$(usex benchmark)"
-DGPERFTOOLSPROFILER="$(usex benchmark)"
-DHID=ON
-DINSTALL_USER_UDEV_RULES=OFF
-DKEYFINDER="$(usex keyfinder)"
-DLILV="$(usex lv2)"
-DMAD="$(usex mp3)"
-DMODPLUG="$(usex modplug)"
-DOPTIMIZE=OFF
-DOPUS="$(usex opus)"
-DPORTMIDI="$(usex midi)"
-DQML=ON
-DQTKEYCHAIN="$(usex qtkeychain)"
-DRUBBERBAND="$(usex rubberband)"
-DVINYLCONTROL=ON
-DWAVPACK="$(usex wavpack)"
)
cmake_src_configure
}
src_install() {
cmake_src_install
use benchmark && dobin "${BUILD_DIR}"/mixxx-test
udev_newrules "${S}"/res/linux/mixxx-usb-uaccess.rules 69-mixxx-usb-uaccess.rules
}
pkg_postinst() {
xdg_pkg_postinst
udev_reload
elog "Manuals are no longer part of the package."
elog "Please refer to https://downloads.mixxx.org/manual/ for up-to-date manuals."
if use benchmark; then
elog ""
elog "Launch benchmark : ${EROOT}/usr/bin/mixxx-test --benchmark"
elog "Launch Unittests : ${EROOT}/usr/bin/mixxx-test"
elog "Some test suites may not be available without source files."
fi
}
pkg_postrm() {
xdg_pkg_postrm
udev_reload
}
|