Sources for RPM packages for CouchDB
Fetching latest commit…
Cannot retrieve the latest commit at this time.

Creating RPM Packages for Fedora 16+ / Centos 6+

You might be able to get these specs working on ancient versions of <= Centos 5 / <= RHEL 5/ <= Fedora 15, but it is a royal pain, and requires some crazy patching to do so. It is practical to use a more current distribution release. Please don't send me patches or requests for those older OS. They won't get accepted.

These are written and tested against couchdb-1.2.0+

Building with rpmbuild on host OS

Fedora Step 1

Centos Step 1

  • Configure EPEL
    • Download latest version of epel-release epel-release
    • rpm -ihv epel-release-{version}.noarch.rpm
  • Setup rpmbuild
  • If installing into Centos 6, autoconf-archive was removed for no good reason. Please build and install as it is a prereq for building.
  • If you want a ~4X faster couchdb replace js-devel-1.7, build and install working js-devel-1.8.5
  • Install js and js-devel rpms from step above or continue

Fedora/Centos Step 2

  • Copy contents of repo to ~/rpmbuild/SOURCES
  • Fetch sources
    • spectool -g -R couchdb.spec
  • Build SRPM
    • rpmbuild -bs couchdb.spec
  • Install dependencies
    • sudo yum-builddep ~/rpmbuild/SRPMS/couchdb-{version}.{release}.src.rpm
  • rpmbuild --rebuild ~/rpmbuild/SRPMS/couchdb-{version}.{release}.src.rpm

Building rpm using mock

  • Install mock
  • Checkout this repo. All commands from within this repo.
  • CentOS build
    • copy centos-6-i386.cfg and centos-6-x86_64.cfg to /etc/mock/
  • Fetch sources
    • spectool -g -R -C ./ couchdb.spec
  • Build SRPM
    • sudo mock -r centos-6-x86_64 --buildsrpm --sources ./ --spec ./couchdb.spec
  • Copy generated SRPM to working directory
    • cp /var/lib/mock/centos-6-x86_64/result/couchdb-1.3.0-3.el6.src.rpm ./
  • Install dependencies
    • sudo mock -r centos-6-x86_64 --installdeps couchdb-1.3.0-3.el6.src.rpm
  • Build RPM
    • sudo mock -r centos-6-x86_64 rebuild couchdb-1.3.0-3.el6.src.rpm
  • Copy built RPMS to working directory
    • cp /var/lib/mock/centos-6-x86_64/result/*.rpm ./

Prerelease Notes

  • Checkout couchdb from
  • Create an archive from a release tag or repo revision: git archive --format=tar --prefix=apache-couchdb-1.2.0/ fb72251bc | gzip >apache-couchdb-1.2.0.tar.gz
  • Comment out "autoreconf -ivf" and uncomment './bootstrap' as configure doesn't exist in git repo and needs bootstrapped