mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-01-09 00:10:21 +03:00
sys-apps/usb_modeswitch: fix build w/ C23
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
23
sys-apps/usb_modeswitch/files/c23.patch
Normal file
23
sys-apps/usb_modeswitch/files/c23.patch
Normal file
@@ -0,0 +1,23 @@
|
||||
get_current_config_value doesn't take any arguments, dev is a global variable.
|
||||
|
||||
Bug: https://bugs.gentoo.org/944427
|
||||
--- a/usb_modeswitch.c
|
||||
+++ b/usb_modeswitch.c
|
||||
@@ -570,7 +570,7 @@ int main(int argc, char **argv)
|
||||
/* Get current configuration of default device, note value if Configuration
|
||||
* parameter is set. Also sets active_config
|
||||
*/
|
||||
- currentConfigVal = get_current_config_value(dev);
|
||||
+ currentConfigVal = get_current_config_value();
|
||||
if (Configuration > -1) {
|
||||
SHOW_PROGRESS(output,"Current configuration number is %d\n", currentConfigVal);
|
||||
} else
|
||||
@@ -772,7 +772,7 @@ int main(int argc, char **argv)
|
||||
if (Configuration > 0) {
|
||||
if (currentConfigVal != Configuration) {
|
||||
if (switchConfiguration()) {
|
||||
- currentConfigVal = get_current_config_value(dev);
|
||||
+ currentConfigVal = get_current_config_value();
|
||||
if (currentConfigVal == Configuration) {
|
||||
SHOW_PROGRESS(output,"The configuration was set successfully\n");
|
||||
} else {
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 1999-2022 Gentoo Authors
|
||||
# Copyright 1999-2025 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
@@ -30,7 +30,10 @@ BDEPEND="virtual/pkgconfig"
|
||||
|
||||
CONFIG_CHECK="~USB_SERIAL"
|
||||
|
||||
PATCHES=( "${FILESDIR}/usb_modeswitch.sh-tmpdir.patch" )
|
||||
PATCHES=(
|
||||
"${FILESDIR}/usb_modeswitch.sh-tmpdir.patch"
|
||||
"${FILESDIR}/c23.patch"
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
default
|
||||
Reference in New Issue
Block a user