Skip to content

brew install pothosware/pothos/airspyhf fails on M2 macs (depends on /usr/local) #65

@dl1ycf

Description

@dl1ycf

There seems to be a hard-coded assumption that include files are in /usr/local:

==> Reinstalling pothosware/pothos/soapyairspyhf
==> Installing dependencies for pothosware/pothos/soapyairspyhf: pothosware/pothos/airspyhf
==> Installing pothosware/pothos/soapyairspyhf dependency: pothosware/pothos/airspyhf
==> cmake .. -DLIBUSB_INCLUDE_DIR=/usr/local/include/libusb-1.0
==> make install
Last 15 lines from /Users/chwu/Library/Logs/Homebrew/airspyhf/02.make:
34 | #include <libusb.h>
| ^~~~~~~~~~
/tmp/airspyhf-20250304-47013-nbje2a/airspyhf-1.0/libairspyhf/src/airspyhf.c:34:10: fatal error: 'libusb.h' file not found
34 | #include <libusb.h>
| ^~~~~~~~~~
1 error generated.

but on M2 macs, the LIBUSB_INCLUDE_DIR is /opt/homebrew/include/libusb-1.0,
if $CPATH exists one should uses $CPATH/libusb-1.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions