Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ppup1090 Fails to compile on RaspberryPiOS Bullseye #1

Open
abcd567a opened this issue Dec 22, 2022 · 8 comments
Open

ppup1090 Fails to compile on RaspberryPiOS Bullseye #1

abcd567a opened this issue Dec 22, 2022 · 8 comments

Comments

@abcd567a
Copy link

pi@piaware:~/ppup1090 $ make

gcc -g -o ppup1090 ppup1090.o anet.o interactive.o mode_ac.o mode_s.o coaa1090.obj -lpthread -lm
/usr/bin/ld: interactive.o:/home/pi/ppup1090/ppup1090.h:282: multiple definition of coaa1090'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:282: first defined here /usr/bin/ld: interactive.o:/home/pi/ppup1090/ppup1090.h:272: multiple definition of ppup1090'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:272: first defined here
/usr/bin/ld: interactive.o:/home/pi/ppup1090/ppup1090.h:225: multiple definition of Modes'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:225: first defined here /usr/bin/ld: interactive.o:/home/pi/ppup1090/ppup1090.h:187: multiple definition of tDF'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:187: first defined here
/usr/bin/ld: mode_ac.o:/home/pi/ppup1090/ppup1090.h:282: multiple definition of coaa1090'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:282: first defined here /usr/bin/ld: mode_ac.o:/home/pi/ppup1090/ppup1090.h:272: multiple definition of ppup1090'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:272: first defined here
/usr/bin/ld: mode_ac.o:/home/pi/ppup1090/ppup1090.h:225: multiple definition of Modes'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:225: first defined here /usr/bin/ld: mode_ac.o:/home/pi/ppup1090/ppup1090.h:187: multiple definition of tDF'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:187: first defined here
/usr/bin/ld: mode_s.o:/home/pi/ppup1090/ppup1090.h:282: multiple definition of coaa1090'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:282: first defined here /usr/bin/ld: mode_s.o:/home/pi/ppup1090/ppup1090.h:272: multiple definition of ppup1090'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:272: first defined here
/usr/bin/ld: mode_s.o:/home/pi/ppup1090/ppup1090.h:225: multiple definition of Modes'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:225: first defined here /usr/bin/ld: mode_s.o:/home/pi/ppup1090/ppup1090.h:187: multiple definition of tDF'; ppup1090.o:/home/pi/ppup1090/ppup1090.h:187: first defined here
collect2: error: ld returned 1 exit status
make: *** [Makefile:23: ppup1090] Error 1

@MM0URH
Copy link

MM0URH commented Mar 13, 2023

Hi @abcd567a,

Were you able to get a resolution to this issue? I have the same running Flightaware on a Pi3B+, Flightaware and Plane Finder are both running OK

@abcd567a
Copy link
Author

Hi @abcd567a,

Were you able to get a resolution to this issue? I have the same running Flightaware on a Pi3B+, Flightaware and Plane Finder are both running OK

No resolutiin yet

@OK1SLM
Copy link

OK1SLM commented Apr 15, 2023

Still no solution?

@rikgale
Copy link

rikgale commented Nov 25, 2023

I am having a similar problem on Bookworm

make -f makeppup1090
gcc -O2 -g -Wall -W `pkg-config --cflags librtlsdr`  -c ppup1090.c
gcc -O2 -g -Wall -W `pkg-config --cflags librtlsdr`  -c anet.c
gcc -O2 -g -Wall -W `pkg-config --cflags librtlsdr`  -c interactive.c
interactive.c: In function ‘interactiveShowData’:
interactive.c:485:44: warning: ‘%03d’ directive output may be truncated writing between 3 and 9 bytes into a region of size 5 [-Wformat-truncation=]
  485 |                         snprintf(strFl,6,"F%03d",(altitude/100));
      |                                            ^~~~
interactive.c:485:42: note: directive argument in the range [-21474836, 21474836]
  485 |                         snprintf(strFl,6,"F%03d",(altitude/100));
      |                                          ^~~~~~~
interactive.c:485:25: note: ‘snprintf’ output between 5 and 11 bytes into a destination of size 6
  485 |                         snprintf(strFl,6,"F%03d",(altitude/100));
      |                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
