I switched my laptop over from Arch to Opensuse Tumbleweed a couple months back and have been pretty happily using it ever since. So much so that I switched one of my raspberry pi 4’s over recently as well. It turns out that what I like in the two distros is mostly the rolling release model.
That said, one of the other things I found appealing about Arch (and FreeBSD before that) is that all header files were installed whenever you installed a package. So my question is, is there a way to either configure zypper to install the -dev packages automatically when I install a package, or if not then an automated way to go through what I have installed and install the corresponding -dev packages? I do a fair amount of coding and it gets tiring going through manually all the time, especially since this has never been a part of my workflow previously and I forget to check whether I’ve installed the headers for this or that package.
Hi
You can check out the development patterns available via;
zypper se -t pattern | grep devel
eg
zypper in -t pattern devel_C_C++
I guess there is a tendency not to be overly aggressive on the installation side with a rpm based distribution?
Yeah, it’s not just rpm but .deb based distros too. Thanks for the reply, I’m still getting used to zypper. I’ll see what I can come up with based on that advice.
No. Arch does not “install -dev together with main package”. Arch does not have -dev packages at all - both binaries and development headers are contained in a single package.
or if not then an automated way to go through what I have installed and install the corresponding -dev packages?
No easily. There is no mandatory rule about development package naming or content, so project may have one devel package per library or multiple runtime libraries and single devel package. And there is no package metadata that contains “development package name”. Nor is it even clear, when such automated install should happen. You install program foo that is built against libbar so libbar is automatically added as dependency. Should libbar-devel be installed automatically too? You may not even know what libbar is …
You may emulate what Arch does by installing all packages (RPMs) that were built from the same source package. Information is present in repository metadata and can be extracted. It is even conceivable to create zypper subcommand plugin for this.
I do a fair amount of coding and it gets tiring going through manually
You still need to know build requirements and install corresponding packages. I do not see how package name changes this. Also zypper supports installation by capabilities (provides), so e.g. “zypper in pkconfig(foo)” will install package that provides “pkgconfig(foo)” which most likely be libfoo-devel. You often do not even need to know actual package name.
It is unrelated to package delivery format. Nothing in RPM or deb inherently forces anyone to split project into multiple packages. It is up to distribution to set packaging policy. Of course distribution build tools need to support it, and native RPM and deb build tools offer efficient natural way to split single project into multiple packages.