[DRBD-user] Problem building drbd-8.2.5 rpm on Fedora Core 5 - quick fix

Jakub Konczyk kuba at houxou.com
Fri Mar 7 18:17:23 CET 2008

Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.


Hi,

'make rpm' fails on Fedora Core 5:

RPM build errors:
     File not found by glob: 
/root/drbd-8.2.5/dist/install/usr/man/man8/drbd.8.*
     File not found by glob: 
/root/drbd-8.2.5/dist/install/usr/man/man8/drbdsetup.8.*
     File not found by glob: 
/root/drbd-8.2.5/dist/install/usr/man/man8/drbdadm.8.*
     File not found by glob: 
/root/drbd-8.2.5/dist/install/usr/man/man8/drbddisk.8.*
     File not found by glob: 
/root/drbd-8.2.5/dist/install/usr/man/man5/drbd.conf.5.*
     File not found by glob: 
/root/drbd-8.2.5/dist/install/usr/man/man8/drbdmeta.8.*
make: *** [rpm] Error 1

The first problem is that drbd.spec.in is using %{_mandir} (defined in 
FC5 as /usr/man/) which is different than the one used by drdb build 
(/usr/share/man).The second problem are wrong man page names in %files 
section, for example: instead of drbd.8.* it should be drbd.8* (without dot)

Fix:

1) can possibly break other rpm builds
add to your ~/.rpmmacros:
%_mandir                %{_datadir}/man

2) apply patch to drbd.spec.in with 'patch -p 0 < patchname':

--- drbd.spec.in        2008-02-12 12:39:35.000000000 +0000
+++ drbd.spec.in.fc5-2  2008-03-07 16:37:39.000000000 +0000
@@ -128,12 +128,12 @@
  %config(noreplace) /etc/drbd.conf

  %defattr(-,root,root)
-%{_mandir}/man8/drbd.8.*
-%{_mandir}/man8/drbdsetup.8.*
-%{_mandir}/man8/drbdadm.8.*
-%{_mandir}/man8/drbddisk.8.*
-%{_mandir}/man5/drbd.conf.5.*
-%{_mandir}/man8/drbdmeta.8.*
+%{_mandir}/man8/drbd.8*
+%{_mandir}/man8/drbdsetup.8*
+%{_mandir}/man8/drbdadm.8*
+%{_mandir}/man8/drbddisk.8*
+%{_mandir}/man5/drbd.conf.5*
+%{_mandir}/man8/drbdmeta.8*
  %doc scripts/drbd.conf
  %doc COPYING
  %doc README

K



More information about the drbd-user mailing list