How To Install unifdef on Fedora 36
Introduction
In this tutorial we learn how to install unifdef
on Fedora 36.
What is unifdef
Unifdef is useful for removing ifdefed lines from a file while otherwise leaving the file alone. Unifdef acts on #ifdef, #ifndef, #else, and #endif lines, and it knows only enough about C and C++ to know when one of these is inactive because it is inside a comment, or a single or double quote.
We can use yum
or dnf
to install unifdef
on Fedora 36. In this tutorial we discuss both methods but you only need to choose one of method to install unifdef.
Install unifdef on Fedora 36 Using dnf
Update yum database with dnf
using the following command.
sudo dnf makecache --refresh
After updating yum database, We can install unifdef
using dnf
by running the following command:
sudo dnf -y install unifdef
Install unifdef on Fedora 36 Using yum
Update yum database with yum
using the following command.
sudo yum makecache --refresh
After updating yum database, We can install unifdef
using yum
by running the following command:
sudo yum -y install unifdef
How To Uninstall unifdef on Fedora 36
To uninstall only the unifdef
package we can use the following command:
sudo dnf remove unifdef
unifdef Package Contents on Fedora 36
/usr/bin/unifdef
/usr/bin/unifdefall.sh
/usr/lib/.build-id
/usr/lib/.build-id/7c
/usr/lib/.build-id/7c/4affb5346d4b7f400700b5dbbc4a120228cf1e
/usr/share/man/man1/unifdef.1.gz
References
Summary
In this tutorial we learn how to install unifdef
on Fedora 36 using yum and [dnf]((/fedora/36/dnf/).