commit 8466e1f1c1fcd919528a3511b31c1759ac8750bc
Author: Uwe Klotz <uklotz(a)mixxx.org>
Date: Tue Mar 17 14:44:32 2020 +0100
New upstream snapshot 2.3.0-pre-alpha built with CMake
mixxx.spec | 163 ++++++++++++++++++++++++++-----------------
usb_hidapi_udev_rules0.patch | 95 +++++++++++++++++++++++++
usb_hidapi_udev_rules1.patch | 78 +++++++++++++++++++++
3 files changed, 272 insertions(+), 64 deletions(-)
---
diff --git a/mixxx.spec b/mixxx.spec
index f7bf678..6a4e065 100644
--- a/mixxx.spec
+++ b/mixxx.spec
@@ -1,10 +1,10 @@
# Optional: Package version suffix for pre-releases, e.g. "beta" or
"rc"
-#global extraver rc
+%global extraver alpha
# Optional: Only used for untagged snapshot versions
-#global gitcommit d9d7ea6404de71c86beacfc86f9087dc8db0fc58
+%global gitcommit e16b6a63b28eab4d3c3ce919ed661a91d7fc664d
# Format: <yyyymmdd>
-#global gitcommitdate 20181224
+%global gitcommitdate 20200316
%if "%{?gitcommit}" == ""
# (Pre-)Releases
@@ -16,21 +16,23 @@
%endif
Name: mixxx
-Version: 2.2.3
-Release: 3%{?extraver:.%{extraver}}%{?snapinfo:.%{snapinfo}}%{?dist}
+Version: 2.3.0
+Release: 0.1%{?extraver:.%{extraver}}%{?snapinfo:.%{snapinfo}}%{?dist}
Summary: Mixxx is open source software for DJ'ing
Group: Applications/Multimedia
License: GPLv2+
URL:
http://www.mixxx.org
Source0:
https://github.com/mixxxdj/%{name}/archive/%{sources}.tar.gz#/%{name}-%{s...
+Patch0: usb_hidapi_udev_rules0.patch
+Patch1: usb_hidapi_udev_rules1.patch
# Build Tools
BuildRequires: desktop-file-utils
BuildRequires: libappstream-glib
BuildRequires: protobuf-compiler
-# TODO: Update to python3-scons for 2.3.0
-# TODO: Update to cmake for 2.4.0
-BuildRequires: python2-scons
+BuildRequires: cmake
+BuildRequires: ccache
+BuildRequires: gcc-c++
# Build Requirements
BuildRequires: chrpath
@@ -80,89 +82,122 @@ through the GUI or with external controllers including
MIDI and HID devices.
+%global debug_package %{nil}
+
+
%prep
%autosetup -p1 -n %{name}-%{sources}
-
-# TODO: Remove bundled libs before build?
-#rm -rf \
-# lib/gmock* \
-# lib/gtest* \
-# lib/libebur128* \
-# lib/soundtouch* \
-# lib/vamp \
-# lib/xwax \
+echo "#pragma once" > src/build.h
+%if 0%{?extraver:1}
+ echo "#define BUILD_BRANCH \"%{extraver}\"" >> src/build.h
+%endif
+%if 0%{?snapinfo:1}
+ echo "#define BUILD_REV \"%{snapinfo}\"" >> src/build.h
+%endif
%build
-export CFLAGS=$RPM_OPT_FLAGS
-export LDFLAGS=$RPM_LD_FLAGS
-export LIBDIR=%{_libdir}
-# TODO: Switch from scons-2 to scons(-3) for 2.3.0
-scons-2 %{?_smp_mflags} \
- prefix=%{_prefix} \
- qtdir=%{_qt5_prefix} \
- build=release \
- optimize=portable \
- bulk=1 \
- faad=1 \
- ffmpeg=1 \
- hid=1 \
- modplug=1 \
- opus=1 \
- qtkeychain=1 \
- shoutcast=1 \
- wv=1 \
+ccache -s
+mkdir -p cmake_build
+cd cmake_build
+cmake \
+ -DCMAKE_POSITION_INDEPENDENT_CODE=ON \
+ -DCMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES=%{_includedir} \
+ -DCMAKE_INSTALL_PREFIX=%{_prefix} \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DOPTIMIZE=portable \
+ -DINSTALL_GTEST=OFF \
+ -DWITH_STATIC_PIC=ON \
+ -DBATTERY=ON \
+ -DBROADCAST=ON \
+ -DBULK=ON \
+ -DFAAD=ON \
+ -DFFMPEG=ON \
+ -DHID=ON \
+ -DLOCALECOMPARE=ON \
+ -DLILV=ON \
+ -DMAD=ON \
+ -DMODPLUG=ON \
+ -DOPUS=ON \
+ -DQTKEYCHAIN=ON \
+ -DVINYLCONTROL=ON \
+ -DWAVPACK=ON \
+ ..
+cmake \
+ --build . \
+ --target mixxx \
+ %{?_smp_mflags}
%install
-export CFLAGS=$RPM_OPT_FLAGS
-export LDFLAGS=$RPM_LD_FLAGS
-export LIBDIR=%{_libdir}
-# TODO: Switch from scons-2 to scons(-3) for 2.3.0
-scons-2 %{?_smp_mflags} \
- prefix=%{_prefix} \
- qtdir=%{_qt5_prefix} \
- install_root=$RPM_BUILD_ROOT%{_prefix} \
- install
-
-# Install udev rule
-install -d ${RPM_BUILD_ROOT}%{_udevrulesdir}
-install -p -m 0644 res/linux/mixxx.usb.rules
${RPM_BUILD_ROOT}%{_udevrulesdir}/90-mixxx.usb.rules
+# Executable
+install -Dpsm 0755 \
+ -t %{buildroot}%{_bindir} \
+ cmake_build/%{name}
+
+# Icon
+install -Dpm 0644 \
+ -t %{buildroot}%{_datadir}/pixmaps \
+ res/images/%{name}_icon.svg \
+
+# Resources
+for subdir in controllers fonts keyboard skins translations
+do
+ pushd .
+ cd res/$subdir
+ find . \
+ -type f \
+ -exec install -Dpm 0644 "{}"
"%{buildroot}%{_datadir}/%{name}/$subdir/{}" \;
+ popd
+done
+
+# Docs
+install -Dpm 0644 \
+ -t %{buildroot}%{_docdir}/%{name} \
+ README \
+ README.md \
+ Mixxx-Manual.pdf
+
+# USB HID permissions
+# Order custom rules before 70-uaccess.rules
+install -Dpm 0644 \
+ res/linux/%{name}-usb-uaccess.rules \
+ %{buildroot}%{_udevrulesdir}/69-%{name}-usb-uaccess.rules
+
+# Desktop launcher
desktop-file-install \
--vendor "" \
- --dir $RPM_BUILD_ROOT%{_datadir}/applications \
+ --dir %{buildroot}%{_datadir}/applications \
--add-category=X-Synthesis \
- res/linux/mixxx.desktop
+ res/linux/%{name}.desktop
+# AppStream metadata
appstream-util \
validate-relax \
--nonet \
- $RPM_BUILD_ROOT%{_datadir}/appdata/%{name}.appdata.xml
-
-# Workaround: Manually strip RPATH from installed binaries
-chrpath --delete $RPM_BUILD_ROOT%{_bindir}/%{name}
-chrpath --delete $RPM_BUILD_ROOT%{_libdir}/%{name}/plugins/vampqt5/libmixxxminimal.so
-chrpath --delete
$RPM_BUILD_ROOT%{_libdir}/%{name}/plugins/soundsourceqt5/libsoundsourcem4a.so
-chrpath --delete
$RPM_BUILD_ROOT%{_libdir}/%{name}/plugins/soundsourceqt5/libsoundsourcewv.so
-
-# Remove docdir
-rm -rf $RPM_BUILD_ROOT%{_docdir}
+ res/linux/%{name}.appdata.xml
+install -Dpm 0644 \
+ -t %{buildroot}%{_datadir}/appdata \
+ res/linux/%{name}.appdata.xml
%files
%license COPYING LICENSE
%doc Mixxx-Manual.pdf README README.md
%{_bindir}/%{name}
-%{_libdir}/%{name}/
%{_datadir}/%{name}/
-%{_datadir}/applications/mixxx.desktop
-%{_datadir}/pixmaps/mixxx_icon.svg
+%{_datadir}/applications/%{name}.desktop
+%{_datadir}/pixmaps/%{name}_icon.svg
%{_datadir}/appdata/%{name}.appdata.xml
-%{_udevrulesdir}/90-mixxx.usb.rules
+%{_udevrulesdir}/69-%{name}-usb-uaccess.rules
%changelog
+* Tue Mar 17 2020 Uwe Klotz <uklotz(a)mixxx.org> -
2.3.0-0.1.alpha.20200316gite16b6a6
+- New upstream snapshot 2.3.0-pre-alpha
+- Replaced build system SCons with CMake
+
* Wed Feb 05 2020 RPM Fusion Release Engineering <leigh123linux(a)gmail.com> -
2.2.3-3
- Rebuilt for
https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
diff --git a/usb_hidapi_udev_rules0.patch b/usb_hidapi_udev_rules0.patch
new file mode 100644
index 0000000..1fc400c
--- /dev/null
+++ b/usb_hidapi_udev_rules0.patch
@@ -0,0 +1,95 @@
+From 5d1a915b655cf9060238275d8078f00c910f4f5a Mon Sep 17 00:00:00 2001
+From: Uwe Klotz <uklotz(a)mixxx.org>
+Date: Thu, 12 Mar 2020 11:44:29 +0100
+Subject: [PATCH 1/2] Change USB HID udev rules from GROUP/MODE to TAG uaccess
+
+---
+ CMakeLists.txt | 2 +-
+ SConscript | 4 +--
+ ...ixxx.usb.rules => mixxx-usb-uaccess.rules} | 25 ++++++++++---------
+ 3 files changed, 16 insertions(+), 15 deletions(-)
+ rename res/linux/{mixxx.usb.rules => mixxx-usb-uaccess.rules} (56%)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index aa5fba2edf..e95b430532 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -879,7 +879,7 @@ install(
+
+ # udev rule file for USB HID and Bulk controllers
+ install(
+- FILES ${CMAKE_CURRENT_SOURCE_DIR}/res/linux/mixxx.usb.rules
++ FILES ${CMAKE_CURRENT_SOURCE_DIR}/res/linux/mixxx-usb-uaccess.rules
+ DESTINATION ${CMAKE_INSTALL_SYSCONFDIR}/udev/rules.d
+ )
+
+diff --git a/SConscript b/SConscript
+index 4a8d90d1fc..0eb8785093 100644
+--- a/SConscript
++++ b/SConscript
+@@ -287,7 +287,7 @@ dotdesktop_files = Glob('#res/linux/mixxx.desktop')
+ dotappstream_files = Glob('#res/linux/mixxx.appdata.xml')
+
+ #udev rule file for USB HID and Bulk controllers
+-hidudev_files = Glob('#res/linux/mixxx.usb.rules')
++hidudev_files = Glob('#res/linux/mixxx-usb-uaccess.rules')
+
+ #Icon file for menu entry
+ icon_files = Glob('#res/images/mixxx_icon.svg')
+@@ -1009,7 +1009,7 @@ def BuildUbuntuPackage(target, source, env):
+ print("* Copying Debian build directory from build/debian to debian (cwd:
%s)" % os.getcwd())
+ print()
+ os.system('cp -r build/debian .')
+- os.system('cp res/linux/mixxx.usb.rules ./debian/mixxx.mixxx-usb.udev')
++ os.system('cp res/linux/mixxx-usb-uaccess.rules
./debian/mixxx.mixxx-usb.udev')
+
+ scons_flags = ' '.join([
+ 'optimize=portable',
+diff --git a/res/linux/mixxx.usb.rules b/res/linux/mixxx-usb-uaccess.rules
+similarity index 56%
+rename from res/linux/mixxx.usb.rules
+rename to res/linux/mixxx-usb-uaccess.rules
+index 7187e8a0b0..1e1a9a842a 100644
+--- a/res/linux/mixxx.usb.rules
++++ b/res/linux/mixxx-usb-uaccess.rules
+@@ -1,25 +1,26 @@
+ # This udev rule allows Mixxx to access HID and USB Bulk controllers when running as a
normal user
+
+-# Allow write access for all users in the "users" group for USB devices from
known vendors
+-# that make HID or USB bulk controllers. Note that the udev rule must match on the USB
device level;
+-# matching the USB interface descriptor with bInterfaceClass does not work.
++# Note that the udev rule must match on the USB device level; matching the USB
interface
++# descriptor with bInterfaceClass does not work.
++
++# Install and execute before 70-uaccess.rules, e.g.
.../udev/rules.d/69-mixxx-usb-uaccess.rules
+
+ # Native Instruments
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="17cc", GROUP="users", MODE="0660"
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="17cc", TAG+="uaccess"
+ # Hercules
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="06f8", GROUP="users", MODE="0660"
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="06f8", TAG+="uaccess"
+ # Pioneer
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="08e4", GROUP="users", MODE="0660"
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="08e4", TAG+="uaccess"
+ # Numark (may be needed for NS7 & V7)
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="15e4", GROUP="users", MODE="0660"
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="15e4", TAG+="uaccess"
+ # Eks
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="1157", GROUP="users", MODE="0660"
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="1157", TAG+="uaccess"
+ # Nintendo
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="057e", GROUP="users", MODE="0660"
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="057e", TAG+="uaccess"
+ # Sony
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="054c", GROUP="users", MODE="0660"
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="054c", TAG+="uaccess"
+ # Gemini
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="23c7", GROUP="users", MODE="0660"
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="23c7", TAG+="uaccess"
+
+ # Only some distribuions require the below
+-KERNEL=="hiddev*", NAME="usb/%k", GROUP="users"
++KERNEL=="hiddev*", NAME="usb/%k", GROUP="uaccess"
+--
+2.25.1
diff --git a/usb_hidapi_udev_rules1.patch b/usb_hidapi_udev_rules1.patch
new file mode 100644
index 0000000..e9c49ea
--- /dev/null
+++ b/usb_hidapi_udev_rules1.patch
@@ -0,0 +1,78 @@
+From 9f01191fa5d61e993301f9e1d56bddee20460dd9 Mon Sep 17 00:00:00 2001
+From: Uwe Klotz <uklotz(a)mixxx.org>
+Date: Thu, 12 Mar 2020 12:00:12 +0100
+Subject: [PATCH 2/2] Extend, update, and sort list of USB vendor ids
+
+---
+ res/linux/mixxx-usb-uaccess.rules | 48 +++++++++++++++++++++++--------
+ 1 file changed, 36 insertions(+), 12 deletions(-)
+
+diff --git a/res/linux/mixxx-usb-uaccess.rules b/res/linux/mixxx-usb-uaccess.rules
+index 1e1a9a842a..0f8a67809b 100644
+--- a/res/linux/mixxx-usb-uaccess.rules
++++ b/res/linux/mixxx-usb-uaccess.rules
+@@ -1,26 +1,50 @@
+ # This udev rule allows Mixxx to access HID and USB Bulk controllers when running as a
normal user
+
++# Sources:
++#
http://www.linux-usb.org/usb.ids
++#
https://www.the-sz.com/products/usbid/
++#
https://devicehunt.com/all-usb-vendors
++
+ # Note that the udev rule must match on the USB device level; matching the USB
interface
+ # descriptor with bInterfaceClass does not work.
+
+ # Install and execute before 70-uaccess.rules, e.g.
.../udev/rules.d/69-mixxx-usb-uaccess.rules
+
+-# Native Instruments
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="17cc", TAG+="uaccess"
+-# Hercules
++# Allen + Heath Ltd.
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="22f0", TAG+="uaccess"
++# Arturia
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="1c75", TAG+="uaccess"
++# BEHRINGER International GmbH
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="1397", TAG+="uaccess"
++# D&M Holdings, Inc. (Denon/Marantz)
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="154e", TAG+="uaccess"
++# EKS (Otus)
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="1157", TAG+="uaccess"
++# Gemini
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="23c7", TAG+="uaccess"
++# Guillemot Corp. (Hercules)
+ SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="06f8", TAG+="uaccess"
+-# Pioneer
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="08e4", TAG+="uaccess"
+-# Numark (may be needed for NS7 & V7)
++# inMusic (Numark, Denon)
+ SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="15e4", TAG+="uaccess"
+-# Eks
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="1157", TAG+="uaccess"
+-# Nintendo
++# KORG, Inc.
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="0944", TAG+="uaccess"
++# Native Instruments
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="17cc", TAG+="uaccess"
++# Nintendo Co., Ltd
+ SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="057e", TAG+="uaccess"
+-# Sony
++# Pioneer Corp.
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="08e4", TAG+="uaccess"
++# Rane
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="13e5", TAG+="uaccess"
++# Reloop
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="200c", TAG+="uaccess"
++# Roland Corp.
++SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="0582", TAG+="uaccess"
++# Sony Corp.
+ SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="054c", TAG+="uaccess"
+-# Gemini
+-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",
ATTRS{idVendor}=="23c7", TAG+="uaccess"
++
++# Missing:
++# - American Musical Supply (AMS/Mixars)
+
+ # Only some distribuions require the below
+ KERNEL=="hiddev*", NAME="usb/%k", GROUP="uaccess"
+--
+2.25.1