[MacPorts] #74242: libusb @1.0.30_0 uses kUSBProductString and kUSBSerialNumberString
MacPorts
noreply at macports.org
Fri Jul 31 14:54:02 UTC 2026
#74242: libusb @1.0.30_0 uses kUSBProductString and kUSBSerialNumberString
------------------------------+---------------------
Reporter: ForestExpertise | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.11.6
Resolution: | Keywords: leopard
Port: libusb |
------------------------------+---------------------
Comment (by ballapete):
The errors on `PPC Leopard` look like this:
{{{
depbase=`echo os/darwin_usb.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/sh ../libtool --tag=CC --mode=compile /opt/local/bin/gcc-
mp-15 -DHAVE_CONFIG_H -I. -I.. -isystem/opt/local/include/LegacySupport
-I/opt/local/include -std=gnu11 -Wall -Wextra -Wshadow -Wunused -Wwrite-
strings -Werror=format-security -Werror=implicit-function-declaration
-Werror=implicit-int -Werror=init-self -Werror=missing-prototypes -Werror
=strict-prototypes -Werror=undef -Werror=uninitialized -fvisibility=hidden
-pthread -pipe -Os -arch ppc -MT os/darwin_usb.lo -MD -MP -MF $depbase.Tpo
-c -o os/darwin_usb.lo os/darwin_usb.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile: /opt/local/bin/gcc-mp-15 -DHAVE_CONFIG_H -I. -I..
-isystem/opt/local/include/LegacySupport -I/opt/local/include -std=gnu11
-Wall -Wextra -Wshadow -Wunused -Wwrite-strings -Werror=format-security
-Werror=implicit-function-declaration -Werror=implicit-int -Werror=init-
self -Werror=missing-prototypes -Werror=strict-prototypes -Werror=undef
-Werror=uninitialized -fvisibility=hidden -pthread -pipe -Os -arch ppc -MT
os/darwin_usb.lo -MD -MP -MF os/.deps/darwin_usb.Tpo -c os/darwin_usb.c
-fno-common -DPIC -o os/.libs/darwin_usb.o
In file included from os/darwin_usb.h:26,
from os/darwin_usb.c:50:
os/darwin_usb.c: In function 'get_running_version':
os/darwin_usb.c:413:21: warning: too many arguments for format [-Wformat-
extra-args]
413 | usbi_err (NULL, "could not read kern.osrelease, errno=",
errno);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./libusbi.h:328:67: note: in definition of macro '_usbi_log'
328 | #define _usbi_log(ctx, level, ...) usbi_log(ctx, level, __func__,
__VA_ARGS__)
|
^~~~~~~~~~~
os/darwin_usb.c:413:5: note: in expansion of macro 'usbi_err'
413 | usbi_err (NULL, "could not read kern.osrelease, errno=",
errno);
| ^~~~~~~~
os/darwin_usb.c: In function 'darwin_devices_detached':
os/darwin_usb.c:684:27: warning: format '%x' expects argument of type
'unsigned int', but argument 6 has type 'UInt32' {aka 'long unsigned int'}
[-Wformat=]
684 | usbi_dbg (NULL, "detected device detached due to re-
enumeration. sessionID: 0x%" PRIx64
|
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
685 | ", locationID: 0x%" PRIx32, session,
locationID);
|
~~~~~~~~~~
| |
|
UInt32 {aka long unsigned int}
./libusbi.h:328:67: note: in definition of macro '_usbi_log'
328 | #define _usbi_log(ctx, level, ...) usbi_log(ctx, level, __func__,
__VA_ARGS__)
|
^~~~~~~~~~~
os/darwin_usb.c:684:11: note: in expansion of macro 'usbi_dbg'
684 | usbi_dbg (NULL, "detected device detached due to re-
enumeration. sessionID: 0x%" PRIx64
| ^~~~~~~~
In file included from
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFError.h:33,
from
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFBundle.h:11,
from
/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:43,
from
/opt/local/include/LegacySupport/CoreFoundation/CoreFoundation.h:27,
from
/System/Library/Frameworks/IOKit.framework/Headers/IOCFBundle.h:4,
from os/darwin_usb.h:29:
os/darwin_usb.c: In function 'darwin_get_device_string':
os/darwin_usb.c:995:59: error: expected ')' before 'kUSBVendorString'
995 | cf = IORegistryEntryCreateCFProperty(service,
CFSTR(kUSBVendorString), kCFAllocatorDefault, 0);
|
^~~~~~~~~~~~~~~~
os/darwin_usb.c:995:53: note: to match this '('
995 | cf = IORegistryEntryCreateCFProperty(service,
CFSTR(kUSBVendorString), kCFAllocatorDefault, 0);
| ^~~~~
os/darwin_usb.c:998:59: error: expected ')' before 'kUSBProductString'
998 | cf = IORegistryEntryCreateCFProperty(service,
CFSTR(kUSBProductString), kCFAllocatorDefault, 0);
|
^~~~~~~~~~~~~~~~~
os/darwin_usb.c:998:53: note: to match this '('
998 | cf = IORegistryEntryCreateCFProperty(service,
CFSTR(kUSBProductString), kCFAllocatorDefault, 0);
| ^~~~~
os/darwin_usb.c:1001:59: error: expected ')' before
'kUSBSerialNumberString'
1001 | cf = IORegistryEntryCreateCFProperty(service,
CFSTR(kUSBSerialNumberString), kCFAllocatorDefault, 0);
|
^~~~~~~~~~~~~~~~~~~~~~
os/darwin_usb.c:1001:53: note: to match this '('
1001 | cf = IORegistryEntryCreateCFProperty(service,
CFSTR(kUSBSerialNumberString), kCFAllocatorDefault, 0);
| ^~~~~
os/darwin_usb.c: In function 'darwin_get_cached_device':
os/darwin_usb.c:1382:21: warning: format '%x' expects argument of type
'unsigned int', but argument 6 has type 'UInt32' {aka 'long unsigned int'}
[-Wformat=]
1382 | usbi_dbg(ctx, "matching sessionID/locationID 0x%" PRIx64
"/0x%" PRIx32 " against cached device with sessionID/locationID 0x%"
PRIx64 "/0x%" PRIx32,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1383 | sessionID, locationID, new_device->session,
new_device->location);
| ~~~~~~~~~~
| |
| UInt32 {aka long unsigned int}
./libusbi.h:328:67: note: in definition of macro '_usbi_log'
328 | #define _usbi_log(ctx, level, ...) usbi_log(ctx, level, __func__,
__VA_ARGS__)
|
^~~~~~~~~~~
os/darwin_usb.c:1382:7: note: in expansion of macro 'usbi_dbg'
1382 | usbi_dbg(ctx, "matching sessionID/locationID 0x%" PRIx64
"/0x%" PRIx32 " against cached device with sessionID/locationID 0x%"
PRIx64 "/0x%" PRIx32,
| ^~~~~~~~
os/darwin_usb.c:1382:21: warning: format '%x' expects argument of type
'unsigned int', but argument 8 has type 'UInt32' {aka 'long unsigned int'}
[-Wformat=]
1382 | usbi_dbg(ctx, "matching sessionID/locationID 0x%" PRIx64
"/0x%" PRIx32 " against cached device with sessionID/locationID 0x%"
PRIx64 "/0x%" PRIx32,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1383 | sessionID, locationID, new_device->session,
new_device->location);
|
~~~~~~~~~~~~~~~~~~~~
|
|
|
UInt32 {aka long unsigned int}
./libusbi.h:328:67: note: in definition of macro '_usbi_log'
328 | #define _usbi_log(ctx, level, ...) usbi_log(ctx, level, __func__,
__VA_ARGS__)
|
^~~~~~~~~~~
os/darwin_usb.c:1382:7: note: in expansion of macro 'usbi_dbg'
1382 | usbi_dbg(ctx, "matching sessionID/locationID 0x%" PRIx64
"/0x%" PRIx32 " against cached device with sessionID/locationID 0x%"
PRIx64 "/0x%" PRIx32,
| ^~~~~~~~
os/darwin_usb.c: In function 'darwin_release_interface':
os/darwin_usb.c:1975:41: warning: format '%u' expects argument of type
'unsigned int', but argument 5 has type 'ULONG' {aka 'long unsigned int'}
[-Wformat=]
1975 | usbi_warn (HANDLE_CTX (dev_handle), "Release final refCount:
%u", refCount);
|
^~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~
|
|
|
ULONG {aka long unsigned int}
./libusbi.h:328:67: note: in definition of macro '_usbi_log'
328 | #define _usbi_log(ctx, level, ...) usbi_log(ctx, level, __func__,
__VA_ARGS__)
|
^~~~~~~~~~~
os/darwin_usb.c:1975:5: note: in expansion of macro 'usbi_warn'
1975 | usbi_warn (HANDLE_CTX (dev_handle), "Release final refCount:
%u", refCount);
| ^~~~~~~~~
os/darwin_usb.c:1975:67: note: format string is defined here
1975 | usbi_warn (HANDLE_CTX (dev_handle), "Release final refCount:
%u", refCount);
|
~^
|
|
|
unsigned int
|
%lu
os/darwin_usb.c: At top level:
os/darwin_usb.c:92:12: warning: 'darwin_detach_kernel_driver' declared
'static' but never defined [-Wunused-function]
92 | static int darwin_detach_kernel_driver (struct
libusb_device_handle *dev_handle, uint8_t interface);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
os/darwin_usb.c:247:17: warning: 'get_device_interface_version' defined
but not used [-Wunused-function]
247 | static uint32_t get_device_interface_version(void) {
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
make[2]: *** [os/darwin_usb.lo] Error 1
make[2]: Leaving directory `/opt/local/var/macports/build/libusb-
f2ed98df/work/libusb-1.0.30/libusb'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/opt/local/var/macports/build/libusb-
f2ed98df/work/libusb-1.0.30'
make: *** [all] Error 2
make: Leaving directory `/opt/local/var/macports/build/libusb-
f2ed98df/work/libusb-1.0.30'
Command failed: cd "/opt/local/var/macports/build/libusb-
f2ed98df/work/libusb-1.0.30" && /usr/bin/make -w all
AM_DEFAULT_VERBOSITY=1
Exit code: 2
}}}
--
Ticket URL: <https://trac.macports.org/ticket/74242#comment:4>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list