Centos – Installing newer version of installed RPM from source (CentOS)

centosrpmsqlite

I've got sqlite 3.3.6 installed through ''yum'', but I need 3.6+. There's no RPM to be found for it, so I decided to install from source. That was simple enough, but now I have both versions installed, which is problematic.

I'd like to get rid of the old version, but if I were to run ''yum erase sqlite'', that would obliterate several things that depend on SQLite. Is there some way to tell the package manager to use the version I installed instead, without going to the trouble of creating an RPM for it?

Also, could someone explain this baffling interaction from after I installed 3.7.0.1 from source (Edit: see gnaman's answer below):

> sqlite3 -version
3.3.6
> which sqlite3
/usr/local/bin/sqlite3
> /usr/local/bin/sqlite3 -version
3.7.0.1

Best Answer

I'd use RPM to remove just the sqlite 3.3.6 and no dependencies:

rpm -e –nodeps name-of-rpm-for-sqlite3.3.6

This should keep your dependencies, but remove your RPM package. Additionally, make sure that you have /usr/local/bin/ in your $PATH.