Subject: pkgsrc - make index
To: None <pkgsrc-users@NetBSD.org>
From: Ulrich Habel <uli@habel.name>
List: pkgsrc-users
Date: 03/02/2007 02:08:19
--=-S/iG9TWT6Yc1HZyCoxdo
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

Hej,

when creating a INDEX for pkgsrc after getting the tarball
pkgsrc-2006Q4.tar.gz with the command "bmake index" ( I am using Debian
Linux for pkgsrc) it failed with following error message:

newton:/usr/pkgsrc# bmake index
/bin/rm: cannot remove `/usr/pkgsrc/INDEX': No such file or directory
*** Error code 1

Stop.
bmake: stopped in /usr/pkgsrc


A quick look into the Makefile showed the problem - there is no "-f" for
the option so the build fails if the INDEX file isn't available (like in
the tarballs - and I think even for cvs checkouts).

Can't we just add the "-f" flag to the rm?

I can't see any disadvantages - the mini patch file in Uni format is
attached to the mail.


Regards

Uli


-- 
A: Yes.
>Q: Are you sure?
>>A: Because it reverses the logical flow of conversation.
>>>Q: Why is top posting annoying in email?

--=-S/iG9TWT6Yc1HZyCoxdo
Content-Disposition: attachment; filename=patch.aa
Content-Type: text/plain; name=patch.aa; charset=UTF-8
Content-Transfer-Encoding: 7bit

--- Makefile.orig	2007-03-02 02:00:33.000000000 +0100
+++ Makefile	2007-03-02 02:00:56.000000000 +0100
@@ -139,7 +139,7 @@
 
 .PHONY: index
 index:
-	@${RM} ${.CURDIR}/INDEX
+	@${RM} -f ${.CURDIR}/INDEX
 	@${MAKE} ${.CURDIR}/INDEX
 
 ${.CURDIR}/INDEX:

--=-S/iG9TWT6Yc1HZyCoxdo--