Opened 2 years ago

Last modified 2 years ago

#64408 reopened defect

libusb @1.0.24_0: error: too many #pragma options align=reset

Reported by: udbraumann Owned by:
Priority: Normal Milestone:
Component: ports Version:
Keywords: leopard powerpc Cc: michaelld (Michael Dickens), evanmiller (Evan Miller), barracuda156
Port: libusb

Description

While upgrading libusb from 1.0.23_0 to 1.0.24_0 building stops with three occurrences of the error too many #pragma options align=reset inside /System/Library/Frameworks/IOKit.framework/Headers/usb/USB.h

...
:info:build libtool: compile:  /opt/local/bin/gcc-mp-7 -DHAVE_CONFIG_H -I. -I.. -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
:info:build In file included from /System/Library/Frameworks/IOKit.framework/Headers/usb/IOUSBLib.h:27:0,
:info:build                  from os/darwin_usb.h:30,
:info:build                  from os/darwin_usb.c:49:
:info:build /System/Library/Frameworks/IOKit.framework/Headers/usb/USB.h:594:9: error: too many #pragma options align=reset
:info:build  #pragma options align=reset
:info:build          ^~~~~~~
:info:build /System/Library/Frameworks/IOKit.framework/Headers/usb/USB.h:612:9: error: too many #pragma options align=reset
:info:build  #pragma options align=reset
:info:build          ^~~~~~~
:info:build /System/Library/Frameworks/IOKit.framework/Headers/usb/USB.h:632:9: error: too many #pragma options align=reset
:info:build  #pragma options align=reset
:info:build          ^~~~~~~
...

How could this get fixed?

Attachments (1)

main.log.gz (5.3 KB) - added by udbraumann 2 years ago.

Download all attachments as: .zip

Change History (10)

Changed 2 years ago by udbraumann

Attachment: main.log.gz added

comment:1 Changed 2 years ago by ryandesign (Ryan Carsten Schmidt)

comment:2 Changed 2 years ago by evanmiller (Evan Miller)

Try installing legacy-support-devel and libusb-devel. For a full discussion see #61868

Last edited 2 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:3 Changed 2 years ago by evanmiller (Evan Miller)

Cc: evanmiller added

comment:4 Changed 2 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: michaelld barracuda156 added; michaelld@… removed
Keywords: powerpc added
Summary: libusb @1.0.24_0 fails building on 10.5.8 PPClibusb @1.0.24_0: error: too many #pragma options align=reset

Has duplicate #64544.

comment:5 Changed 2 years ago by barracuda156

Since v. 1.0.23 builds on ppc with no issues, maybe we can default it for ppc systems, until pragma bug is fixed? A number of ports report themselves as incompatible with ppc arch simply due to libusb now. Once earlier version of libusb is installed, they build with no complains.

For the reference of others, I talk about this version: https://github.com/macports/macports-ports/tree/15d61f029417bbc8b37f31a2f4833ee6d57f0359/devel/libusb

comment:6 Changed 2 years ago by kencu (Ken)

I presume you tried https://trac.macports.org/ticket/64408#comment:2 and it didn’t work for you?

comment:7 in reply to:  6 Changed 2 years ago by barracuda156

Replying to kencu:

I presume you tried https://trac.macports.org/ticket/64408#comment:2 and it didn’t work for you?

I used a patch copied from elsewhere - and turned out I made a silly error while copying it. Thanks to your comment I reran compilation and reviewed what patch was doing, and realized what's wrong. I never noticed that because it applied successfully. Thank you. I did not need devel versions, it compiled now:

36-47:~ svacchanda$ port -v installed libusb
The following ports are currently installed:
  libusb @1.0.23_0+universal requested_variants='+universal' platform='darwin 9' archs='ppc ppc64' date='2022-02-13T13:28:21+0800'
  libusb @1.0.25_0 (active) requested_variants='' platform='darwin 9' archs='ppc' date='2022-02-13T17:25:45+0800'

comment:8 Changed 2 years ago by kencu (Ken)

Resolution: invalid
Status: newclosed

thanks.

comment:9 Changed 2 years ago by kencu (Ken)

Resolution: invalid
Status: closedreopened

whoops, sorry, I missed that this was an older ticket there for a sec

Note: See TracTickets for help on using tickets.