Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: building current w/ MKXORG on 4.0




On Sep 7, 2008, at 7:16 , Zafer Aydoğan wrote:

2008/9/5 Andreas Wrede <andreas%planix.com@localhost>:
Building current with MKXORG=YES on a 4.0 system fails:

cleandir ===> external/mit/xorg/bin/glxgears
usage: rm [-f|-i] [-dPRrvW] file ...
--- cleanx11man ---
*** [cleanx11man] Error code 1
1 error

nbmake: stopped in /u1/netbsd-current/src/external/mit/xorg/bin/ glxgears

Unlike in current, in 4.0 rm -f will fail if no argument is supplied, see
revision 1.47 of src/bin/rm/rm.c:

date: 2008/05/26 14:12:06; author: christos; state: Exp; lines: +8 -6 PR/38754: murray armfield: Rm prints diagnostic messages when invoked with
-f
and no other arguments, contrary to POSIX. Also cosmetic fixes.

--
  aew



What's the workaround ? I can't compile current on an current before May 2008.


I applied the attached patch to src/rm/rm.c, which is effectively a pull-up of revision 1.47 to 4.0.
Maybe someone can issue a pull-up request for this change?

--
    aew
Index: bin/rm/rm.c
===================================================================
RCS file: /cvsroot/src/bin/rm/rm.c,v
retrieving revision 1.45
diff -u -r1.45 rm.c
--- bin/rm/rm.c 25 Aug 2006 11:00:40 -0000      1.45
+++ bin/rm/rm.c 7 Sep 2008 13:42:21 -0000
@@ -126,8 +126,11 @@
        argc -= optind;
        argv += optind;
 
-       if (argc < 1)
+       if (argc < 1) {
+               if (fflag)
+                       return 0;
                usage();
+       }
 
        checkdot(argv);
 
@@ -168,9 +171,8 @@
                flags |= FTS_NOSTAT;
        if (Wflag)
                flags |= FTS_WHITEOUT;
-       if (!(fts = fts_open(argv, flags,
-           (int (*)(const FTSENT **, const FTSENT **))NULL)))
-               err(1, NULL);
+       if ((fts = fts_open(argv, flags, NULL)) == NULL)
+               err(1, "fts_open failed");
        while ((p = fts_read(fts)) != NULL) {
        
                switch (p->fts_info) {

Attachment: PGP.sig
Description: This is a digitally signed message part



Home | Main Index | Thread Index | Old Index