I'm using an old RHEL5 system and trying to install davfs from source. I don't have the option of upgrading the entire system to a newer version, so I am stuck with what I have.
This is what I have tried so far:
Setup rpmbuild environment following the instructions at https://wiki.centos.org/HowTos/SetupRpmBuildEnvironment. Works fine, I can use rpmbuild without needing sudo.
Located the closest match for davfs srpm I could find for the system I am using: http://rpm.pbone.net/index.php3/stat/26/dist/74/size/455789/name/davfs2-1.4.7-8.el6.src.rpm
Downloaded and installed the srpm
$ wget ftp://ftp.pbone.net/mirror/download.fedora.redhat.com/pub/fedora/epel/6/SRPMS/davfs2-1.4.7-8.el6.src.rpm
$ rpm -i davfs2-1.4.7-8.el6.src.rpm
Patched the source using included patch files
$ cd ~/rpmbuild/SPECS
$ rpmbuild -bp davfs2.spec
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.fxF37X
+ umask 022
+ cd /home/myusername/rpmbuild/BUILD
+ LANG=C
+ export LANG
+ unset DISPLAY
+ cd /home/myusername/rpmbuild/BUILD
+ rm -rf davfs2-1.4.7
+ /usr/bin/gzip -dc /home/myusername/rpmbuild/SOURCES/davfs2-1.4.7.tar.gz
+ /bin/tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd davfs2-1.4.7
+ /bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ echo 'Patch #1 (davfs2-1.4.7-neon-0.30.patch):'
Patch #1 (davfs2-1.4.7-neon-0.30.patch):
+ /bin/cat /home/myusername/rpmbuild/SOURCES/davfs2-1.4.7-neon-0.30.patch
+ /usr/bin/patch -p1
patching file configure
+ echo 'Patch #2 (davfs2-1.4.7-system.patch):'
Patch #2 (davfs2-1.4.7-system.patch):
+ /bin/cat /home/myusername/rpmbuild/SOURCES/davfs2-1.4.7-system.patch
+ /usr/bin/patch -p1
patching file ChangeLog
patching file src/kernel_interface.c
patching file src/mount_davfs.c
+ exit 0
Now when I try to build the patched source, I get the error below:
$ rpmbuild -ba davfs2.spec
...
configure: incompatible neon library version 0.30.0: wanted 0.25 26 27 28 29 30
configure: error: could not find neon
error: Bad exit status from /var/tmp/rpm-tmp.AFBGNB (%build)
I found a patchfile which indicates this has been fixed and it should build with neon 0.30.0: https://lists.fedoraproject.org/pipermail/scm-commits/Week-of-Mon-20130916/1115037.html. These 2 lines from that page are interesting:
# Add support for neon 0.30.0
-%patch1
This is where I am stuck. I tried looking at the .patch files included under ~/rpmbuild/SOURCES/davfs2-1.4.7
, but couldn't figure out if the patch shown on 1115037.html was included in the srpm. If it was not, how do I update the patch and build it successfully?
I have tried installing davfs binary. It installs fine, but mount fails with SSL handshake error or SSL version mismatch error due to old SSL libraries. This is why I am trying to build from source.
That line means take the %patch1
line out of the specfile. But if you look lower in the patch, it re-adds it with the -p1
parameter. That patch edits the first patch file and the specfile:
davfs2-1.4.7-neon-0.30.patch | 47 ++++++++++++++++++++++++++++++-----------
davfs2.spec | 8 +------
So you need to try applying ALL the patches in that email.