Preloader
 

Tech Tips

Home / Company / Tech Tips / 32 bit tools in a 64 bit world

32 bit tools in a 64 bit world

Getting Aldec’s Riviera-Pro LV to run on Ubuntu 18.04

In FPGA/ASIC Development, most of our tools are driven by performance, and many of them run on Linux. However, they tend to be a bit behind the times on what specific version of Linux they support. And although most tools have now migrated to 64 bit, most tools vendors have kept the 64 bit option as an additional license step, because one of the advantages of 64 bit computing is additional memory space, which allows the program to handle larger designs.

For Verilog/VHDL Simulation, there are the 3 big players, Cadence, Synopsys, and Mentor Graphics, which on is usually recommended or required by the ASIC vendor, then there are several smaller players, Aldec, SynaptiCAD, Silvaco are companies that have simulators that have difficulty getting certified in the ASIC world, but usually support the FPGA vendors well, and now there are also several free/opensource/GPL simulators that are getting traction in schools, like Icarus. I have personally used tools from all the above vendors at one time or another..

Aldec like most tool vendors offers a range of tool license options, Their cheapest solution for simulation is Active-HDL. This tool is windows only, works well and is targeted to FPGA’s. Their ASIC capable tool is called Riviera-Pro, and comes in three license levels, LV, LVT and LVT-SV. Most of our designs are FPGA designs of medium size, so the memory limitation of the LV option hasn’t been an issue. LV is also a faster simulator than the comparable tool Modelsim-DE offered by Mentor Graphics. The LVT offers some speed improvements, and 64 bit support and the LVT-SV offers the addition of system verilog validation libraries

The issue: The Riviera-Pro LV licenses is limited to the 32 bit executable and the instructions do not include what 32 bit libraries are specifically required. Ubuntu 18.04 no longer includes 32 bit libraries by default, and is now requiring users to install the specific 32 bit libraries required instead of offering a “all in one” installation.

The symptom: The installation went fine, however when starting the simulator from a terminal the following error messages was displayed:

vsim &

This application failed to start because it could not find or load the Qt platform plugin “xcb”.
Available platform plugins are: xcb.
Reinstalling the application may fix this problem.

Initially we tried adding 32 bit support to Ubuntu with the following commands:

sudo dpkg --add-architecture i386
sudo pat-get install libc6:i386 libstdc++6:i386
sudo apt-get update
sudo apt-get dist-upgrade

But the problem persisted.

Doing a quick google search lead me to the following article: https://stackoverflow.com/questions/17106315/failed-to-load-platform-plugin-xcb-while-launching-qt5-app-on-linux-without

I tried the fixes suggested but still had the issues, but when I tried the following setting the environment variable QT_QPA_PLATFORM_PLUGIN_PATH my error message changed.

I found in looking through the vsim command in they start a launcher script, that sets several environment variables including the LD_LIBRARY_PATH. But not QT_QPA_PLATFORM_PLUGIN_PATH. So I set QT_QPA_PLATFORM_PLUGIN_PATH to the platform directory I found in the installation directory.

QT_QPA_PLATFORM_PLUGIN_PATH=/opt/Aldec/Riveria-Pro_2018.10/bin/Linux/platforms
export QT_QPA_PLATFORM_PLUGIN_PATH

Then when I restarted vsim, the error message changed:

vsim &

This application failed to start because it could not find or load the Qt platform plugin “xcb”.
Available platform plugins are: /opt/Aldec/Riviera-Pro_2018.10/bin/Linux/platforms/xcb.
Reinstalling the application may fix this problem.

