3

I'm curious about the major difference/pros/cons between installing services and tools from source over using RPMs and from repositories.

From my understanding using a repo/rpm gives you the ability to easily install and uninstall all the files, but you lose the ability to specify advanced commands/flags or a specific version during an install.

So question is. Can you download the source file, configure it and then pack it into an RPM to give the ability to easily uninstall and upgrade later?

Tiffany Walker
  • 6,681
  • 14
  • 56
  • 82

1 Answers1

3

Yes you can. Check out this: checkinstall (I haven't used it for a while, but it should still work)

With it, you can configure the sources as needed (with ./configure --with-foo --without-bar), and compile (with make). Insted of running make install to install it, just run checkinstall, and it will create a .rpm (or .deb or .tgz) file from the package that would otherwise be installed via make install.

It doesnt work with all packes, but i've had good experience with it in my Slackware days.

mulaz
  • 10,682
  • 1
  • 31
  • 37
  • Nice, I didn't know about that tool. That would speed up writing spec files by hand a bit. Can you remember anything about the exact circumstances where this will *not* work? – Andrew B Jan 09 '13 at 00:40
  • Sometimes i had problems when scripts messed up with existing files on the filesystem. I think it was also a problem if "make install" created a new user. But mostly, i could solve the problem with "make install" and then "checkinstall", and manually removing the user after uninstall. – mulaz Jan 09 '13 at 00:43