While building createrepo_c on Ubuntu 22.04, I got the error:
createrepo_c/build$ cmake ..
-- Checking for module 'rpm'
-- No package 'rpm' found
I have rpm installed, but that apparently doesn’t provide the includes.
All the other missing dependencies came up right away when searching SO, but I can’t seem to find this one, nor can I guess the name, like rpm-dev
. What do I need to install to be able to build?
It is actually mentioned in the Readme in the format libname
(link
) yum install
/apt install
The rpm development libraries can be installed with:
sudo apt install librpm-dev
and the full package can be built in Ubuntu 20.04 and newer with:
sudo apt update
sudo apt install -y libbz2-dev cmake \
libmagic-dev libglib2.0-dev libcurl4-openssl-dev \
libxml2-dev libpython3-dev librpm-dev libssl-dev \
libsqlite3-dev liblzma-dev zlib1g-dev libzstd-dev
git clone https://github.com/rpm-software-management/createrepo_c.git
mkdir -p build
cd build
cmake .. -DWITH_ZCHUNK=OFF -DWITH_LIBMODULEMD=OFF
make
./src/createrepo_c
but it is much easier on Ubuntu 22.04 to just install it:
sudo apt install createrepo-c