Skip to main content

libmceliece: Full Installation Guide

libmceliece: Full Installation Guide for Global Users (System-Wide)

This guide walks you through installing libmceliece — a high-performance C implementation of the McEliece post-quantum cryptosystem — from source globally on a Linux system.

Note: If you see warnings like this script does not know how to check instruction-set extensions without python3-capstone, it's recommended to install python3-capstone for accurate CPU detection.

๐Ÿงฐ 1. Prerequisites

Install all necessary and recommended dependencies:

sudo apt update && sudo apt install -y \
  autoconf \
  build-essential \
  clang \
  python3 \
  python3-pip \
  gcc \
  clang \
  valgrind \
  libcpucycles-dev \
  librandombytes-dev \
  python3-capstone \
  wget \
  curl \
  make \
  man-db 

๐Ÿ“‹ Breakdown by Category

Category Packages
Build tools gcc, clang, build-essential, make
Testing tools valgrind
Crypto dependencies libcpucycles-dev, librandombytes-dev
Python tools python3, python3-pip, python3-capstone
Network & CLI wget, curl, man-db

⬇️ 2. Download the Latest libmceliece Release

Visit the official site or use wget to fetch the latest source:

# Download the latest version tag
wget https://lib.mceliece.org/libmceliece-latest-version.txt

# Extract the version number (e.g., 2025.04.28)
version=$(cat libmceliece-latest-version.txt)

# Download the corresponding tarball
wget https://lib.mceliece.org/libmceliece-$version.tar.gz

# Extract the archive
tar -xzf libmceliece-$version.tar.gz
cd libmceliece-$version

⚙️ 3. Configure, Build and Install (System-Wide)

./configure
make -j$(nproc)
sudo make install

This installs headers, libraries, binaries, and man pages to /usr/local.

Alternative for unprivileged users:

./configure --prefix=$HOME
make -j$(nproc)
make install

This installs the following:

  • Headers: /usr/local/include/

  • Libraries: /usr/local/lib/

  • Binaries: /usr/local/bin/

  • Man pages: /usr/local/man/

✅ 4. Post-Install: Test the Library

It’s critical to run the built-in test suite to validate the integrity and security of the build:

make check

๐Ÿ› ️ Step 5: Configure the Dynamic Linker

Ensure the system recognizes the new library

sudo ldconfig


✅ Step 6: Verify Installation

Check the dynamic library is registered

sudo ldconfig

ldconfig -p | grep mceliece

Check if headers are available:

ls /usr/local/include | grep mceliece

Check if binaries are installed:

mceliece-keygen --help

๐Ÿ” 7. Troubleshooting Common Issues

  • Missing Capstone Warning: this script does not know how to check instruction-set extensions without python3-capstone
    → Fix: sudo apt install python3-capstone
  • Missing Libraries: e.g., libcpucycles or librandombytes
    → Fix: Ensure libcpucycles-dev and librandombytes-dev are installed

๐Ÿ“ 8. Breakdown by Function

CategoryPackages
Build toolsgcc, clang, build-essential, make
Testing toolsvalgrind
Post-quantum depslibcpucycles-dev, librandombytes-dev
Python envpython3, python3-pip, python3-capstone
Network/CLI toolswget, curl, man-db

๐Ÿงช 9. Optional: Check if everything is correctly installed

gcc --version
clang --version
python3 --version
python3 -c "import capstone; print('Capstone OK')"

If all print versions or success messages, your prerequisites are ready.

๐Ÿ“š References

Version: Based on 2025.04.28 release of the installation documentation.

Comments

Popular Posts

How to remove the date and .html from every blogger post url

#Remove date and .html from blogger post url A Common search term which every blogger search is How to Remove Date From Blogger Post URL or how do I remove date from blogger permalink? Follow the steps below and then date and .html will be removed from the URL of your blogger post. Step 1 : Login to your Blogger blog and select Theme / Template. Step 2 : Click on Edit HTML and paste the below code just above the </head> tag let's see code :   ➤ Code : mycode.js; Copy code <script type='text/javascript' > //<![CDATA[ // BloggerJS v0.3.1 var urlTotal,nextPageToken,postsDatePrefix=!1,accessOnly=!1,useApiV3=!1,apiKey="",blogId="",postsOrPages=["pages","posts"],jsonIndex=1,secondRequest=!0,feedPriority=0,amp="&"[0];function urlVal(){var e=window.location.pathname,t=e.length;return...

Django static files not working when debug false || debug true

# Django static and media files not working when debug is false In this article you will learn how to fix problem of not loading static files and media in Django even the DEBUG is FALSE. This is the easiest and safest solution. # Problem: Django static and media files not working when debug is false  ➤ Code: settings.py DEBUG = False #True ALLOWED_HOSTS = [ '*' ] #Host name # Problem Fix: Let's see, How you can fix the problem of Django static and media files not working when DEBUB = False : 1.)First way: devserver in insecure mode If you still need to server static locally ( e.g. for testing without debug ) you can run devserver in insecure mode: python manage.py runserver --insecure --insecure: it means you can run serve...

How to connect MongoDB with Django

In this article, you will learn how to connect to a MongoDB database to a Python web application framework Django. You will also learn how to edit your Django Project Settings file and connect your web application to a mongodb (NoSQL or document) Database. Django is a flexible framework for quickly creating Python applications. By default, Django applications are configured to store data into a lightweight SQLite database file. Connecting your Django App to a MongoDB database # Introduction: Django is used in such an amazing modular style, It’s simple to replace different components of a Django-based web application. Because document(NoSQL) databases are more common these days, you might want to try running an application with a different back end rather than one of the standard relational databases such as MySQL, SQLite, PostgreSQL or etc. 3 Ways To Connect Django With MongoDB: Djongo. MongoEngine. PyMongo. 1.) Djongo Dongo is an...