fsphil / hacktv

Analogue TV transmitter for the HackRF
GNU General Public License v3.0
732 stars 86 forks source link

Linux mint "make" is giving me errors #114

Closed t0nitogp closed 4 months ago

t0nitogp commented 4 months ago

I'm trying to build hackTV and I ran into an issue, I installed the requirements

apt-get install libhackrf-dev libavutil-dev libavdevice-dev libswresample-dev libswscale-dev libavformat-dev libavcodec-dev

When I go to "make" command it starts running and stops at:

/usr/bin/ld: rf_hack.o: in function 'rf_hackrf_open': /home/mint/hacktv/src/rf_hackrf.c:365: undefined reference to 'hackrf_get_transfer_buffer_size' /usr/bin/ld: /home/mint/hacktv/src/rf_hackrf.c:367: undefined reference to 'hackrf_get_transfer_buffer_size' collect2: error: ld returned 1 exit status make: *** [Makefile:36: hacktv] Error 1

t0nitogp commented 4 months ago

IMG_20240703_133029

fsphil commented 4 months ago

This is a duplicate of #106

Basically your system is still using a very old version of libhackrf that lacks the hackrf_get_transfer_buffer_size() function. You can simply replace that function call with 262144.

I might just remove this call until Ubuntu and Mint fix their packages.

t0nitogp commented 4 months ago

You mean edit the rf_hackrf.c and replace on both lines 'hackrf_get_transfer_buffer_size()' with 262144?

I'm sorry if this is a stupid question but I'm very new to Linux, I'm using the latest version of Mint, is there a way to maybe update a newer version of libhackrf and try again?

t0nitogp commented 4 months ago

This is a duplicate of #106

Basically your system is still using a very old version of libhackrf that lacks the hackrf_get_transfer_buffer_size() function. You can simply replace that function call with 262144.

I might just remove this call until Ubuntu and Mint fix their packages.

I tried replacing hackrf_get_transfer_buffer_size() with 262144 and just got more errors. I know nothing about code...

fsphil commented 4 months ago

I've pushed a change that removes that function call, that should compile for you.

t0nitogp commented 4 months ago

Thank you!

fsphil commented 4 months ago

Did it work?

t0nitogp commented 4 months ago

I didn't have a chance to it try yet, but as soon as I do I'll let you know :)

t0nitogp commented 4 months ago

Did it work?

Yes, perfectly! Thank you so much!

fsphil commented 4 months ago

Thanks for reporting back!