The fact that it was showing that it did find the xcb plugin, made me look at what libraries it that plugin was missing.. (And looking at the original message, I realized it had found the plugin initially, but just couldn’t load it..

To test what libraries were required I ran the following commands

cd /opt/Aldec/Riviera-Pro_2018.10/bin/Linux/platforms
LD_LIBRARY_PATH=/opt/Aldec/Riviera-Pro_2018.10/bin/Linux:/opt/Aldec/Riviera-Pro_2018.10/bin/Linux/X11
ldd libqxcb.so

which returned the following:


linux-gate.so.1 (0xf7f17000)
libQt5XcbQpaAldec.so.5 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/libQt5XcbQpaAldec.so.5 (0xf7dd2000)
libQt5DBusAldec.so.5 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/libQt5DBusAldec.so.5 (0xf7d29000)
libfreetype.so.6 => not found
libfontconfig.so.1 => not found
libexpat.so.1 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/X11/libexpat.so.1 (0xf7be0000)
libQt5GuiAldec.so.5 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/libQt5GuiAldec.so.5 (0xf762b000)
libQt5CoreAldec.so.5 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/libQt5CoreAldec.so.5 (0xf709f000)
libpthread.so.0 => /lib/i386-linux-gnu/libpthread.so.0 (0xf7080000)
libX11.so.6 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/X11/libX11.so.6 (0xf6f38000)
libX11-xcb.so.1 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/X11/libX11-xcb.so.1 (0xf6f34000)
libSM.so.6 => not found
libICE.so.6 => not found
libxcb.so.1 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/X11/libxcb.so.1 (0xf6ee7000)
libdl.so.2 => /lib/i386-linux-gnu/libdl.so.2 (0xf6ee2000)
libstdc++.so.6 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/libstdc++.so.6 (0xf6d69000)
libm.so.6 => /lib/i386-linux-gnu/libm.so.6 (0xf6c67000)
libgcc_s.so.1 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/libgcc_s.so.1 (0xf6c4a000)
libc.so.6 => /lib/i386-linux-gnu/libc.so.6 (0xf6a6e000)
libdbus-1.so.3 => not found
libpng16.so.16 => /usr/lib/i386-linux-gnu/libpng16.so.16 (0xf69d7000)
libz.so.1 => /lib/i386-linux-gnu/libz.so.1 (0xf69b8000)
libicui18n.so.58 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/libicui18n.so.58 (0xf672b000)
libicuuc.so.58 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/libicuuc.so.58 (0xf657f000)
libicudata.so.58 => /opt/Aldec/Riviera-PRO-2018.10/bin/Linux/libicudata.so.58 (0xf4c7e000)
librt.so.1 => /lib/i386-linux-gnu/librt.so.1 (0xf4c74000)
/lib/ld-linux.so.2 (0xf7f19000)
libXau.so.6 =>not found
libXdmcp.so.6 => not found
libuuid.so.1 => /lib/i386-linux-gnu/libuuid.so.1 (0xf4c60000)
libbsd.so.0 => /lib/i386-linux-gnu/libbsd.so.0 (0xf4c45000)
libsystemd.so.0 => /lib/i386-linux-gnu/libsystemd.so.0 (0xf4bb3000)
liblzma.so.5 => /lib/i386-linux-gnu/liblzma.so.5 (0xf4b87000)
liblz4.so.1 => /usr/lib/i386-linux-gnu/liblz4.so.1 (0xf4b71000)
libgcrypt.so.20 => /lib/i386-linux-gnu/libgcrypt.so.20 (0xf4a90000)
libgpg-error.so.0 => /lib/i386-linux-gnu/libgpg-error.so.0 (0xf4a78000)

Now I had something to work with: Some of the required 32 bit libraries where still not installed. So using google I started searching what Ubuntu packages the missing files came from, and ended up installing the following packages to get it to work:

sudo apt-get install libx11-6:i386
sudo apt-get install libfreetype6:i386
sudo apt-get install libice6:i386
sudo apt-get install libsm6:i386
sudo apt-get install libdbus-1-3:i386

I found I still needed the LD_LIBRARY_PATH command in 18.04 so I added that to our modulfile for Riviera-Pro, and we were now able to simulate again.