vychytraly .
2017-Oct-29 13:40 UTC
[CentOS] How to encourage maintainers to update their software
Frank please could you explain how to create rpms for el7 from fedora src.rpms? On Sun, Oct 29, 2017 at 12:42 AM, Frank Cox <theatre at sasktel.net> wrote:> On Sat, 28 Oct 2017 17:15:01 -0400 > H wrote: > > > The graphical configuration utility for fcitx (fcitx-configtool) is > missing > > I don't know anything about Chinese text rendering. > > > - The geany editor is missing the markdown plugin, this however, may > shortly > > be resolved. > > Check on my website. :) > > The rest of your stuff is easily dealt with by compiling the relevant > Fedora rpms. > > > I'd love to have keepassx updated > > Download this: > > ftp://mirror.csclub.uwaterloo.ca/fedora/linux/releases/25/ > Everything/source/tree/Packages/k/keepassx-2.0.3-1.fc25.src.rpm > > and you can have this: > > keepassx-2.0.3-1.el7.centos.x86_64.rpm > > I just tried it and it took only a few minutes. > > > - pdfshuffler is not available for CentOS 7, only CentOS 6. > > I just compiled this > > ftp://mirror.csclub.uwaterloo.ca/fedora/linux/releases/25/ > Everything/source/tree/Packages/p/pdfshuffler-0.6.0-9.fc25.src.rpm > > It took about three seconds to do the whole job and now I have this: > > pdfshuffler-0.6.0-9.el7.centos.noarch.rpm > > You can easily do the same if you wish. Just install rpmdevtools and any > necessary dependencies for the rpm that you want to compile and off you > go. The rpmbuild command will even tell you about any missing > dependencies. For example, my first attempt at compiling keepassx told me: > > error: Failed build dependencies: > libXtst-devel is needed by keepassx-1:2.0.3-1.el7.centos.x86_64 > libgcrypt-devel is needed by keepassx-1:2.0.3-1.el7.centos.x86_64 > > To fix it I did this: > > yum install libXtst-devel libgcrypt-devel > > My next attempt to compile the keepassx rpm worked. > > This isn't a guaranteed solution for absolutely every rpm or program that > you might ever come across; sometimes you get into a dependency rabbit hole > that never seems to end and it becomes more work than it's worth to solve. > Other times you get stuff that requires a newer or different version of > something that's way too much work to upgrade or change. But in a lot of > cases, you can just download and compile your own rpm as needed. As you > see here, two items on your wish list are easily handled this way in less > than five minutes. It took me longer to write this email than it did to > download and compile those programs. > > > -- > MELVILLE THEATRE ~ Real D 3D Digital Cinema ~ www.melvilletheatre.com > _______________________________________________ > CentOS mailing list > CentOS at centos.org > https://lists.centos.org/mailman/listinfo/centos >
Johnny Hughes
2017-Oct-29 15:21 UTC
[CentOS] How to encourage maintainers to update their software
On 10/29/2017 08:40 AM, vychytraly . wrote:> Frank please could you explain how to create rpms for el7 from fedora > src.rpms? >Well, I am not Frank, but you download the SRPM (I use wget) and put it into a directory. Then you extract it .. there are many ways to do that .. I do this: rpm -Uvh --define "_topdir $(pwd)" --nodeps <srpm.name> Then you have an exploded SRPM with a SPECS/ and SOURCES/ directory. You then need to edit the SPECS/<name>.spec file and verify each line in the spec file will work with EL7 instead of fc25 (or whatever version of Fedora you got the SRPM from). This includes but is not limited to knowing the differences in the rpm macros between that version of Fedora's rpmbuild and CentOS 7's rpmbuild .. what the versions of shared libraries (or other dependencies like python, etc.) are for that version of Fedora and CentOS 7 .. which one of those shared dependencies are required or can be degraded in version to the ones in CentOS 7. Basically, the SRPMs from Fedora 18 generally had all the required dependencies for RHEL / CentOS for the 7.0 release cycle source code .. BUT with rebases in every point release since the 7.0 cycle,, that is no longer true. Now some components (like Gnome) have very newer dependencies while others still have the dependencies from Fedora 18. Fedora 18 stopped getting updates and went EOL on 2014-01-14 .. any packages that you build based on those SRPMs need to get a new source code stream so that you can continue to get security fixes .. or you have to take the newer source code and backport the changes to the Fedora 18 based SRPMS .. or you have to get newer versions of the package and build it against the current CentOS 7 provided shared dependencies, upgrading any dependencies that are too old. THEN you have to rebuild any other packages in CentOS that used the older dependencies from CentOS 7 that you just upgraded. THEN you need to maintain not only the package that you wanted to build the way that you just did .. now you also need to maintain all those dependencies that way .. AND .. you need to maintain all of the new CentOS packages that you had to rebuild based on those dependencies in the same way. That could mean that to add one thing, you now need to maintain 20 packages. And if you are taking things from Fedora 25 (as an example) to CentOS 7, you need to be concerned about things like .. a different location for kernel install tools .. a different major version of python (python2 vs python3) .. a majorly different version of GNOME and KDE, differences in samba, in NFS, etc. etc. Again, that is why Red Hat has thousands of engineers to maintain the Enterprise Linux sources. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 198 bytes Desc: OpenPGP digital signature URL: <http://lists.centos.org/pipermail/centos/attachments/20171029/644f2de4/attachment-0001.sig>
Frank Cox
2017-Oct-29 18:50 UTC
[CentOS] How to encourage maintainers to update their software
On Sun, 29 Oct 2017 14:40:56 +0100 vychytraly . wrote:> Frank please could you explain how to create rpms for el7 from fedora > src.rpms?The complexity of doing this will vary a lot with what you're trying to compile, but for userland programs like email clients, text editors, games and the like it can be very easy to do in a lot of cases. As Johnny says, you don't really want to do this with core operating system functions since you can end up with a Frankenstein system that might not work properly any more. In many cases (more than a few but by no means all) you can compile a Fedora rpm for Centos using the following procedure. You need to have rpmdevtools installed: yum install rpmdevtools Now set up the build directory structure in your home directory: rpmdev-setuptree After that, download the Fedora srpm, then run a rpmbuild command against the rpm you downloaded: rpmbuild -ba nameofsourcerpm.src.rpm Now you see what happens. Sometimes the process will run and you'll end up with a rpm file in ~/rpmbuild/RPMS/. If so, then you're done. You've got the Centos rpm that you wanted. If the process errors out then your next step depends on the nature of the error. If it's a missing dependency then you might be able to simply install that dependency: yum install nameofdependency Then run the rpmbuild command again and see if it works. If you can't find a pre-built rpm of the missing dependency then you might be able to build it yourself using the above process. Or not. It depends on the circumstances and what's missing. If the program requires a newer version of a dependency that you already have installed, you might want to re-consier your plan at that point. See above about creating a Frankenstein system. If the process errors out due to something other than a missing dependency, things become a bit more complex at that point. If you look in ~/rpmbuild/SPECS you will find a .spec file for your rpm. Crank up your text editor and inspect that and see what it's doing and where things go wrong. Sometimes it's useful to simply compile the original source file directly and see if that works. (You can find that in ~/rpmbuild/SOURCES. ) If the original source file compiles but the rpm doesn't, then there's likely a fix that you need to do to the spec file to make it work. Sometimes it's useful to compare the spec file for an older version that does work on Centos with the spec file for a newer version that doesn't, and see what changed. If the source file doesn't compile then you have bigger problems to solve -- perhaps you need to patch the sources or perhaps it just plain won't work on Centos. That's the place where I'll usually give up unless it's really important to me to get it to work. If it is really important (that doesn't happen very often) then I keep a sacrificial Centos 7 Virtual Box image that I can use to experiment with changing some of the stuff that's under the hood without worrying about blowing up my main desktop. But again, that doesn't happen very often. Note that some Fedora stuff won't work on Centos. Period. But some stuff will work just fine. -- MELVILLE THEATRE ~ Real D 3D Digital Cinema ~ www.melvilletheatre.com
Gregory P. Ennis
2017-Oct-29 21:06 UTC
[CentOS] How to encourage maintainers to update their software
On Sun, 29 Oct 2017 14:40:56 +0100 vychytraly . wrote:> Frank please could you explain how to create rpms for el7 from fedora > src.rpms?The complexity of doing this will vary a lot with what you're trying to compile, but for userland programs like email clients, text editors, games and the like it can be very easy to do in a lot of cases. As Johnny says, you don't really want to do this with core operating system functions since you can end up with a Frankenstein system that might not work properly any more. In many cases (more than a few but by no means all) you can compile a Fedora rpm for Centos using the following procedure. ......... Frank, Thanks very much for explaining this process. I would like to have orthanc usable for Centos 7, but the epel repos only have it for Centos 6. I will give your outline a try!!! Greg
James Hogarth
2017-Oct-30 11:27 UTC
[CentOS] How to encourage maintainers to update their software
On 29 October 2017 at 13:40, vychytraly . <vychytraly at gmail.com> wrote:> Frank please could you explain how to create rpms for el7 from fedora > src.rpms? > >You may find this a useful read: https://www.hogarthuk.com/?q=node/11
vychytraly .
2017-Oct-30 15:26 UTC
[CentOS] How to encourage maintainers to update their software
Thank you all very much for explaining this, it is very interesting topic :) On Mon, Oct 30, 2017 at 12:27 PM, James Hogarth <james.hogarth at gmail.com> wrote:> On 29 October 2017 at 13:40, vychytraly . <vychytraly at gmail.com> wrote: > > Frank please could you explain how to create rpms for el7 from fedora > > src.rpms? > > > > > > You may find this a useful read: > > https://www.hogarthuk.com/?q=node/11 > _______________________________________________ > CentOS mailing list > CentOS at centos.org > https://lists.centos.org/mailman/listinfo/centos >