gcc -O2 -g -Wall -W `pkg-config --cflags librtlsdr`  -c mode_ac.c
gcc -O2 -g -Wall -W `pkg-config --cflags librtlsdr`  -c mode_s.c
gcc -O2 -g -Wall -W `pkg-config --cflags librtlsdr`  -c net_io.c
net_io.c: In function ‘modesSendSBSOutput’:
net_io.c:351:5: warning: ‘ftime’ is deprecated: Use gettimeofday or clock_gettime instead [-Wdeprecated-declarations]
  351 |     ftime(&epocTime_now);                                         // get the current system time & date
      |     ^~~~~
In file included from dump1090.h:54,
                 from net_io.c:31:
/usr/include/aarch64-linux-gnu/sys/timeb.h:29:12: note: declared here
   29 | extern int ftime (struct timeb *__timebuf)
      |            ^~~~~
gcc -g -o ppup1090 ppup1090.o anet.o interactive.o mode_ac.o mode_s.o net_io.o coaa1090.obj `pkg-config --libs librtlsdr` -lpthread -lm
/usr/bin/ld: interactive.o:/home/pi/ppup/dump1090.h:373: multiple definition of `Modes'; ppup1090.o:/home/pi/ppup/dump1090.h:373: first defined here
/usr/bin/ld: interactive.o:/home/pi/ppup/dump1090.h:238: multiple definition of `tDF'; ppup1090.o:/home/pi/ppup/dump1090.h:238: first defined here
/usr/bin/ld: mode_ac.o:/home/pi/ppup/dump1090.h:373: multiple definition of `Modes'; ppup1090.o:/home/pi/ppup/dump1090.h:373: first defined here
/usr/bin/ld: mode_ac.o:/home/pi/ppup/dump1090.h:238: multiple definition of `tDF'; ppup1090.o:/home/pi/ppup/dump1090.h:238: first defined here
/usr/bin/ld: mode_s.o:/home/pi/ppup/dump1090.h:373: multiple definition of `Modes'; ppup1090.o:/home/pi/ppup/dump1090.h:373: first defined here
/usr/bin/ld: mode_s.o:/home/pi/ppup/dump1090.h:238: multiple definition of `tDF'; ppup1090.o:/home/pi/ppup/dump1090.h:238: first defined here
/usr/bin/ld: net_io.o:/home/pi/ppup/dump1090.h:373: multiple definition of `Modes'; ppup1090.o:/home/pi/ppup/dump1090.h:373: first defined here
/usr/bin/ld: net_io.o:/home/pi/ppup/dump1090.h:238: multiple definition of `tDF'; ppup1090.o:/home/pi/ppup/dump1090.h:238: first defined here
/usr/bin/ld: coaa1090.obj: error adding symbols: file in wrong format
collect2: error: ld returned 1 exit status
make: *** [makeppup1090:24: ppup1090] Error 1

@Tomfr06
Copy link

Tomfr06 commented Jan 21, 2024

I believe this is because you (we) are now running a 64 bits OS...
When you make, everything is compiled ARM aarch64
But the final command tries to link it with the precompiled coaa1090.obj that is ARM "32 bits" binary.
I'm no expert but maybe one of the following could solve the issue:

  • Reinstall the Raspberry PI to run 32 bit (this is what I did in the past when I switch to a PI 4, I first tried first 64bits OS and got that issue, then reinstalled with 32 bit and could compile).
  • @MalcolmRobb provides an ARM aarch64 version of the coaa1090.obj in the repo.
  • Compile everything in 32 bits, probably on another PI running under a 32 OS... But I'm not sure if the resulting binary would then run under a 64 bit OS

@Elmer-Fudd
Copy link

I have just tried this on a fresh 32-bit Bullseye install (though I did install some other packages before attempting it) and got exactly the same errors. I can get other dump1090 distributions to install, but none have ppup1090 as far as I know, and that is the functionality I need.

@OK1SLM
Copy link

OK1SLM commented Jun 1, 2024

@abcd567a
Copy link
Author

abcd567a commented Nov 6, 2024

Script for automated installation of ppup1090
https://github.com/abcd567a/ppup1090/blob/master/README.md

The automated installation script on above site uses the set of pre-compiled executable binaries provided by PlanePlotter Group. You can download this set of pre-compiled binaries from here:
https://www.coaa.co.uk/ppup1090-2024-06-11.zip

The script given on above linked Github site installs PlanePlotter Uploader ppup1090 with Systemd on following:

Raspberry Pi 32-bit (armhf) & 64-bit (arm64) OS Buster, Bullseye, & Bookworm
Ubuntu 20, 22 & 24 amd64 / x86_64
Debian 11, 12 & 13 amd64 / x86_64

.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants