The instructions below show how to manually build. One industrious amateur radio operator, Dave Slotter, W3DJS, created a script that users may download and run under the BASH shell on Ubuntu and Raspberry Pi OS to automatically build or update the Fldigi suite of applications. The script may be found here: https://github.com/dslotter/ham_radio_scripts/blob/main/update_fldigi_suite
On Debian, Ubuntu, Linux Mint and Raspbian/RPi3 it is easiest to install the build dependencies for fldigi using the apt-get build-dep command. To do this, the source code repositories must be enabled.
Edit the file /etc/apt/sources.list using the text editor nano in a terminal window. This is a system file so you must execute commands as root.
First, make a backup copy of the file:
$ sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak
Now edit the file:
$ sudo nano /etc/apt/sources.list
Uncomment the lines which start with deb-src by deleting the leading ''# " characters.
Save the changes with control-O, then exit //nano// with control-X. Note: if there is no "deb-src" line in your sources.list file then continue on through the wiki and enable the source repositories as described below for Linux Mint.
For those that don't have the aptitude package installed, especially those on a Raspberry Pi, it needs to be installed before proceeding to be sure of resolving the build dependencies. It's recommended you accept the recommended conflict resolution offered unless you have a good reason not to.
$ sudo apt-get install aptitude
Next, update the apt package cache:
$ sudo aptitude update
Note: Linux Mint 21.02 has broken aptitude so if the above update for aptitude comes back with errors
then use apt-get. Apt-get should be already installed in all linux distros, but you will need to do
the update as above, as well as replacing any reference to aptitude with apt-get further down this page.
Choose Administration->Software Sources from the main menu to open the Software Sources program.
Check Enable source code repositories. Next, update the apt cache:
Choose System->Software Sources from the main menu to open the Software Sources program
Close the Software Sources program.
$ sudo aptitude install build-essential
Note: If building on Pi OS Bullseye the above will ask to delete one existing package. It's best to answer No.
$ sudo aptitude build-dep fldigi
Note: If building on Pi OS Bullseye the above will fail, at least at this time, with a missing package.
To get around that issue do:
sudo apt-get update
sudo apt-get build-dep fldigi
Once the missing package that aptitude complains about is available then the work around will no longer be needed.
Aptitude will assist you in resolving any library version conflicts. This may occur on some Debian/Ubuntu/Mint recent distributions.
Portaudio development headers / libs may conflict on a system with Jack pre-installed. Portaudio is required for fldigi to compile, so do not accept a recommendation that does not include installing the portaudio library. Aptitude will offer suggested solutions to resolve the conflict (including doing nothing).
Make sure that build-dep has installed libxft-dev. Test by looking for the Xft.h header.
On Ubuntu/Mint/Pi3/Pi4: /usr/include/X11/Xft/Xft.h
If it does not exist you can install libxft-dev manually:
$ sudo aptitude install libxft-dev
If you get an error about libudev-dev not installed you will need to install it manually as well.
$ sudo aptitude install libudev-dev
Compiling fldigi requires more than the default swap space. You may need to increase the swap space on the microSD card. Please follow the example instructions at Pi Swap Space and use the number 2048 instead of 1024 to give 2 GB of swap. Some users have needed the larger swap space.
You are now ready to build fldigi.
Download the latest source tarball (tar.gz) to your /home directory from here:
* download directory at W1HKJ web site
If you want to be on the bleeding edge you can download from the alpha page
https://www.w1hkj.org/alpha/fldigi/
Note:
https://www.w1hkj.org/files/
https://www.w1hkj.org/alpha/
will allow access to all of the applications developed and supported by W1HKJ & associates, both distribution and alpha versions.
The source tarball contains all the files needed to compile fldigi.
Open your file manager and locate the downloaded tarball. Right-click the file and select Extract Here. Scroll up to the unpacked tarball directory, right-click and select Open In Terminal.
Alternate procedure from a terminal, including creating a development directory in the user home directory:
$ cd ~
$ mkdir dev
$ cd dev
$ wget https://www.w1hkj.org/files/fldigi/fldigi-x.xx.xx.tar.gz
$ tar xf fldigi-x.xx.xx.tar.gz
$ cd fldigi-x.xx.xx
where 'x.xx.xx' is the version number of the most recently posted source archive.
At this point you will have a source tree extracted from the tarball containing a configure script. Now you need to prepare the source for compilation with the configure command. This generates the Makefiles that make uses to run the compiler and linker. configure has various options to fine-tune the build.
Do not include the ''--enable-optimizations=native'' option if building on Pi.
On the RPi3 or 4 you may include "--enable-optimizations=rpi3 (or 4)" only when compiling fldigi or flrig in a 32 Bit version of the OS in order to take the best advantage of the RPi3 or 4 hardware. If building in Pi OS 64 bit do not use any optimizations.* It will fail.
Note the leading ''./'' prefixed to configure*.
Run it in the terminal window:
$ ./configure --enable-optimizations=native
If you do not find a configure script in the directory, it can be re-generated using the command
$ autoreconf -i
Verify the configure script now exists and rerun the script as shown above.
Successful completion of //configure// prints a configuration summary:
Configuration summary:
Version .......................... 4.1.20
Static linking ................... no
CPU optimizations ................ native
Debugging ........................ no
fldigi ........................... yes
flarq ............................ yes
i18n ............................. yes
fldigi build options:
sndfile .......................... yes
oss .............................. yes
portaudio ........................ yes
pulseaudio ....................... yes
flxmlrpc ......................... external lib
hamlib ........................... yes
Proceed to make and install fldigi and flarq.
$ make && sudo make install
This command will install the fldigi and flarq binaries, manual pages, icons and desktop launchers.
The recommended sound server for fldigi is Pulse Audio, but you will need to install the volume manager.
$ sudo aptitude install pavucontrol
Open the volume manager and in the first 2 tabs, make sure you select the correct sound card. Also set Playback to 50%, you will also want to set the Output to 50% as not to over-drive the output during the initial set up.
Pi3 users may find the pulse sound server is not started at boot. If so add the following to
/home/pi/.config/lxsession/LXDE-pi/autostart
"@pulseaudio --start"
Next you will need to add yourself to the dialout group. There are two ways to do this.
You can use the Users and Groups found in your menu or from a terminal::
$ sudo adduser (your user name) dialout
In either case you will need to log out and back in for it to take effect.
That should get you up and running with fldigi.
Edited by :: Dave W1HKJ, Ed W3NR, Joe K0OG, Bob NW8L, Cliff AE5ZA
Way too complex and risky. Heck with messing up my Ubuntu system. I'm done
I get to this step:
$ make && sudo make install
and get the fatal error:
'In file included from cmedia/hid.cxx:23:
cmedia/hid_lin.cxx:42:10: fatal error: libudev.h: No such file or directory
42 | #include <libudev.h>'</libudev.h>
You probably overlooked this section
on https://sourceforge.net/p/fldigi/wiki/debian_howto/
David
On 4/2/24 12:50, Mike wrote:
So I am trying to install this on a Pi 5 . Everything goes swimmingly up to the install:
make && sudo make install
returns the following error:
g++: error: unrecognized command-line option ‘-mno-3dnow’
g++: error: unrecognized command-line option ‘-mfpmath=sse’
Thoughts?
reference: https://sourceforge.net/p/fldigi/wiki/debian_howto/
Do not use cpu optimizations with the ./configure command.
David
On 8/3/24 15:58, mark acierno wrote: