DESTDIR support is broken (patch)

Julien ÉLIE julien at trigofacile.com
Thu Jun 5 19:14:51 UTC 2008


Hi Ivan,

> But please note that the code above silently assumes that both
> $(MAN5) and $(MAN8) are subdirectories of a common directory and
> their ``base'' names are `man5' and `man8', respectively.

You're right.


> Thus, it's worthwhile to mention the assumption made at least in
> the code comments.  A better solution would be to check whether
> the assumption is actually satisfied and, if it isn't, to fall
> back creating absolute symbolic links (as was done before.)

Does this patch suit you?

===================================================================
--- doc/man/Makefile    (révision 7854)
+++ doc/man/Makefile    (copie de travail)
@@ -53,8 +53,13 @@
            $(CP_MAN) $$M $D$(MAN5)/$$M ; \
        done
        rm -f $D$(MAN5)/localgroups.5 $D$(MAN5)/nocem.ctl.5
-       $(LN_S) ../man8/docheckgroups.8 $D$(MAN5)/localgroups.5
-       $(LN_S) ../man8/perl-nocem.8 $D$(MAN5)/nocem.ctl.5
+       if [ -r $D$(MAN5)/../man8 ] ; then \
+           $(LN_S) ../man8/docheckgroups.8 $D$(MAN5)/localgroups.5 ; \
+           $(LN_S) ../man8/perl-nocem.8 $D$(MAN5)/nocem.ctl.5 ; \
+       else \
+           $(LN_S) $(MAN8)/docheckgroups.8 $D$(MAN5)/localgroups.5 ; \
+           $(LN_S) $(MAN8)/perl-nocem.8 $D$(MAN5)/nocem.ctl.5 ; \
+       fi

 # auth_krb5 is conditionally compiled, so handle it specially.  actsync(8)
 # also covers actsyncd.



It seems to work fine.  (And whether $D is put in the condition does not
matter.)

-- 
Julien ÉLIE

« Mon père, ce héros au sourire si doux. » (Victor Hugo) 



More information about the inn-workers mailing list