[SOLVED. Post #26] The piaware has been built WITHOUT fa-mlat-client due to cx_Freeze issue

Hi,

I’ve built piaware from source for my PC (amd64) and I’m getting this error.

The piaware has been built WITHOUT fa-mlat-client 
due to cx_Freeze issue.... 
MLAT will NOT be enabled ....

In the log I don’t see any issues or errors concerning cx_Freeze. What can I do?

The only thing you can do is to wait for Flightaware to update their source-code to be compatible with Bookworm. Once Flightaware updates their source code, you have to rebuild the piaware package and replace existing package with new package.

The warning message about fa-mlat-client appears because you have built piaware with following:

(1) On Debian 12 Bookworm or on Ubuntu 23
(2) Used following script at Github site https://github.com/abcd567a/piaware-ubuntu-debian-amd64

sudo bash -c "$(wget -O - https://raw.githubusercontent.com/abcd567a/piaware-ubuntu-debian-amd64/master/install-piaware.sh)"

The above script has following code which installs piaware without fa-mlat-client. The reason for doing this is that any attempt to build piaware on Bookworm in normal way (i.e. including fa-mlat-client) results in failure to build the piaware package.

elif [[ ${OS_VERSION} == bookworm ]]; then
  sudo bash -c "$(wget -O - https://github.com/abcd567a/temp/raw/main/install-piaware-debian-12.sh)"
  exit 0

 

In file https://github.com/abcd567a/temp/raw/main/install-piaware-debian-12.sh

cd ${INSTALL_DIRECTORY}/piaware_builder/package-${OS_VERSION}

sudo sed -i 's/python3-dev(>=3.9)/python3-dev/' debian/control
sudo sed -i 's/tcl-tls (>= 1.7.22-2)/tcl-tls/' debian/control

sudo sed -i  's/include <eval.h>/include <ceval.h>/' cx_Freeze-6.8.3/source/bases/Common.c

sudo sed -i  's/ clean_mlat-client / /' debian/rules
sudo sed -i  's/ build_mlat-client / /' debian/rules
sudo sed -i  's/ install_mlat-client / /' debian/rules
sudo sed -i '/cd mlat-client/s/^/#/' piaware_builder/package-bullseye/debian/rules
sudo sed -i '/fa-mlat-client/s/^/#/' debian/rules
sudo sed -i '/freeze-mlat-client/s/^/#/' piaware_builder/package-bullseye/debian/rules

sudo dpkg-buildpackage -b --no-sign 
....
....
....

echo -e "\e[1;35mThe piaware has been built WITHOUT fa-mlat-client \e[39m"
echo -e "\e[1;35mdue to cx_Freeze issue.... \e[39m"
echo -e "\e[1;31mMLAT will NOT be enabled .... \e[39m"



1 Like

Since even without mlat enabled, you can still feed data to flightaware, better continue running piaware without mlat till Flightaware makes its source code compatible to Bookworm, then reinstall piaware built from updated source code.

However if you are too keen to enable mlat, then instead of using piaware source-code from Fllightaware, use piaware source code from https://github.com/WhoAmI0501/piaware_builder. This source-code is forked from Flightaware, but it is modified to build piaware on Bookworm with fa-mlat-client.

To build piaware from above noted mlat-enabled source-code, do following:

sudo apt install python3-pip   
sudo apt install cmake   

sudo apt install devscripts 
sudo apt install build-essential

sudo apt install debhelper
sudo apt install tcl8.6-dev

sudo apt install autoconf
sudo apt install python3-dev

sudo apt install python3-venv
sudo apt install libz-dev 

sudo apt install zlib1g-dev

 

git clone  https://github.com/WhoAmI0501/piaware_builder   

cd piaware_builder   

sudo ./sensible-build.sh bookworm    

cd package-bookworm 

sudo dpkg-buildpackage -b --no-sign 

cd ../  

sudo dpkg -i piaware_*.deb

 

Thanks. That does also fail:

e3b3fa8 (grafted, HEAD, tag: v8.2) No change release for 8.2
Retrieving v0.2.13 from https://github.com/mutability/mlat-client.git
Cloning into './package-bookworm/mlat-client'...
warning: Could not find remote branch v0.2.13 to clone.
fatal: Remote branch v0.2.13 not found in upstream origin

I got the mlat-client from adsbexchange to work. Can I use it for piaware?

This is because of an error in file sensible-build.sh of WhoAmI0501 fork of piaware_builder.

The mlat-client version v0.2.13 does not exist.
The correct version is v0.2.12

Below I have added a sed command to correct this error

OK do following

First install following dependencies in addition to the ones mentioned in my previous post


sudo apt install libboost-system-dev 

sudo apt install libboost-program-options-dev 
sudo apt install libboost-regex-dev 

sudo apt install libboost-filesystem-dev 
sudo apt install patchelf 

sudo apt install net-tools 

sudo apt install itcl3 
sudo apt install tcl 
sudo apt install tcl-tls 

sudo apt install tcllib 
sudo apt install tclx8.4

 

Next delete the existing cloned source-code folder piaware_builder, clone fresh copy of source-code piaware_builder, correct the mlat-client ver mistake by sed command, and build & install piaware package

sudo rm -rf piaware_builder

git clone  https://github.com/WhoAmI0501/piaware_builder   

cd piaware_builder 

sudo sed -i 's/mlat-client.git v0.2.13/mlat-client.git v0.2.12/' sensible-build.sh 

sudo ./sensible-build.sh bookworm    

cd package-bookworm 

sudo dpkg-buildpackage -b --no-sign 

cd ../  

sudo dpkg -i piaware_8.2_*.deb  

 

Thank you. That does also not work:
mlat-client(1994672): ImportError: /usr/lib/piaware/helpers/lib/_modes.cpython-311-x86_64-linux-gnu.so: undefined symbol: _PyFloat_Unpack4

The name of the symbol is now PyFloat_Unpack4.

I think i’ll just leave it until it is fixed upstream.

Just remove the cloned directory & defective piaware from WhoAmI0501, and run the script from my Github site (which you originally ran to build piaware without fa-mlat-client). It will feed Flightaware successfully and smoothly without any trouble The only thing missing will be mlat, which for me is acceptable as number of mlat planes in my area are less than 10% of planes with positions. Also this is a temporary handicap, and I expect the Bookworm compatible version of Flightaware code will be soon available.

First remove whatever you have installed from WhoAmI0501 site

sudo rm -rf piaware_builder   

sudo dpkg --purge piaware  

 

Next run following bash script to install piaware without fa-mlat-client

sudo bash -c "$(wget -O - https://raw.githubusercontent.com/abcd567a/piaware-ubuntu-debian-amd64/master/install-piaware.sh)"

 

Last configure piaware

sudo piaware-config feeder-id xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx 
sudo piaware-config allow-manual-updates yes 
sudo piaware-config allow-auto-updates yes 
sudo systemctl restart piaware 

Click on screenshot to see larger size

 

2 Likes

Yes, v0.2.13 was apparently deleted a while ago, but not to worry: alternatively, you can manually change the line of sensible-build.sh from

shallow_clone https://github.com/mutability/mlat-client.git v0.2.13 "$OUTDIR/mlat-client"

to

shallow_clone https://github.com/wiedehopf/mlat-client.git master "$OUTDIR/mlat-client"

and everything should work again incl. MLAT – at least, it does over here…

3 Likes

That works, thank you.
3 green :grinning:
image

2 Likes

 

 

Did the above hack, piaware package was built sucessfully, installed it
Mlat enabled, showing 3 Green, but NOT synchronized with any nearby receivers even after running for 25 minutes. :disappointed:

 

 

 

image

 

Click on Screenshot to see larger size

I’m sorry to hear that, works like a charm over here:
MLAT1

Mine is also synchronized and tracking aircraft.
“Multilateration (MLAT): Supported / Enabled (synchronized with 196 nearby receivers)”

What are those two errors of missing files or directories with your setup?

Not clear, no detail mentioned except “Error: 2 (no such file or directory)”

When I rebooted the computer, this error disappeared. :slightly_smiling_face:
However “not synchronized with any nearby receivers” persists even 35 minutes after reboot.
Please see screenshot below.

Click on Screenshot to See Larger Size

 

@byraspi
@heliosh

Just now I tried to install Adsbexchange feeder on Debian12 Bookworm AMD64 (same computer as in my posts above). The Adsbexchange mlat service failed with following error messages:

undefined symbol:_PyFloat_Unpack4

 

FULL ERROR MESSAGE:

92
94
96
---------------------------------
Sep 10 07:36:53 debian12 adsbexchange-mlat[3582]:     self.require(requires)[0].run_script(script_name, ns)
Sep 10 07:36:53 debian12 adsbexchange-mlat[3582]:   File "/usr/local/share/adsbexchange/venv/lib/python3.11/site-packages/pkg_resources/__init__.py", line 1517, in run_script
Sep 10 07:36:53 debian12 adsbexchange-mlat[3582]:     exec(code, namespace, namespace)
Sep 10 07:36:53 debian12 adsbexchange-mlat[3582]:   File "/usr/local/share/adsbexchange/venv/lib/python3.11/site-packages/MlatClient-0.4.2-py3.11-linux-x86_64.egg/EGG-INFO/scripts/mlat-client", line 26, in <module>
Sep 10 07:36:53 debian12 adsbexchange-mlat[3582]:     from mlat.client.receiver import ReceiverConnection
Sep 10 07:36:53 debian12 adsbexchange-mlat[3582]:   File "/usr/local/share/adsbexchange/venv/lib/python3.11/site-packages/MlatClient-0.4.2-py3.11-linux-x86_64.egg/mlat/client/receiver.py", line 26, in <module>
Sep 10 07:36:53 debian12 adsbexchange-mlat[3582]:     import _modes
Sep 10 07:36:53 debian12 adsbexchange-mlat[3582]: ImportError: /usr/local/share/adsbexchange/venv/lib/python3.11/site-packages/MlatClient-0.4.2-py3.11-linux-x86_64.egg/_modes.cpython-311-x86_64-linux-gnu.so: undefined symbol:_PyFloat_Unpack4
Sep 10 07:36:53 debian12 systemd[1]: adsbexchange-mlat.service: Main process exited, code=exited, status=1/FAILURE
Sep 10 07:36:53 debian12 systemd[1]: adsbexchange-mlat.service: Failed with result 'exit-code'.
---------------------------------
adsbexchange-mlat service couldn't be started, please report this error to the adsbexchange forum or discord.
Try an copy as much of the output above and include it in your report, thank you!
---------------------------------

 

Hmm, that’s probably a very stupid question, so my apologies in advance: on the Pi, you did install the new ~/piaware_builder/package-bookworm/dump1090-fa_8.2_arm64.deb ? – I don’t know nothing about amd64…

P.S.: And I don’t use ADSBexchange anymore…

Yes, the adsbexchange feeder is using the mutability mlat-client, which is currently incompatible with debian bookworm.

Have you set the receiver coordinates correctly? Mine were set to a wrong location and it didn’t synchronize at first.

The location is the very first thing I checked when I found “Not Synchronized with nearby receivers”. I found the location (Lat/Lon). were already set correctly in “My ADS-B”, and were accurate upto 4 places of decimal. Same Lat/Lon I have set on other Bullseye receivers, and mlat synchronizes on all of these.

@byraspi
@heliosh

SUCCESS ON RPi - Synchronized with nearby receivers
(Dont know why failed to synchronize on AMD64 Computer)

(1) Wrote following image to a spare microSD card

image

(2) Slipped into RPi Model 4 and booted. ran sudo raspi-config and set Language & Time Zone.

(3) Did following to upgrade Bullseye to Bookworm:

(3.1) Replaced all occurrences ofbullseye by bookworm in files /etc/apt/sources.list & /etc/apt/sources.list.d/raspi.list by following sed commands. (Alternatively, this can be done by editing these files manually). After replacing bullseye by bookworm, updated apt.

sudo sed -i -e 's/bullseye/bookworm/g' /etc/apt/sources.list
sudo sed -i -e 's/bullseye/bookworm/g' /etc/apt/sources.list.d/raspi.list
sudo apt update

(3.2) Upgraded OS to Bookworm by folloing commands

sudo apt update

## the full-upgrade command below will take a long time
## It will installs about 450 new packages to replace old ones
## in-between it will ask questions 3 or 4 times, answer all by y (yes)

sudo apt -y full-upgrade   

sudo apt -y autoremove
sudo apt -y clean
sudo reboot

# remove old config files
sudo apt purge ?config-files

(4) As a result of above upgrade, got following OS

Click on Screenshot to See Larger Size

 

(5) Installed dump1090-fa by following command

sudo bash -c "$(wget -O - https://raw.githubusercontent.com/abcd567a/piaware-ubuntu-debian-amd64/master/install-dump1090-fa.sh)"
 

(6) Installed piaware by following method

(6.1) Installed build tools & dependencies

sudo apt install -y python3-pip  
sudo apt install -y cmake  

sudo apt install -y devscripts  
sudo apt install -y build-essential  

sudo apt install -y debhelper  
sudo apt install net-tools 

sudo apt install -y tcl8.6-dev  
sudo apt install -y autoconf  

sudo apt install -y python3-dev  
sudo apt install -y python3-venv  

sudo apt install -y libz-dev  
sudo apt install -y zlib1g-dev  
sudo apt install -y libboost-system-dev  
sudo apt install -y libboost-program-options-dev  

sudo apt install -y libboost-regex-dev  
sudo apt install -y libboost-filesystem-dev  

sudo apt install -y patchelf  

sudo apt install -y itcl3
sudo apt install -y tcl

sudo apt install -y tcl-tls
sudo apt install -y tcllib

sudo apt install -y tclx8.4  

(6.2) Cloned piaware_builder source-code from WhoAMI Github repository, changed in file sensible-build.sh, the mlat-client source from mutability to wiedehopf, and build and installed the piaware

git clone  https://github.com/WhoAmI0501/piaware_builder   

cd piaware_builder 

sudo sed -i 's/mutability\/mlat-client.git v0.2.13/wiedehopf\/mlat-client.git master/' sensible-build.sh

sudo ./sensible-build.sh bookworm    

cd package-bookworm 

sudo dpkg-buildpackage -b --no-sign 

cd ../  

sudo dpkg -i piaware_8.2_*.deb

 

(7) SUCCESS

Click on Screenshot to See Large Size

 

2 Likes