OpenRTX / dmrconfig

Configuration utility for DMR radios
BSD 3-Clause "New" or "Revised" License
240 stars 56 forks source link

Release 1.1 compiles on OSX, but the current code from the repository does not. #32

Closed meleschi closed 3 years ago

meleschi commented 5 years ago

I get the following error when attempting to compile the most recent version of dmrconfig. I do get a successful compile when I use version 1.1 code however. Just wanted to let you know. =)

I am on 10.14.5 BTW.

laptop-01:dmrconfig meleschi$ make make: pkg-config: Command not found gcc -g -O -Wall -Werror -DVERSION='"1.1.218"' -c -o main.o main.c make: pkg-config: Command not found gcc -g -O -Wall -Werror -DVERSION='"1.1.218"' -c -o util.o util.c make: pkg-config: Command not found gcc -g -O -Wall -Werror -DVERSION='"1.1.218"' -c -o radio.o radio.c make: pkg-config: Command not found gcc -g -O -Wall -Werror -DVERSION='"1.1.218"' -c -o dfu-libusb.o dfu-libusb.c dfu-libusb.c:32:10: fatal error: 'libusb.h' file not found

include

     ^~~~~~~~~~

1 error generated. make: *** [dfu-libusb.o] Error 1

sergev commented 5 years ago

Thank you for the bug report. Looks like I was too optimistic about using pkg-config on MacOS. Please try change 1af792bd8d3c4316a5b98e99f4b35758b5db1517.

meleschi commented 5 years ago

Slightly different error now:

dmrconfig$ make gcc -g -O -Wall -Werror -DVERSION='"1.1.219"' -c -o main.o main.c gcc -g -O -Wall -Werror -DVERSION='"1.1.219"' -c -o util.o util.c gcc -g -O -Wall -Werror -DVERSION='"1.1.219"' -c -o radio.o radio.c gcc -g -O -Wall -Werror -DVERSION='"1.1.219"' -c -o dfu-libusb.o dfu-libusb.c dfu-libusb.c:32:10: fatal error: 'libusb.h' file not found

include

     ^~~~~~~~~~

1 error generated. make: *** [dfu-libusb.o] Error 1

sergev commented 5 years ago

Would you mind to install pkg-config and libusb-1.0? Like this:

brew install pkg-config libusb

More details here: http://macappstore.org/pkg-config/

sergev commented 5 years ago

This version should build correctly with pkg-config installed: eb1417ebfaf4161193436784cba2827c36c1c707

meleschi commented 5 years ago

It worked!

BTW - I already had libusb installed, but I did install pkg-config per your recommendation.

sergev commented 5 years ago

Excellent! I've added a comment to Makefile about installing pkg-config on Mac.

f-izzo commented 3 years ago

This issue seems resolved.

I've also added the Mac OS build dependencies to the README.md