NetBSD-Users archive

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

Re: tooling around with the kernel source, had a question about cvs



> What is the cvs command to take a diff of any given change and the
> original source?

Here is are two examples:

$ cd /usr/src
$ cvs diff -u sys/conf/Makefile.kern.inc 
Index: sys/conf/Makefile.kern.inc
===================================================================
RCS file: /cvsroot/src/sys/conf/Makefile.kern.inc,v
retrieving revision 1.119
diff -u -r1.119 Makefile.kern.inc
--- sys/conf/Makefile.kern.inc  13 Nov 2008 06:48:38 -0000      1.119
+++ sys/conf/Makefile.kern.inc  19 Nov 2008 22:59:36 -0000
@@ -402,8 +402,10 @@
 .if !target(install-kernel-${MACHINE_NAME})
 install-kernel-${MACHINE_NAME}:
 .for _K in ${KERNIMAGES}
-       rm -f ${DESTDIR}/o${_K}
-       ln ${DESTDIR}/${_K} ${DESTDIR}/o${_K}
+       if [ -e "${DESTDIR}/${_K}" ] ; then             \
+               rm -f ${DESTDIR}/o${_K} ;               \
+               ln ${DESTDIR}/${_K} ${DESTDIR}/o${_K} ; \
+       fi
        cp ${_K} ${DESTDIR}/n${_K}
        mv ${DESTDIR}/n${_K} ${DESTDIR}/${_K}
 .endfor

And another example:

$ cvs diff -u -p -r1.8 -r1.9 sys/arch/amd64/amd64/locore.S
Index: sys/arch/amd64/amd64/locore.S
===================================================================
RCS file: /cvsroot/src/sys/arch/amd64/amd64/locore.S,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -p -r1.8 -r1.9
--- sys/arch/amd64/amd64/locore.S       10 Nov 2003 08:51:51 -0000      
1.8
+++ sys/arch/amd64/amd64/locore.S       30 Nov 2003 23:58:51 -0000      
1.9
@@ -1,4 +1,4 @@
-/*     $NetBSD: locore.S,v 1.8 2003/11/10 08:51:51 wiz Exp $   */
+/*     $NetBSD: locore.S,v 1.9 2003/11/30 23:58:51 fvdl Exp $  */
 
 /*
  * Copyright-o-rama!
@@ -884,6 +884,7 @@ idle_start:
        jz      idle_loop
 idle_exit:
        movl    $IPL_HIGH,CPUVAR(ILEVEL)
+       sti
 #if defined(MULTIPROCESSOR) || defined(LOCKDEBUG)       
        call    _C_LABEL(sched_lock_idle)
 #endif


Home | Main Index | Thread Index | Old Index