Skip to content

apt-pkg: (re)export pkgTagSection::Key to fix FTBFS in python-apt

Michael Vogt requested to merge mvo/apt:fix-python-apt-build into main

With apt 2.5.1 python-apt fails to build with:

...
x86_64-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/usr/include/python3.10 -c python/acquire-item.cc -o build/temp.linux-x86_64-3.10/python/acquire-item.o -std=c++11 -Wno-write-strings -DAPT_8_CLEANER_HEADERS -DAPT_9_CLEANER_HEADERS -DAPT_10_CLEANER_HEADERS -DPY_SSIZE_T_CLEAN
In file included from python/python-apt.h:30,
                 from python/apt_pkgmodule.h:211,
                 from python/acquire-item.cc:25:
/usr/include/apt-pkg/deblistparser.h:48:65: error: ‘pkgTagSection::Key’ has not been declared
   48 |   bool ParseDepends(pkgCache::VerIterator &Ver, pkgTagSection::Key Key,
      |                                                                ^~~

This commit adds a small fix by (re)exporting pkgTagSection::Key.

Merge request reports

Loading