Basically try to list files owned by the package in Debian and try to find an equivalent package which provides that file on Fedora. Bear in mind that sometimes you couldn’t use the full absolute file path, so try to use */file-name
.
On Debian (preferrably use podman or VM) install apt-file
and run: apt-file show <package-name>
$ sudo apt-file show zlib1g-dev
zlib1g-dev: /usr/include/zconf.h
zlib1g-dev: /usr/include/zlib.h
zlib1g-dev: /usr/lib/x86_64-linux-gnu/libz.a
zlib1g-dev: /usr/lib/x86_64-linux-gnu/libz.so
zlib1g-dev: /usr/lib/x86_64-linux-gnu/pkgconfig/zlib.pc
zlib1g-dev: /usr/share/doc/zlib1g-dev/FAQ.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/README.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/algorithm.txt.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/changelog.Debian.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/changelog.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/copyright
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/README.examples
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/enough.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/example.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/fitblk.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/gun.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/gzappend.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/gzjoin.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/gzlog.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/gzlog.h.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/infcover.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/minigzip.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/zlib_how.html
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/zpipe.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/examples/zran.c.gz
zlib1g-dev: /usr/share/doc/zlib1g-dev/txtvsbin.txt.gz
zlib1g-dev: /usr/share/man/man3/zlib.3.gz
Then on Fedora use dnf
to get the package name:
$ sudo dnf provides /usr/include/zconf.h
Last metadata expiration check: 3:04:50 ago on Mon 29 Aug 2022 09:44:09 AM CEST.
zlib-devel-1.2.11-31.fc36.i686 : Header files and libraries for Zlib development
Repo : fedora
Matched from:
Filename : /usr/include/zconf.h
zlib-devel-1.2.11-31.fc36.x86_64 : Header files and libraries for Zlib development
Repo : fedora
Matched from:
Filename : /usr/include/zconf.h
zlib-devel-1.2.11-32.fc36.i686 : Header files and libraries for Zlib development
Repo : updates
Matched from:
Filename : /usr/include/zconf.h
zlib-devel-1.2.11-32.fc36.x86_64 : Header files and libraries for Zlib development
Repo : @System
Matched from:
Filename : /usr/include/zconf.h
zlib-devel-1.2.11-32.fc36.x86_64 : Header files and libraries for Zlib development
Repo : updates
Matched from:
Filename : /usr/include/zconf.h
Note: Skip -multilib
suffix from package name and 32
for which install :i686
equivalent and version, if needed.
Example for lib32ncurses5-dev
. Skip 32
and 5
and use:
$ sudo apt-file show libncurses-dev | grep include | head -n1
libncurses-dev: /usr/include/curses.h
$ sudo dnf provides /usr/include/curses.h
Last metadata expiration check: 3:19:58 ago on Mon 29 Aug 2022 09:44:09 AM CEST.
ncurses-devel-6.2-9.20210508.fc36.i686 : Development files for the ncurses library
Repo : fedora
Matched from:
Filename : /usr/include/curses.h
ncurses-devel-6.2-9.20210508.fc36.x86_64 : Development files for the ncurses library
Repo : @System
Matched from:
Filename : /usr/include/curses.h
ncurses-devel-6.2-9.20210508.fc36.x86_64 : Development files for the ncurses library
Repo : fedora
Matched from:
Filename : /usr/include/curses.h
For -multilib
on x86_64
install both x86_64 and ':i686` counterpart:
$ sudo apt-file show g++ | head -n1
g++: /usr/bin/g++
$ sudo dnf provides /usr/bin/g++
gcc-c++-12.0.1-0.16.fc36.i686 : C++ support for GCC
Repo : fedora
Matched from:
Filename : /usr/bin/g++
gcc-c++-12.0.1-0.16.fc36.x86_64 : C++ support for GCC
Repo : fedora
Matched from:
Filename : /usr/bin/g++
gcc-c++-12.1.1-1.fc36.x86_64 : C++ support for GCC
Repo : @System
Matched from:
Filename : /usr/bin/g++
gcc-c++-12.2.1-1.fc36.x86_64 : C++ support for GCC
Repo : updates
Matched from:
Filename : /usr/bin/g++
Finally you would need to install on Fedora:
$ sudo dnf install gcc-c++.i686 gcc-c++
Repeat, or better automate that process, for other packages.