From: tholo Date: Mon, 21 Apr 1997 04:24:52 +0000 (+0000) Subject: Latest release from Cyclic Software X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=b6c0222275d7627ee4b3daf0c986f90dee05daa5;p=openbsd Latest release from Cyclic Software --- diff --git a/gnu/usr.bin/cvs/BUGS b/gnu/usr.bin/cvs/BUGS index 3c4a0d612ef..75841da80f9 100644 --- a/gnu/usr.bin/cvs/BUGS +++ b/gnu/usr.bin/cvs/BUGS @@ -15,15 +15,16 @@ similar file for the unix-like operating systems (not yet, at least). This file also might contain some platform-specific bugs. -* Importing files as binary (using wrappers to specify that--like -binwrap-1 in the testsuite) will not work on systems which need to -translate between text and binary files (that is, it will work only on -unix). (for the cause, look at send_modified and note that it knows -nothing about whether wrappers specified binary-ness). The file will -be marked as binary, but the contents will be incorrect. The -workaround is (a) import the binary files (but not text files, unless -they have been converted to unix text files) on unix, or (b) check in -the correct contents for the binary files after the import is done. +* Importing files as binary (using -kb or wrappers to specify +binaryness; see binwrap-1 in the testsuite for the latter) will not +work on systems which need to translate between text and binary files +(that is, it will work only on unix). (for the cause, look at +send_modified and note that it knows nothing about whether wrappers +specified binary-ness). The file will be marked as binary, but the +contents will be incorrect. The workaround is (a) import the binary +files (but not text files, unless they have been converted to unix +text files) on unix, or (b) check in the correct contents for the +binary files after the import is done. * Some people have reported seeing the message "dying gasps from %s diff --git a/gnu/usr.bin/cvs/ChangeLog b/gnu/usr.bin/cvs/ChangeLog index 263d0782b82..23c5a3d37f6 100644 --- a/gnu/usr.bin/cvs/ChangeLog +++ b/gnu/usr.bin/cvs/ChangeLog @@ -1,3 +1,25 @@ +Thu Apr 17 14:28:20 1997 Jim Kingdon + + * TODO: Combine items 150 and 181 since they are basically the same. + +Tue Apr 15 12:32:26 1997 Jim Kingdon + + * FAQ: The URL of yahoo's Configuration Management category has + changed. As it might change again, just cite their top-level page + rather than the entire URL. + +8 Apr 1997 Jim Kingdon + + * cvsnt.mak: Add windows-NT/sockerror.c. + +Wed Mar 26 15:51:33 1997 Jim Kingdon + + * BUGS: Further note on import -kb bug. + +Tue Mar 25 17:51:32 1997 Jim Kingdon + + * cvs-format.el: Add comment concerning c-label-offset. + Wed Mar 19 14:06:40 1997 Jim Meyering * configure.in (test for shadow passwords): Use AC_MSG_RESULT diff --git a/gnu/usr.bin/cvs/FAQ b/gnu/usr.bin/cvs/FAQ index 450fa32f57d..c7fcdd78bec 100644 --- a/gnu/usr.bin/cvs/FAQ +++ b/gnu/usr.bin/cvs/FAQ @@ -7,8 +7,5 @@ questions like "what is the latest version of CVS?" and "what about GUIs for CVS?", see the CVS web site, http://www.loria.fr/~molli/cvs-index.html. There are many web sites on Configuration Management packages (of which CVS is an example); for -example see - -http://www.yahoo.com/Computers_and_Internet/Software/Software_Engineering/Configuration_Management/index.html - -or http://www.iac.honeywell.com/Pub/Tech/CM/index.html. +example see the "Configuration Management" category at http://www.yahoo.com/ +or see http://www.iac.honeywell.com/Pub/Tech/CM/index.html. diff --git a/gnu/usr.bin/cvs/TODO b/gnu/usr.bin/cvs/TODO index 8a1fd93cc53..179a1804971 100644 --- a/gnu/usr.bin/cvs/TODO +++ b/gnu/usr.bin/cvs/TODO @@ -245,17 +245,30 @@ A new command seems appropriate for this. The state can be saved in the CVS directory. I.e., - - % cvs msg foo.c + + % cvs message foo.c Enter log message for foo.c >> fixed an uninitialized variable >> ^D - The text is saved as CVS/foo.c,m (or some such name) and commit is - modified to append (prepend?) the text (if found) to the log message - specified at commit time. Easy enough. (having cvs commit be - non-interactive takes care of various issues like whether to connect - to the server before or after prompting for a message -kingdon, June 1996) + The text is saved as CVS/foo.c,m (or some such name) and commit + is modified to append (prepend?) the text (if found) to the log + message specified at commit time. Easy enough. (having cvs + commit be non-interactive takes care of various issues like + whether to connect to the server before or after prompting for a + message (see comment in commit.c at call to start_server) + -kingdon, June 1996) + + I'm not sure about the part above about having commit prompt + for an overall message--part of the point is having commit + non-interactive and somehow combining messages seems like (excess?) + hair. + + Would be nice to do this so it allows users more flexibility in + specifying messages per-directory ("cvs message -l") or per-tree + ("cvs message") or per-file ("cvs message foo.c"), and fixes the + incompatibility between client/server (per-tree) and + non-client/server (per-directory). 151. Also, is there a flag I am missing that allows replacing Ulrtx_Build by Ultrix_build? I.E. I would like a tag replacement to be a one step @@ -371,16 +384,6 @@ similar result). (But watch out for what happens if the network is down!). -181. Make a "cvs message" command which prompts for a log message and - stores it in the CVS directory. Then "cvs ci" would use it. - This solves the problem with where in the client to prompt for - the log message (see comment in commit.c at call to - start_server), allows users more flexibility in specifying - messages per-directory ("cvs message -l") or per-tree ("cvs - message") or per-file ("cvs message foo.c"), and fixes the - incompatibility between client/server (per-tree) and - non-client/server (per-directory). - 182. There should be a way to show log entries corresponding to changes from tag "foo" to tag "bar". "cvs log -rfoo -rbar" doesn't cut it, because it is inclusive on the bar end. I'm not sure that is diff --git a/gnu/usr.bin/cvs/cvs-format.el b/gnu/usr.bin/cvs/cvs-format.el index 1ecbce2d850..06dcc62fdd4 100644 --- a/gnu/usr.bin/cvs/cvs-format.el +++ b/gnu/usr.bin/cvs/cvs-format.el @@ -81,7 +81,13 @@ ;;`c-label-offset' ;; Extra indentation for line that is a label, or case or default. - +;; This doesn't quite do the right thing for CVS switches, which use the +;; switch (foo) +;; { +;; case 0: +;; break; +;; style. But if one manually aligns the first case, then the rest +;; should work OK. (setq c-label-offset -4) ;;;; eof diff --git a/gnu/usr.bin/cvs/cvsnt.mak b/gnu/usr.bin/cvs/cvsnt.mak index c3de608ee1c..31f5a7d6daf 100644 --- a/gnu/usr.bin/cvs/cvsnt.mak +++ b/gnu/usr.bin/cvs/cvsnt.mak @@ -31,8 +31,8 @@ NULL=nul ################################################################################ # Begin Project # PROP Target_Last_Scanned "cvsnt - Win32 Debug" -CPP=cl.exe RSC=rc.exe +CPP=cl.exe !IF "$(CFG)" == "cvsnt - Win32 Release" @@ -97,6 +97,7 @@ CLEAN : -@erase ".\WinRel\diff.obj" -@erase ".\WinRel\mkdir.obj" -@erase ".\WinRel\trees.obj" + -@erase ".\WinRel\sockerror.obj" -@erase ".\WinRel\recurse.obj" -@erase ".\WinRel\import.obj" -@erase ".\WinRel\rtag.obj" @@ -214,6 +215,7 @@ LINK32_OBJS= \ "$(INTDIR)/diff.obj" \ "$(INTDIR)/mkdir.obj" \ "$(INTDIR)/trees.obj" \ + "$(INTDIR)/sockerror.obj" \ "$(INTDIR)/recurse.obj" \ "$(INTDIR)/import.obj" \ "$(INTDIR)/rtag.obj" \ @@ -285,6 +287,7 @@ CLEAN : -@erase ".\WinDebug\cvs.exe" -@erase ".\WinDebug\add.obj" -@erase ".\WinDebug\savecwd.obj" + -@erase ".\WinDebug\sockerror.obj" -@erase ".\WinDebug\infcodes.obj" -@erase ".\WinDebug\valloc.obj" -@erase ".\WinDebug\server.obj" @@ -404,6 +407,7 @@ LINK32_FLAGS=wsock32.lib kernel32.lib user32.lib gdi32.lib winspool.lib\ LINK32_OBJS= \ "$(INTDIR)/add.obj" \ "$(INTDIR)/savecwd.obj" \ + "$(INTDIR)/sockerror.obj" \ "$(INTDIR)/infcodes.obj" \ "$(INTDIR)/valloc.obj" \ "$(INTDIR)/server.obj" \ @@ -534,117 +538,35 @@ LINK32_OBJS= \ # Begin Source File SOURCE=.\src\mkmodules.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_MKMOD=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - ".\lib\getline.h"\ - - -"$(INTDIR)\mkmodules.obj" : $(SOURCE) $(DEP_CPP_MKMOD) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_MKMOD=\ ".\src\cvs.h"\ ".\lib\savecwd.h"\ ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_MKMOD=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\mkmodules.obj" : $(SOURCE) $(DEP_CPP_MKMOD) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=.\src\subr.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_SUBR_=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - - -"$(INTDIR)\subr.obj" : $(SOURCE) $(DEP_CPP_SUBR_) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_SUBR_=\ ".\src\cvs.h"\ ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_SUBR_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\subr.obj" : $(SOURCE) $(DEP_CPP_SUBR_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=.\src\admin.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - DEP_CPP_ADMIN=\ ".\src\cvs.h"\ @@ -653,65 +575,11 @@ DEP_CPP_ADMIN=\ $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_ADMIN=\ - ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_ADMIN=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\admin.obj" : $(SOURCE) $(DEP_CPP_ADMIN) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=.\src\server.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_SERVE=\ - ".\src\cvs.h"\ - ".\src\watch.h"\ - ".\src\edit.h"\ - ".\src\fileattr.h"\ - ".\lib\getline.h"\ - ".\src\buffer.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - - -"$(INTDIR)\server.obj" : $(SOURCE) $(DEP_CPP_SERVE) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_SERVE=\ ".\src\cvs.h"\ ".\src\watch.h"\ @@ -720,110 +588,30 @@ DEP_CPP_SERVE=\ ".\lib\getline.h"\ ".\src\buffer.h"\ {$(INCLUDE)}"\sys\Types.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_SERVE=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\server.obj" : $(SOURCE) $(DEP_CPP_SERVE) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=.\src\diff.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_DIFF_=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\diff.obj" : $(SOURCE) $(DEP_CPP_DIFF_) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_DIFF_=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_DIFF_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\diff.obj" : $(SOURCE) $(DEP_CPP_DIFF_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=.\src\client.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_CLIEN=\ - ".\windows-NT\config.h"\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\src\edit.h"\ - ".\src\buffer.h"\ - ".\lib\md5.h"\ - - -"$(INTDIR)\client.obj" : $(SOURCE) $(DEP_CPP_CLIEN) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_CLIEN=\ ".\windows-NT\config.h"\ ".\src\cvs.h"\ @@ -831,44 +619,17 @@ DEP_CPP_CLIEN=\ ".\src\edit.h"\ ".\src\buffer.h"\ ".\lib\md5.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_CLIEN=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\client.obj" : $(SOURCE) $(DEP_CPP_CLIEN) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=.\src\checkout.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - DEP_CPP_CHECK=\ ".\src\cvs.h"\ @@ -877,2374 +638,623 @@ DEP_CPP_CHECK=\ $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_CHECK=\ +SOURCE=.\src\no_diff.c +DEP_CPP_NO_DI=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_CHECK=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ -"$(INTDIR)\checkout.obj" : $(SOURCE) $(DEP_CPP_CHECK) "$(INTDIR)" +"$(INTDIR)\no_diff.obj" : $(SOURCE) $(DEP_CPP_NO_DI) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\no_diff.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_NO_DI=\ +SOURCE=.\src\entries.c +DEP_CPP_ENTRI=\ ".\src\cvs.h"\ + ".\lib\getline.h"\ -"$(INTDIR)\no_diff.obj" : $(SOURCE) $(DEP_CPP_NO_DI) "$(INTDIR)" +"$(INTDIR)\entries.obj" : $(SOURCE) $(DEP_CPP_ENTRI) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_NO_DI=\ +SOURCE=.\src\tag.c +DEP_CPP_TAG_C=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_NO_DI=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ + ".\lib\savecwd.h"\ -"$(INTDIR)\no_diff.obj" : $(SOURCE) $(DEP_CPP_NO_DI) "$(INTDIR)" +"$(INTDIR)\tag.obj" : $(SOURCE) $(DEP_CPP_TAG_C) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\entries.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_ENTRI=\ +SOURCE=.\src\rtag.c +DEP_CPP_RTAG_=\ ".\src\cvs.h"\ - ".\lib\getline.h"\ -"$(INTDIR)\entries.obj" : $(SOURCE) $(DEP_CPP_ENTRI) "$(INTDIR)" +"$(INTDIR)\rtag.obj" : $(SOURCE) $(DEP_CPP_RTAG_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_ENTRI=\ +# End Source File +################################################################################ +# Begin Source File + +SOURCE=.\src\status.c +DEP_CPP_STATU=\ ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_ENTRI=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ -"$(INTDIR)\entries.obj" : $(SOURCE) $(DEP_CPP_ENTRI) "$(INTDIR)" +"$(INTDIR)\status.obj" : $(SOURCE) $(DEP_CPP_STATU) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\tag.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_TAG_C=\ +SOURCE=.\src\root.c +DEP_CPP_ROOT_=\ ".\src\cvs.h"\ - ".\lib\savecwd.h"\ + ".\lib\getline.h"\ -"$(INTDIR)\tag.obj" : $(SOURCE) $(DEP_CPP_TAG_C) "$(INTDIR)" +"$(INTDIR)\root.obj" : $(SOURCE) $(DEP_CPP_ROOT_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_TAG_C=\ +SOURCE=.\src\myndbm.c +DEP_CPP_MYNDB=\ ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_TAG_C=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ + ".\lib\getline.h"\ -"$(INTDIR)\tag.obj" : $(SOURCE) $(DEP_CPP_TAG_C) "$(INTDIR)" +"$(INTDIR)\myndbm.obj" : $(SOURCE) $(DEP_CPP_MYNDB) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\rtag.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_RTAG_=\ +SOURCE=.\src\hash.c +DEP_CPP_HASH_=\ ".\src\cvs.h"\ -"$(INTDIR)\rtag.obj" : $(SOURCE) $(DEP_CPP_RTAG_) "$(INTDIR)" +"$(INTDIR)\hash.obj" : $(SOURCE) $(DEP_CPP_HASH_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_RTAG_=\ +SOURCE=.\src\repos.c +DEP_CPP_REPOS=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_RTAG_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ + ".\lib\getline.h"\ -"$(INTDIR)\rtag.obj" : $(SOURCE) $(DEP_CPP_RTAG_) "$(INTDIR)" +"$(INTDIR)\repos.obj" : $(SOURCE) $(DEP_CPP_REPOS) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\status.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_STATU=\ +SOURCE=.\src\parseinfo.c +DEP_CPP_PARSE=\ ".\src\cvs.h"\ + ".\lib\getline.h"\ -"$(INTDIR)\status.obj" : $(SOURCE) $(DEP_CPP_STATU) "$(INTDIR)" +"$(INTDIR)\parseinfo.obj" : $(SOURCE) $(DEP_CPP_PARSE) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_STATU=\ +SOURCE=.\src\vers_ts.c +DEP_CPP_VERS_=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_STATU=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ -"$(INTDIR)\status.obj" : $(SOURCE) $(DEP_CPP_STATU) "$(INTDIR)" +"$(INTDIR)\vers_ts.obj" : $(SOURCE) $(DEP_CPP_VERS_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\root.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_ROOT_=\ +SOURCE=.\src\checkin.c +DEP_CPP_CHECKI=\ ".\src\cvs.h"\ - ".\lib\getline.h"\ + ".\src\fileattr.h"\ + ".\src\edit.h"\ -"$(INTDIR)\root.obj" : $(SOURCE) $(DEP_CPP_ROOT_) "$(INTDIR)" +"$(INTDIR)\checkin.obj" : $(SOURCE) $(DEP_CPP_CHECKI) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_ROOT_=\ +SOURCE=.\src\commit.c +DEP_CPP_COMMI=\ ".\src\cvs.h"\ ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_ROOT_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ + ".\src\edit.h"\ + ".\src\fileattr.h"\ -"$(INTDIR)\root.obj" : $(SOURCE) $(DEP_CPP_ROOT_) "$(INTDIR)" +"$(INTDIR)\commit.obj" : $(SOURCE) $(DEP_CPP_COMMI) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\myndbm.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_MYNDB=\ +SOURCE=.\src\version.c +DEP_CPP_VERSI=\ ".\src\cvs.h"\ - ".\lib\getline.h"\ -"$(INTDIR)\myndbm.obj" : $(SOURCE) $(DEP_CPP_MYNDB) "$(INTDIR)" +"$(INTDIR)\version.obj" : $(SOURCE) $(DEP_CPP_VERSI) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_MYNDB=\ +SOURCE=.\src\cvsrc.c +DEP_CPP_CVSRC=\ ".\src\cvs.h"\ ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_MYNDB=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ -"$(INTDIR)\myndbm.obj" : $(SOURCE) $(DEP_CPP_MYNDB) "$(INTDIR)" +"$(INTDIR)\cvsrc.obj" : $(SOURCE) $(DEP_CPP_CVSRC) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\hash.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_HASH_=\ +SOURCE=.\src\remove.c +DEP_CPP_REMOV=\ ".\src\cvs.h"\ -"$(INTDIR)\hash.obj" : $(SOURCE) $(DEP_CPP_HASH_) "$(INTDIR)" +"$(INTDIR)\remove.obj" : $(SOURCE) $(DEP_CPP_REMOV) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_HASH_=\ +SOURCE=.\src\update.c +DEP_CPP_UPDAT=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_HASH_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ + ".\lib\savecwd.h"\ + ".\lib\md5.h"\ + ".\src\watch.h"\ + ".\src\fileattr.h"\ + ".\src\edit.h"\ + ".\lib\getline.h"\ -"$(INTDIR)\hash.obj" : $(SOURCE) $(DEP_CPP_HASH_) "$(INTDIR)" +"$(INTDIR)\update.obj" : $(SOURCE) $(DEP_CPP_UPDAT) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\repos.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_REPOS=\ +SOURCE=.\src\logmsg.c +DEP_CPP_LOGMS=\ ".\src\cvs.h"\ ".\lib\getline.h"\ -"$(INTDIR)\repos.obj" : $(SOURCE) $(DEP_CPP_REPOS) "$(INTDIR)" +"$(INTDIR)\logmsg.obj" : $(SOURCE) $(DEP_CPP_LOGMS) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_REPOS=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_REPOS=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ +SOURCE=.\src\classify.c +DEP_CPP_CLASS=\ + ".\src\cvs.h"\ -"$(INTDIR)\repos.obj" : $(SOURCE) $(DEP_CPP_REPOS) "$(INTDIR)" +"$(INTDIR)\classify.obj" : $(SOURCE) $(DEP_CPP_CLASS) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\parseinfo.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_PARSE=\ +SOURCE=.\src\history.c +DEP_CPP_HISTO=\ ".\src\cvs.h"\ - ".\lib\getline.h"\ + ".\lib\savecwd.h"\ -"$(INTDIR)\parseinfo.obj" : $(SOURCE) $(DEP_CPP_PARSE) "$(INTDIR)" +"$(INTDIR)\history.obj" : $(SOURCE) $(DEP_CPP_HISTO) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_PARSE=\ +SOURCE=.\src\add.c +DEP_CPP_ADD_C=\ ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_PARSE=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ + ".\lib\savecwd.h"\ -"$(INTDIR)\parseinfo.obj" : $(SOURCE) $(DEP_CPP_PARSE) "$(INTDIR)" +"$(INTDIR)\add.obj" : $(SOURCE) $(DEP_CPP_ADD_C) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\vers_ts.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_VERS_=\ +SOURCE=.\src\lock.c +DEP_CPP_LOCK_=\ ".\src\cvs.h"\ -"$(INTDIR)\vers_ts.obj" : $(SOURCE) $(DEP_CPP_VERS_) "$(INTDIR)" +"$(INTDIR)\lock.obj" : $(SOURCE) $(DEP_CPP_LOCK_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_VERS_=\ +SOURCE=.\src\recurse.c +DEP_CPP_RECUR=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_VERS_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ + ".\lib\savecwd.h"\ + ".\src\fileattr.h"\ + ".\src\edit.h"\ -"$(INTDIR)\vers_ts.obj" : $(SOURCE) $(DEP_CPP_VERS_) "$(INTDIR)" +"$(INTDIR)\recurse.obj" : $(SOURCE) $(DEP_CPP_RECUR) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\checkin.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_CHECKI=\ +SOURCE=.\src\modules.c +DEP_CPP_MODUL=\ ".\src\cvs.h"\ - ".\src\fileattr.h"\ - ".\src\edit.h"\ + ".\lib\savecwd.h"\ -"$(INTDIR)\checkin.obj" : $(SOURCE) $(DEP_CPP_CHECKI) "$(INTDIR)" +"$(INTDIR)\modules.obj" : $(SOURCE) $(DEP_CPP_MODUL) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_CHECKI=\ +SOURCE=.\src\find_names.c +DEP_CPP_FIND_=\ ".\src\cvs.h"\ - ".\src\fileattr.h"\ - ".\src\edit.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_CHECKI=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ -"$(INTDIR)\checkin.obj" : $(SOURCE) $(DEP_CPP_CHECKI) "$(INTDIR)" +"$(INTDIR)\find_names.obj" : $(SOURCE) $(DEP_CPP_FIND_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\commit.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_COMMI=\ +SOURCE=.\src\rcs.c +DEP_CPP_RCS_C=\ ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\src\edit.h"\ - ".\src\fileattr.h"\ -"$(INTDIR)\commit.obj" : $(SOURCE) $(DEP_CPP_COMMI) "$(INTDIR)" +"$(INTDIR)\rcs.obj" : $(SOURCE) $(DEP_CPP_RCS_C) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_COMMI=\ +SOURCE=.\src\create_adm.c +DEP_CPP_CREAT=\ ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\src\edit.h"\ - ".\src\fileattr.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_COMMI=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ -"$(INTDIR)\commit.obj" : $(SOURCE) $(DEP_CPP_COMMI) "$(INTDIR)" +"$(INTDIR)\create_adm.obj" : $(SOURCE) $(DEP_CPP_CREAT) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\version.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_VERSI=\ +SOURCE=.\src\main.c +DEP_CPP_MAIN_=\ ".\src\cvs.h"\ -"$(INTDIR)\version.obj" : $(SOURCE) $(DEP_CPP_VERSI) "$(INTDIR)" +"$(INTDIR)\main.obj" : $(SOURCE) $(DEP_CPP_MAIN_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_VERSI=\ +SOURCE=.\src\patch.c +DEP_CPP_PATCH=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_VERSI=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ + ".\lib\getline.h"\ -"$(INTDIR)\version.obj" : $(SOURCE) $(DEP_CPP_VERSI) "$(INTDIR)" +"$(INTDIR)\patch.obj" : $(SOURCE) $(DEP_CPP_PATCH) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\cvsrc.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_CVSRC=\ +SOURCE=.\src\release.c +DEP_CPP_RELEA=\ ".\src\cvs.h"\ ".\lib\getline.h"\ -"$(INTDIR)\cvsrc.obj" : $(SOURCE) $(DEP_CPP_CVSRC) "$(INTDIR)" +"$(INTDIR)\release.obj" : $(SOURCE) $(DEP_CPP_RELEA) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_CVSRC=\ +SOURCE=.\src\rcscmds.c +DEP_CPP_RCSCM=\ ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_CVSRC=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ -"$(INTDIR)\cvsrc.obj" : $(SOURCE) $(DEP_CPP_CVSRC) "$(INTDIR)" +"$(INTDIR)\rcscmds.obj" : $(SOURCE) $(DEP_CPP_RCSCM) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\remove.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_REMOV=\ +SOURCE=.\src\import.c +DEP_CPP_IMPOR=\ ".\src\cvs.h"\ + ".\lib\savecwd.h"\ -"$(INTDIR)\remove.obj" : $(SOURCE) $(DEP_CPP_REMOV) "$(INTDIR)" +"$(INTDIR)\import.obj" : $(SOURCE) $(DEP_CPP_IMPOR) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_REMOV=\ - ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_REMOV=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\remove.obj" : $(SOURCE) $(DEP_CPP_REMOV) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\update.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_UPDAT=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - ".\lib\md5.h"\ - ".\src\watch.h"\ - ".\src\fileattr.h"\ - ".\src\edit.h"\ - ".\lib\getline.h"\ - - -"$(INTDIR)\update.obj" : $(SOURCE) $(DEP_CPP_UPDAT) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_UPDAT=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - ".\lib\md5.h"\ - ".\src\watch.h"\ - ".\src\fileattr.h"\ - ".\src\edit.h"\ - ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_UPDAT=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\update.obj" : $(SOURCE) $(DEP_CPP_UPDAT) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\logmsg.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_LOGMS=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - - -"$(INTDIR)\logmsg.obj" : $(SOURCE) $(DEP_CPP_LOGMS) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_LOGMS=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_LOGMS=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\logmsg.obj" : $(SOURCE) $(DEP_CPP_LOGMS) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\classify.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_CLASS=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\classify.obj" : $(SOURCE) $(DEP_CPP_CLASS) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_CLASS=\ - ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_CLASS=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\classify.obj" : $(SOURCE) $(DEP_CPP_CLASS) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\history.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_HISTO=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - - -"$(INTDIR)\history.obj" : $(SOURCE) $(DEP_CPP_HISTO) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_HISTO=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_HISTO=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\history.obj" : $(SOURCE) $(DEP_CPP_HISTO) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\add.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_ADD_C=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - - -"$(INTDIR)\add.obj" : $(SOURCE) $(DEP_CPP_ADD_C) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_ADD_C=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_ADD_C=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\add.obj" : $(SOURCE) $(DEP_CPP_ADD_C) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\lock.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_LOCK_=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\lock.obj" : $(SOURCE) $(DEP_CPP_LOCK_) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_LOCK_=\ - ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_LOCK_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\lock.obj" : $(SOURCE) $(DEP_CPP_LOCK_) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\recurse.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_RECUR=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - ".\src\fileattr.h"\ - ".\src\edit.h"\ - - -"$(INTDIR)\recurse.obj" : $(SOURCE) $(DEP_CPP_RECUR) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_RECUR=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - ".\src\fileattr.h"\ - ".\src\edit.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_RECUR=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\recurse.obj" : $(SOURCE) $(DEP_CPP_RECUR) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\modules.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_MODUL=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - - -"$(INTDIR)\modules.obj" : $(SOURCE) $(DEP_CPP_MODUL) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_MODUL=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_MODUL=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\modules.obj" : $(SOURCE) $(DEP_CPP_MODUL) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\find_names.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_FIND_=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\find_names.obj" : $(SOURCE) $(DEP_CPP_FIND_) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_FIND_=\ - ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_FIND_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\find_names.obj" : $(SOURCE) $(DEP_CPP_FIND_) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\rcs.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_RCS_C=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\rcs.obj" : $(SOURCE) $(DEP_CPP_RCS_C) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_RCS_C=\ - ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_RCS_C=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\rcs.obj" : $(SOURCE) $(DEP_CPP_RCS_C) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\create_adm.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_CREAT=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\create_adm.obj" : $(SOURCE) $(DEP_CPP_CREAT) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_CREAT=\ - ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_CREAT=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\create_adm.obj" : $(SOURCE) $(DEP_CPP_CREAT) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\main.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_MAIN_=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\main.obj" : $(SOURCE) $(DEP_CPP_MAIN_) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_MAIN_=\ - ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_MAIN_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\main.obj" : $(SOURCE) $(DEP_CPP_MAIN_) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\patch.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_PATCH=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - - -"$(INTDIR)\patch.obj" : $(SOURCE) $(DEP_CPP_PATCH) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_PATCH=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_PATCH=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\patch.obj" : $(SOURCE) $(DEP_CPP_PATCH) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\release.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_RELEA=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - - -"$(INTDIR)\release.obj" : $(SOURCE) $(DEP_CPP_RELEA) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_RELEA=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_RELEA=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\release.obj" : $(SOURCE) $(DEP_CPP_RELEA) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\rcscmds.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_RCSCM=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\rcscmds.obj" : $(SOURCE) $(DEP_CPP_RCSCM) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_RCSCM=\ - ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_RCSCM=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\rcscmds.obj" : $(SOURCE) $(DEP_CPP_RCSCM) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\import.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_IMPOR=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - - -"$(INTDIR)\import.obj" : $(SOURCE) $(DEP_CPP_IMPOR) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_IMPOR=\ - ".\src\cvs.h"\ - ".\lib\savecwd.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_IMPOR=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\import.obj" : $(SOURCE) $(DEP_CPP_IMPOR) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\ignore.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_IGNOR=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - - -"$(INTDIR)\ignore.obj" : $(SOURCE) $(DEP_CPP_IGNOR) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_IGNOR=\ +SOURCE=.\src\ignore.c +DEP_CPP_IGNOR=\ ".\src\cvs.h"\ ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_IGNOR=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\ignore.obj" : $(SOURCE) $(DEP_CPP_IGNOR) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\log.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_LOG_C=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\log.obj" : $(SOURCE) $(DEP_CPP_LOG_C) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_LOG_C=\ - ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_LOG_C=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ -"$(INTDIR)\log.obj" : $(SOURCE) $(DEP_CPP_LOG_C) "$(INTDIR)" +"$(INTDIR)\ignore.obj" : $(SOURCE) $(DEP_CPP_IGNOR) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\wrapper.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_WRAPP=\ +SOURCE=.\src\log.c +DEP_CPP_LOG_C=\ ".\src\cvs.h"\ - ".\lib\getline.h"\ -"$(INTDIR)\wrapper.obj" : $(SOURCE) $(DEP_CPP_WRAPP) "$(INTDIR)" +"$(INTDIR)\log.obj" : $(SOURCE) $(DEP_CPP_LOG_C) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File +SOURCE=.\src\wrapper.c DEP_CPP_WRAPP=\ ".\src\cvs.h"\ ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_WRAPP=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\wrapper.obj" : $(SOURCE) $(DEP_CPP_WRAPP) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=.\src\error.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_ERROR=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\error.obj" : $(SOURCE) $(DEP_CPP_ERROR) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_ERROR=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_ERROR=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\error.obj" : $(SOURCE) $(DEP_CPP_ERROR) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=.\src\expand_path.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_EXPAN=\ - ".\src\cvs.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - - -"$(INTDIR)\expand_path.obj" : $(SOURCE) $(DEP_CPP_EXPAN) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_EXPAN=\ ".\src\cvs.h"\ {$(INCLUDE)}"\sys\Types.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_EXPAN=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\expand_path.obj" : $(SOURCE) $(DEP_CPP_EXPAN) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=.\src\edit.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_EDIT_=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\src\watch.h"\ - ".\src\edit.h"\ - ".\src\fileattr.h"\ - - -"$(INTDIR)\edit.obj" : $(SOURCE) $(DEP_CPP_EDIT_) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_EDIT_=\ ".\src\cvs.h"\ ".\lib\getline.h"\ ".\src\watch.h"\ ".\src\edit.h"\ ".\src\fileattr.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_EDIT_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\edit.obj" : $(SOURCE) $(DEP_CPP_EDIT_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\fileattr.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_FILEA=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\src\fileattr.h"\ - - -"$(INTDIR)\fileattr.obj" : $(SOURCE) $(DEP_CPP_FILEA) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_FILEA=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\src\fileattr.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_FILEA=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\fileattr.obj" : $(SOURCE) $(DEP_CPP_FILEA) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\watch.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_WATCH=\ - ".\src\cvs.h"\ - ".\src\edit.h"\ - ".\src\fileattr.h"\ - ".\src\watch.h"\ - - -"$(INTDIR)\watch.obj" : $(SOURCE) $(DEP_CPP_WATCH) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_WATCH=\ - ".\src\cvs.h"\ - ".\src\edit.h"\ - ".\src\fileattr.h"\ - ".\src\watch.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_WATCH=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\watch.obj" : $(SOURCE) $(DEP_CPP_WATCH) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - -# End Source File -################################################################################ -# Begin Source File - -SOURCE=.\src\login.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_LOGIN=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - - -"$(INTDIR)\login.obj" : $(SOURCE) $(DEP_CPP_LOGIN) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - -DEP_CPP_LOGIN=\ - ".\src\cvs.h"\ - ".\lib\getline.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_LOGIN=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - - -"$(INTDIR)\login.obj" : $(SOURCE) $(DEP_CPP_LOGIN) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\scramble.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_SCRAM=\ +SOURCE=.\src\fileattr.c +DEP_CPP_FILEA=\ ".\src\cvs.h"\ + ".\lib\getline.h"\ + ".\src\fileattr.h"\ -"$(INTDIR)\scramble.obj" : $(SOURCE) $(DEP_CPP_SCRAM) "$(INTDIR)" +"$(INTDIR)\fileattr.obj" : $(SOURCE) $(DEP_CPP_FILEA) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_SCRAM=\ +SOURCE=.\src\watch.c +DEP_CPP_WATCH=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_SCRAM=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ + ".\src\edit.h"\ + ".\src\fileattr.h"\ + ".\src\watch.h"\ -"$(INTDIR)\scramble.obj" : $(SOURCE) $(DEP_CPP_SCRAM) "$(INTDIR)" +"$(INTDIR)\watch.obj" : $(SOURCE) $(DEP_CPP_WATCH) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\buffer.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_BUFFE=\ +SOURCE=.\src\login.c +DEP_CPP_LOGIN=\ ".\src\cvs.h"\ - ".\src\buffer.h"\ + ".\lib\getline.h"\ -"$(INTDIR)\buffer.obj" : $(SOURCE) $(DEP_CPP_BUFFE) "$(INTDIR)" +"$(INTDIR)\login.obj" : $(SOURCE) $(DEP_CPP_LOGIN) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File -DEP_CPP_BUFFE=\ +SOURCE=.\src\scramble.c +DEP_CPP_SCRAM=\ ".\src\cvs.h"\ - ".\src\buffer.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_BUFFE=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ -"$(INTDIR)\buffer.obj" : $(SOURCE) $(DEP_CPP_BUFFE) "$(INTDIR)" +"$(INTDIR)\scramble.obj" : $(SOURCE) $(DEP_CPP_SCRAM) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File -SOURCE=.\src\zlib.c - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_ZLIB_=\ +SOURCE=.\src\buffer.c +DEP_CPP_BUFFE=\ ".\src\cvs.h"\ ".\src\buffer.h"\ - ".\zlib\zlib.h"\ - ".\zlib\zconf.h"\ -"$(INTDIR)\zlib.obj" : $(SOURCE) $(DEP_CPP_ZLIB_) "$(INTDIR)" +"$(INTDIR)\buffer.obj" : $(SOURCE) $(DEP_CPP_BUFFE) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" +# End Source File +################################################################################ +# Begin Source File +SOURCE=.\src\zlib.c DEP_CPP_ZLIB_=\ ".\src\cvs.h"\ ".\src\buffer.h"\ ".\zlib\zlib.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ ".\zlib\zconf.h"\ -NODEP_CPP_ZLIB_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ - "$(INTDIR)\zlib.obj" : $(SOURCE) $(DEP_CPP_ZLIB_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File @@ -3509,103 +1519,27 @@ DEP_CPP_VASPR=\ # Begin Source File SOURCE=".\windows-NT\mkdir.c" - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_MKDIR=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\mkdir.obj" : $(SOURCE) $(DEP_CPP_MKDIR) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_MKDIR=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_MKDIR=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\mkdir.obj" : $(SOURCE) $(DEP_CPP_MKDIR) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=".\windows-NT\run.c" - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_RUN_C=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\run.obj" : $(SOURCE) $(DEP_CPP_RUN_C) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_RUN_C=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_RUN_C=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\run.obj" : $(SOURCE) $(DEP_CPP_RUN_C) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File @@ -3624,52 +1558,14 @@ DEP_CPP_PWD_C=\ # Begin Source File SOURCE=".\windows-NT\filesubr.c" - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_FILES=\ - ".\src\cvs.h"\ - - -"$(INTDIR)\filesubr.obj" : $(SOURCE) $(DEP_CPP_FILES) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_FILES=\ ".\src\cvs.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_FILES=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\filesubr.obj" : $(SOURCE) $(DEP_CPP_FILES) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File @@ -3726,107 +1622,29 @@ SOURCE=".\windows-NT\stripslash.c" # Begin Source File SOURCE=".\windows-NT\rcmd.c" - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_RCMD_=\ - ".\src\cvs.h"\ - ".\windows-NT\rcmd.h"\ - - -"$(INTDIR)\rcmd.obj" : $(SOURCE) $(DEP_CPP_RCMD_) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_RCMD_=\ ".\src\cvs.h"\ ".\windows-NT\rcmd.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_RCMD_=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\rcmd.obj" : $(SOURCE) $(DEP_CPP_RCMD_) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File SOURCE=".\windows-NT\startserver.c" - -!IF "$(CFG)" == "cvsnt - Win32 Release" - -DEP_CPP_START=\ - ".\src\cvs.h"\ - ".\windows-NT\rcmd.h"\ - - -"$(INTDIR)\startserver.obj" : $(SOURCE) $(DEP_CPP_START) "$(INTDIR)" - $(CPP) $(CPP_PROJ) $(SOURCE) - - -!ELSEIF "$(CFG)" == "cvsnt - Win32 Debug" - DEP_CPP_START=\ ".\src\cvs.h"\ ".\windows-NT\rcmd.h"\ - ".\windows-NT\config.h"\ - ".\windows-NT\options.h"\ - ".\lib\fnmatch.h"\ - ".\windows-NT\pwd.h"\ - ".\lib\system.h"\ - ".\src\hash.h"\ - ".\src\client.h"\ - ".\src\myndbm.h"\ - ".\lib\regex.h"\ - ".\lib\getopt.h"\ - ".\lib\wait.h"\ - ".\src\rcs.h"\ - ".\src\update.h"\ - ".\src\server.h"\ - {$(INCLUDE)}"\sys\Types.h"\ - {$(INCLUDE)}"\sys\Stat.h"\ - {$(INCLUDE)}"\sys\Timeb.h"\ - {$(INCLUDE)}"\sys\Utime.h"\ - ".\windows-NT\ndir.h"\ - -NODEP_CPP_START=\ - ".\src\popen.h"\ - ".\lib\tcpip.h"\ "$(INTDIR)\startserver.obj" : $(SOURCE) $(DEP_CPP_START) "$(INTDIR)" $(CPP) $(CPP_PROJ) $(SOURCE) -!ENDIF - # End Source File ################################################################################ # Begin Source File @@ -4067,6 +1885,16 @@ DEP_CPP_TREES=\ $(CPP) $(CPP_PROJ) $(SOURCE) +# End Source File +################################################################################ +# Begin Source File + +SOURCE=".\windows-NT\sockerror.c" + +"$(INTDIR)\sockerror.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + # End Source File # End Target # End Project diff --git a/gnu/usr.bin/cvs/doc/ChangeLog b/gnu/usr.bin/cvs/doc/ChangeLog index 27314bed625..182ac42030d 100644 --- a/gnu/usr.bin/cvs/doc/ChangeLog +++ b/gnu/usr.bin/cvs/doc/ChangeLog @@ -1,3 +1,164 @@ +Fri Apr 18 12:05:48 1997 Jim Kingdon + + * cvs.texinfo (Assigning revisions): Say that -r implies -f. + +Thu Apr 17 16:34:14 1997 Jim Kingdon + + * cvs.texinfo (From other version control systems): Add comment + about CMZ and PATCHY. + +Wed Apr 16 12:35:25 1997 Jim Kingdon + + * cvsclient.texi (Responses): Add paragraph describing how + Copy-file relates to Merged. + (Responses): Add paragraph about how it is the server which + worries about not clobbering the user's file. + +Tue Apr 15 00:57:31 1997 Jim Kingdon + + * RCSFILES: Add notes on keyword expansion. + + * cvs.texinfo (Rename by copying): Comment out seemingly erroneous + text regarding the revision number that the new file starts with. + +Mon Apr 14 12:37:35 1997 Jim Kingdon + + * cvsclient.texi (Requests): Clients should try to send + notifications right away. + + * cvsclient.texi (Requests): For Notify request, clarify a few + future expansion situations. Specify the format of the time. + + * cvsclient.texi (Requests): Clarify that arguments to co, rdiff, + and rtag are module names (and how that differs from file/directory + names). + + * cvsclient.texi (Responses): Say that servers need to create + directories one at a time. + +Sat Apr 12 09:32:58 1997 Jim Kingdon + + * cvs.texinfo (Committing your changes): Say that editor default + is notepad (not vi) for Windows NT/95. Be more clear about what + "cvs commit" does. Add paragraph about timestamps. + (Environment variables, Global options, editinfo): + Add xrefs to that node. + +Thu Apr 10 15:48:39 1997 Jim Kingdon + + * cvs.texinfo (Error messages): Add "could not patch; will refetch". + +Wed Apr 9 15:21:11 1997 Jim Kingdon + + * cvs.texinfo (Working directory storage): New node. + + * cvs.texinfo (Error messages): Add comment about "cvs co ." on + NT. + +Tue Apr 8 14:44:26 1997 Jim Kingdon + + * cvs.texinfo (Error messages): Add diff3 usage message. + +Sun Apr 6 19:03:01 1997 Jim Kingdon + + * cvs.texinfo (Removing files): Add comment about undoing a "cvs + remove". + + * cvsclient.texi (Requests): Explicitly mention the idea of + deferring "Notify" requests. + +Tue Apr 1 07:51:38 1997 Jim Kingdon + + * cvsclient.texi (Responses): Add paragraph about directory + creation and empty directories. + + * cvs.texinfo (Binary files): Add comment about binary files and + merges. + + * cvsclient.texi (Requests): Add discussion of when to send + Is-modified. + + * cvsclient.texi (Requests): Sending Is-modified is enough to + prevent the file from being considered "lost". + +Sun Mar 30 00:31:47 1997 Jim Kingdon + + * cvsclient.texi (Requests): Add Is-modified request. Clarify + order of Entry relative to Unchanged or Is-modified (might as well + specify the same thing vis-a-vis Modified while we are at it). + +Sat Mar 29 12:32:40 1997 Jim Kingdon + + * cvsclient.texi: Change "newline" to "linefeed". Most of the + document already reads "linefeed" and that is what is intended. + (File transmissions): New node, moved here from Requests. + (Goals, Filenames, File transmissions, new node Strings): Add + discussion of character sets and what we expect from the transport + protocol we run on. + + * cvsclient.texi (Requests): Add paragraph about each Directory + request specifying a new local-directory and repository. + + * cvsclient.texi (Requests): Add paragraph about renaming + local-directory in Directory request. Use "local-directory" + consistently instead of "working directory", for clarity. + +Fri Mar 28 13:59:59 1997 Jim Kingdon + + * cvsclient.texi (Requests): Make it clear that there is no + guarantee that one will get Clear-sticky instead of another + response. Also clarify that clients will tend to store the + repository in a long-term way. + + * cvsclient.texi (Requests): Further clarify Directory example. + + * cvsclient.texi (Requests): Add example and further explanation + of what expand-modules is for. + + * cvsclient.texi (Requests): Add example, hopefully making it + clearer what REPOSITORY and LOCAL-DIRECTORY mean to Directory. + + * cvs.texinfo (Attic): New node. + (rtag options): Adjust discussion of -a accordingly. + (Repository files): Adjust accordingly. + +Thu Mar 27 09:57:05 1997 Jim Kingdon + + * cvs.texinfo (Error messages): Give exact wording of broken pipe + error message. + + * cvs.texinfo (history database): Add comment about various + problems with the history file. + + * cvs.texinfo (Common options): The ISO8601 web page we had + mentioned in a comment is no more. Replace it with a new one. + + * cvs.texinfo (Common options): "cvs history" also outputs dates. + +Wed Mar 26 10:54:21 1997 Jim Kingdon + + * cvs.texinfo (Common options): "cvs editors" also outputs dates. + + * cvs.texinfo (Outside): Fix paragraph which said that revision + numbers start at 1.0. First of all, it is 1.1. Second of all, it + is sometimes 2.1, 3.1, etc. Third of all, the xref should be to + Assigning revisions not commit options. + + * cvs.texinfo (Outside): Comment out sentence which incorrectly + stated that "cvs add" can operate on "foo/bar.c". + +Tue Mar 25 22:21:29 1997 Jim Kingdon + + * cvs.texinfo (Error messages): New node. + (Magic branch numbers): Move from Troubleshooting to Revisions and + branches. The former placement never made any sense to me. + (Revision numbers): Remove "Main trunk (intro)" index entry now + that this node is right next to the other "main trunk" index + entry. + (BUGS): Very briefly mention reporting bugs in CVS. + + * cvs.texinfo (Compatibility): Add comment about "Nfoo" in CVS/Tag. + Mon Mar 24 13:50:24 1997 Jim Kingdon * cvs.texinfo (Creating a branch): Add comment about -r in branch diff --git a/gnu/usr.bin/cvs/doc/RCSFILES b/gnu/usr.bin/cvs/doc/RCSFILES index 0ac61aa1d42..f437cfe6118 100644 --- a/gnu/usr.bin/cvs/doc/RCSFILES +++ b/gnu/usr.bin/cvs/doc/RCSFILES @@ -37,6 +37,24 @@ for more information on them. CVS also sets the RCS state to "dead" to indicate that a file does not exist in a given revision (this is stored just as any other RCS state is). +The rules regarding keyword expansion are not documented along with +the rest of the RCS file format; they are documented in the co(1) +manpage in the RCS 5.7 distribution. See also the "Keyword +substitution" chapter of cvs.texinfo. The co(1) manpage refers to +special behavior if the log prefix for the $Log keyword is /* or (*. +RCS 5.7 produces a warning whenever it behaves that way, and current +versions of CVS do not handle this case in a special way (CVS 1.9 and +earlier invoke RCS to perform keyword expansion). + +Note that the "comment {string};" syntax from rcsfile.5 specifies a +comment leader, which affects expansion of the $Log keyword for old +versions of RCS. The comment leader is not used by RCS 5.7 or current +versions of CVS. + +Both RCS 5.7 and current versions of CVS handle the $Log keyword in a +different way if the log message starts with "checked in with -k by ". +I don't think this behavior is documented anywhere. + Diff follows: (Note that in the following diff the old value for the Id keyword was: diff --git a/gnu/usr.bin/cvs/doc/cvs.texinfo b/gnu/usr.bin/cvs/doc/cvs.texinfo index 5e8e26be611..9a8be310758 100644 --- a/gnu/usr.bin/cvs/doc/cvs.texinfo +++ b/gnu/usr.bin/cvs/doc/cvs.texinfo @@ -343,7 +343,10 @@ noted by comments in the @file{cvs.texinfo} file. @cindex Errors, reporting (manual) This list is not complete. If you notice any error, omission, or something that is unclear, please send -mail to @t{bug-cvs@@prep.ai.mit.edu}. +mail to @t{bug-cvs@@prep.ai.mit.edu}. This is also the +address for reporting bugs in @sc{cvs}. +@c FIXME: There is a lot more to say on this, when we +@c get around to writing it up. @end itemize I hope that you will find this manual useful, despite @@ -721,7 +724,10 @@ you want to edit. @xref{Multiple developers}, for an explanation. @cindex EDITOR, environment variable When you have checked that the compiler is still compilable you decide -to make a new version of @file{backend.c}. +to make a new version of @file{backend.c}. This will +store your new @file{backend.c} in the repository and +make it available to anyone else who is using that same +repository. @example $ cvs commit backend.c @@ -736,8 +742,34 @@ The environment variable @code{$CVSEDITOR} determines which editor is started. If @code{$CVSEDITOR} is not set, then if the environment variable @code{$EDITOR} is set, it will be used. If both @code{$CVSEDITOR} and -@code{$EDITOR} are not set then the editor defaults to -@code{vi}. If you want to avoid the overhead of +@code{$EDITOR} are not set then there is a default +which will vary with your operating system, for example +@code{vi} for unix or @code{notepad} for Windows +NT/95. + +@c This probably should go into some new node +@c containing detailed info on the editor, rather than +@c the intro. In fact, perhaps some of the stuff with +@c CVSEDITOR and -m and so on should too. +When @sc{cvs} starts the editor, it includes a list of +files which are modified. For the @sc{cvs} client, +this list is based on comparing the modification time +of the file against the modification time that the file +had when it was last gotten or updated. Therefore, if +a file's modification time has changed but its contents +have not, it will show up as modified. The simplest +way to handle this is simply not to worry about it---if +you proceed with the commit @sc{cvs} will detect that +the contents are not modified and treat it as an +unmodified file. The next @code{update} will clue +@sc{cvs} in to the fact that the file is unmodified, +and it will reset its stored timestamp so that the file +will not show up in future editor sessions. +@c FIXCVS: Might be nice if "commit" and other commands +@c would reset that timestamp too, but currently commit +@c doesn't. + +If you want to avoid starting an editor you can specify the log message on the command line using the @samp{-m} flag instead, like this: @@ -898,6 +930,7 @@ user-defined modules. @menu * Specifying a repository:: Telling CVS where your repository is * Repository storage:: The structure of the repository +* Working directory storage:: The structure of working directories * Intro administrative files:: Defining modules * Multiple repositories:: Multiple repositories * Creating a repository:: Creating a repository @@ -942,6 +975,8 @@ CVSROOT=/usr/local/cvsroot export CVSROOT @end example +@cindex Root file, in CVS directory +@cindex CVS/Root file A repository specified with @code{-d} will override the @code{$CVSROOT} environment variable. Once you've checked a working copy out from the @@ -978,6 +1013,7 @@ the file permissions appropriate for the repository. @menu * Repository files:: What files are stored in the repository * File permissions:: File permissions +* Attic:: Some files are stored in the Attic @end menu @node Repository files @@ -1026,8 +1062,9 @@ under version control. The name of the history file is the name of the corresponding file with @samp{,v} appended to the end. Here is what the repository for the @file{yoyodyne/tc} directory might look like: -@c FIXME: Should also mention CVS (CVSREP) and Attic - +@c FIXME: Should also mention CVS (CVSREP) +@c FIXME? Should we introduce Attic with an xref to +@c Attic? Not sure whether that is a good idea or not. @example @code{$CVSROOT} | @@ -1161,6 +1198,270 @@ Since @sc{cvs} was not written to be run setuid, it is unsafe to try to run it setuid. You cannot use the setuid features of @sc{rcs} together with @sc{cvs}. +@node Attic +@subsection The attic +@cindex attic + +You will notice that sometimes @sc{cvs} stores an +@sc{rcs} file in the @code{Attic}. For example, if the +@sc{cvsroot} is @file{/usr/local/cvsroot} and we are +talking about the file @file{backend.c} in the +directory @file{yoyodyne/tc}, then the file normally +would be in + +@example +/usr/local/cvsroot/yoyodyne/tc/backend.c,v +@end example + +but if it goes in the attic, it would be in + +@example +/usr/local/cvsroot/yoyodyne/tc/Attic/backend.c,v +@end example + +@cindex dead state +instead. It should not matter from a user point of +view whether a file is in the attic; @sc{cvs} keeps +track of this and looks in the attic when it needs to. +But in case you want to know, the rule is that the RCS +file is stored in the attic if and only if the head +revision on the trunk has state @code{dead}. A +@code{dead} state means that file has been removed, or +never added, for that revision. For example, if you +add a file on a branch, it will have a trunk revision +in @code{dead} state, and a branch revision in a +non-@code{dead} state. +@c Probably should have some more concrete examples +@c here, or somewhere (not sure exactly how we should +@c arrange the discussion of the dead state, versus +@c discussion of the attic). + +@node Working directory storage +@section How data is stored in the working directory + +While we are discussing @sc{cvs} internals which may +become visible from time to time, we might as well talk +about what @sc{cvs} puts in the @file{CVS} directories +in the working directories. As with the repository, +@sc{cvs} handles this information and one can usually +access it via @sc{cvs} commands. But in some cases it +may be useful to look at it, and other programs, such +as the @code{jCVS} graphical user interface or the +@code{VC} package for emacs, may need to look at it. +Such programs should follow the recommendations in this +section if they hope to be able to work with other +programs which use those files, including future +versions of the programs just mentioned and the +command-line @sc{cvs} client. + +The @file{CVS} directory contains several files. +Programs which are reading this directory should +silently ignore files which are in the directory but +which are not documented here, to allow for future +expansion. + +@table @file +@item Root +This file contains the current @sc{cvs} root, as +described in @ref{Specifying a repository}. + +@cindex Repository file, in CVS directory +@cindex CVS/Repository file +@item Repository +This file contains the directory within the repository +which the current directory corresponds with. For +historical reasons it is an absolute pathname, although +it would make more sense for it to be relative to the +root. For example, after the command + +@example +cvs -d :local:/usr/local/cvsroot checkout yoyodyne/tc +@end example + +@file{Root} will contain + +@example +:local:/usr/local/cvsroot +@end example + +and @file{Repository} will contain + +@example +/usr/local/cvsroot/yoydyne/tc +@end example + +@cindex Entries file, in CVS directory +@cindex CVS/Entries file +@item Entries +This file lists the files and directories in the +working directory. It is a text file according to the +conventions appropriate for the operating system in +question. +@c That seems like a lose, it makes it impossible (it +@c would seem) to share a working directory via a +@c networked file system between systems with diverse +@c text file conventions. But it seems to be how CVS +@c currently works. +The first character of each line indicates what sort of +line it is. If the character is unrecognized, programs +reading the file should silently skip that line, to +allow for future expansion. + +If the first character is @samp{/}, then the format is: + +@example +/@var{name}/@var{revision}/@var{timestamp}[+@var{conflict}]/@var{options}/@var{tagdate} +@end example + +where @samp{[} and @samp{]} are not part of the entry, +but instead indicate that the @samp{+} and conflict +marker are optional. @var{name} is the name of the +file within the directory. @var{revision} is the +revision that the file in the working derives from, or +@samp{0} for an added file, or @samp{-} followed by a +revision for a removed file. @var{timestamp} is the +timestamp of the file at the time that @sc{cvs} created +it; if the timestamp differs with the actual +modification time of the file it means the file has +been modified. @var{conflict} indicates that there was +a conflict; if it is the same as the actual +modification time of the file it means that the user +has obviously not resolved the conflict. @var{options} +contains sticky options (for example @samp{-kb} for a +binary file). @var{tagdate} contains @samp{T} followed +by a tag name, or @samp{D} for a date, followed by a +sticky tag or date. Note that if @var{timestamp} +contains a pair of timestamps separated by a space, +rather than a single timestamp, you are dealing with a +version of @sc{cvs} earlier than @sc{cvs} 1.5 (not +documented here). + +If the first character of a line in @file{Entries} is +@samp{D}, then it indicates a subdirectory. @samp{D} +on a line all by itself indicates that the program +which wrote the @file{Entries} file does record +subdirectories (therefore, if there is such a line and +no other lines beginning with @samp{D}, one knows there +are no subdirectories). Otherwise, the line looks +like: + +@example +D/@var{name}/@var{filler1}/@var{filler2}/@var{filler3}/@var{filler4} +@end example + +where @var{name} is the name of the subdirectory, and +all the @var{filler} fields should be silently ignored, +for future expansion. Programs which modify +@code{Entries} files should preserve these fields. + +@cindex Entries.Log file, in CVS directory +@cindex CVS/Entries.Log file +@item Entries.Log +This file does not record any information beyond that +in @file{Entries}, but it does provide a way to update +the information without having to rewrite the entire +@file{Entries} file, including the ability to preserve +the information even if the program writing +@file{Entries} and @file{Entries.Log} abruptly aborts. +The format of a line in @file{Entries.Log} is a single +character command followed by a space followed by a +line in the format specified for a line in +@file{Entries}. The single character command is +@samp{A} to indicate that the entry is being added, +@samp{R} to indicate that the entry is being removed, +or any other character to indicate that the entire line +in @file{Entries.Log} should be silently ignored (for +future expansion). If the second character of the line +in @file{Entries.Log} is not a space, then it was +written by an older version of @sc{cvs} (not documented +here). + +@cindex Entries.Backup file, in CVS directory +@cindex CVS/Entries.Backup file +@item Entries.Backup +This is a temporary file. Recommended usage is to +write a new entries file to @file{Entries.Backup}, and +then to rename it (atomically, where possible) to @file{Entries}. + +@cindex Entries.Static file, in CVS directory +@cindex CVS/Entries.Static file +@item Entries.Static +The only relevant thing about this file is whether it +exists or not. If it exists, then it means that only +part of a directory was gotten and @sc{cvs} will +not create additional files in that directory. To +clear it, use the @code{update} command with the +@samp{-d} option, which will get the additional files +and remove @file{Entries.Static}. + +@cindex Tag file, in CVS directory +@cindex CVS/Tag file +@cindex Sticky tags/dates, per-directory +@cindex Per-directory sticky tags/dates +@item Tag +This file contains per-directory sticky tags or dates. +The first character is @samp{T} for a branch tag, +@samp{N} for a non-branch tag, or @samp{D} for a date, +or another character to mean the file should be +silently ignored, for future expansion. This character +is followed by the tag or date. Note that +per-directory sticky tags or dates are used for things +like applying to files which are newly added; they +might not be the same as the sticky tags or dates on +individual files. For general information on sticky +tags and dates, see @ref{Sticky tags}. +@c FIXME: This needs to be much better documented, +@c preferably not in the context of "working directory +@c storage". +@c FIXME: The Sticky tags node needs to discuss, or xref to +@c someplace which discusses, per-directory sticky +@c tags and the distinction with per-file sticky tags. + +@cindex Checkin.prog file, in CVS directory +@cindex CVS/Checkin.prog file +@cindex Update.prog file, in CVS directory +@cindex CVS/Update.prog file +@item Checkin.prog +@itemx Update.prog +These files store the programs specified by the +@samp{-i} and @samp{-u} options in the modules file, +respectively. + +@cindex Notify file, in CVS directory +@cindex CVS/Notify file +@item Notify +This file stores notifications (for example, for +@code{edit} or @code{unedit}) which have not yet been +sent to the server. Its format is not yet documented +here. + +@cindex Notify.tmp file, in CVS directory +@cindex CVS/Notify.tmp file +@item Notify.tmp +This file is to @file{Notify} as @file{Entries.Backup} +is to @file{Entries}. That is, to write @file{Notify}, +first write the new contents to @file{Notify.tmp} and +then (atomically where possible), rename it to +@file{Notify}. + +@cindex Base directory, in CVS directory +@cindex CVS/Base directory +@item Base +If watches are in use, then an @code{edit} command +stores the original copy of the file in the @file{Base} +directory. This allows the @code{unedit} command to +operate even if it is unable to communicate with the +server. + +@cindex Template file, in CVS directory +@cindex CVS/Template file +@item Template +This file contains the template specified by the +@file{rcsinfo} file (@pxref{rcsinfo}). It is only used +by the client; the non-client/server @sc{cvs} consults +@file{rcsinfo} directly. +@end table + @c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @node Intro administrative files @section The administrative files @@ -1263,7 +1564,9 @@ thinking of setting up several repositories on the same machine, you might want to consider using several directories within the same repository. @c FIXCVS: the thing about recursing into diverse roots -@c would be nice to fix. +@c would be nice to fix. But it gets hairy if they are +@c on diverse servers--it isn't clear this is really +@c all that useful. @c FIXME: Does the FAQ have more about this? I have a @c dim recollection, but I'm too lazy to check right now. @@ -2078,6 +2381,18 @@ Note: you must run it on a machine which has both else in contrib it is unsupported (your mileage may vary). @end table +@c CMZ and/or PATCHY were systems that were used in the +@c high energy physics community (especially for +@c CERNLIB). CERN has replaced them with CVS, but the +@c CAR format seems to live on as a way to submit +@c changes. There is a program car2cvs which converts +@c but I'm not sure where one gets a copy. +@c Not sure it is worth mentioning here, since it would +@c appear to affect only one particular community. +@c Best page for more information is: +@c http://wwwcn1.cern.ch/asd/cvs/index.html +@c See also: +@c http://ecponion.cern.ch/ecpsa/cernlib.html @c . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . @node From scratch @@ -3177,6 +3492,7 @@ ability to make branches on the revision tree. * Branches motivation:: What branches are good for * Creating a branch:: Creating a branch * Sticky tags:: Sticky tags +* Magic branch numbers:: Magic branch numbers @end menu @c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -3187,7 +3503,6 @@ ability to make branches on the revision tree. @cindex Linear development @cindex Number, revision- @cindex Decimal revision number -@cindex Main trunk (intro) @cindex Branch number @cindex Number, branch @@ -3322,14 +3637,14 @@ provide a better way to distinguish between things like release 1 versus release 2 of your product (@pxref{Tags}). However, if you want to set the numeric revisions, the @samp{-r} option to @code{cvs -commit} can do that. +commit} can do that. The @samp{-r} option implies the +@samp{-f} option, in the sense that it causes the +files to be committed even if they are not modified. -For example, to bring all your files up to the @sc{rcs} +For example, to bring all your files up to revision 3.0 (including those that haven't changed), you might invoke: -@c Why does this not require -f to get the "those that -@c haven't changed" part? That isn't clear to me. @example $ cvs commit -r 3.0 @end example @@ -3724,6 +4039,73 @@ done $ @end example +@c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +@node Magic branch numbers +@section Magic branch numbers + +@c Want xref to here from "log" and "admin"? + +This section describes a @sc{cvs} feature called +@dfn{magic branches}. For most purposes, you need not +worry about magic branches; @sc{cvs} handles them for +you. However, they are visible to you in certain +circumstances, so it may be useful to have some idea of +how it works. + +Externally, branch numbers consist of an odd number of +dot-separated decimal integers. @xref{Revision +numbers}. That is not the whole truth, however. For +efficiency reasons @sc{cvs} sometimes inserts an extra 0 +in the second rightmost position (1.2.3 becomes +1.2.0.3, 8.9.10.11.12 becomes 8.9.10.11.0.12 and so +on). + +@sc{cvs} does a pretty good job at hiding these so +called magic branches, but in a few places the hiding +is incomplete: + +@itemize @bullet +@ignore +@c This is in ignore as I'm taking their word for it, +@c that this was fixed +@c a long time ago. But before deleting this +@c entirely, I'd rather verify it (and add a test +@c case to the testsuite). +@item +The magic branch can appear in the output from +@code{cvs status} in vanilla @sc{cvs} 1.3. This is +fixed in @sc{cvs} 1.3-s2. + +@end ignore +@item +The magic branch number appears in the output from +@code{cvs log}. +@c What output should appear instead? + +@item +You cannot specify a symbolic branch name to @code{cvs +admin}. + +@end itemize + +@c Can CVS do this automatically the first time +@c you check something in to that branch? Should +@c it? +You can use the @code{admin} command to reassign a +symbolic name to a branch the way @sc{rcs} expects it +to be. If @code{R4patches} is assigned to the branch +1.4.2 (magic branch number 1.4.0.2) in file +@file{numbers.c} you can do this: + +@example +$ cvs admin -NR4patches:1.4.2 numbers.c +@end example + +It only works if at least one revision is already +committed on the branch. Be very careful so that you +do not assign the tag to the wrong number. (There is +no way to see how the tag was assigned yesterday). + @c --------------------------------------------------------------------- @node Merging @chapter Merging @@ -4183,6 +4565,10 @@ cvs commit: Committing . If you change your mind you can easily resurrect the file before you commit it, using the @code{add} command. +@c FIXME: what if you change your mind after you commit +@c it? (answer is also "cvs add" but we don't say that...). +@c We need some index entries for thinks like "undoing +@c removal" too. @example $ ls @@ -4441,8 +4827,11 @@ The examples below assume that the file @var{old} is renamed to The normal way to move a file is to copy @var{old} to @var{new}, and then issue the normal @sc{cvs} commands to remove @var{old} from the repository, and add -@var{new} to it. (Both @var{old} and @var{new} could -contain relative paths, for example @file{foo/bar.c}). +@var{new} to it. +@c The following sentence is not true: one must cd into +@c the directory to run "cvs add". +@c (Both @var{old} and @var{new} could +@c contain relative paths, for example @file{foo/bar.c}). @example $ mv @var{old} @var{new} @@ -4460,8 +4849,9 @@ portion of the history you are accessing. For example, time of the rename. When @var{new} is committed its revision numbers will -start at 1.0 again, so if that bothers you, use the -@samp{-r rev} option to commit (@pxref{commit options}) +start again, usually at 1.1, so if that bothers you, +use the @samp{-r rev} option to commit. For more +information see @ref{Assigning revisions}. @c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @node Inside @@ -4557,10 +4947,18 @@ Disadvantages: @item You cannot easily see the history of the file across the rename. +@ignore +@c Is this true? I don't see how the revision numbers +@c _could_ start over, when new,v is just old,v with +@c the tags deleted. +@c If there is some need to reinstate this text, +@c it is "usually 1.1", not "1.0" and it needs an +@c xref to Assigning revisions @item Unless you use the @samp{-r rev} (@pxref{commit options}) flag when @var{new} is committed its revision numbers will start at 1.0 again. +@end ignore @end itemize @c --------------------------------------------------------------------- @@ -4713,6 +5111,63 @@ You can use the history file (@pxref{history file}) to log various @sc{cvs} actions. To retrieve the information from the history file, use the @code{cvs history} command (@pxref{history}). +@c +@c The history database has many problems: +@c * It is very unclear what field means what. This +@c could be improved greatly by better documentation, +@c but there are still non-orthogonalities (for +@c example, tag does not record the "repository" +@c field but most records do). +@c * Confusion about files, directories, and modules. +@c Some commands record one, some record others. +@c * File removal is not logged. There is an 'R' +@c record type documented, but CVS never uses it. +@c * Tags are only logged for the "cvs rtag" command, +@c not "cvs tag". The fix for this is not completely +@c clear (see above about modules vs. files). +@c * Are there other cases of operations that are not +@c logged? One would hope for all changes to the +@c repository to be logged somehow (particularly +@c operations like tagging, "cvs admin -k", and other +@c operations which do not record a history that one +@c can get with "cvs log"). Operations on the working +@c directory, like export, get, and release, are a +@c second category also covered by the current "cvs +@c history". +@c * The history file does not record the options given +@c to a command. The most serious manifestation of +@c this is perhaps that it doesn't record whether a command +@c was recursive. It is not clear to me whether one +@c wants to log at a level very close to the command +@c line, as a sort of way of logging each command +@c (more or less), or whether one wants +@c to log more at the level of what was changed (or +@c something in between), but either way the current +@c information has pretty big gaps. +@c * Further details about a tag--like whether it is a +@c branch tag or, if a non-branch tag, which branch it +@c is on. One can find out this information about the +@c tag as it exists _now_, but if the tag has been +@c moved, one doesn't know what it was like at the time +@c the history record was written. +@c * Whether operating on a particular tag, date, or +@c options was implicit (sticky) or explicit. +@c +@c Another item, only somewhat related to the above, is a +@c way to control what is logged in the history file. +@c This is probably the only good way to handle +@c different people having different ideas about +@c information/space tradeoffs. +@c +@c It isn't really clear that it makes sense to try to +@c patch up the history file format as it exists now to +@c include all that stuff. It might be better to +@c design a whole new CVSROOT/nhistory file and "cvs +@c nhistory" command, or some such, or in some other +@c way trying to come up with a clean break from the +@c past, which can address the above concerns. Another +@c open question is how/whether this relates to +@c taginfo/loginfo/etc. @c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @node user-defined logging @@ -5122,6 +5577,10 @@ contain data which looks like a keyword (@pxref{Keyword substitution}), so keyword expansion must be turned off. +@c FIXME: the third is that one can't do merges with +@c binary files. xref to Multiple Developers and the +@c reserved checkout issues. + The @samp{-kb} option available with some @sc{cvs} commands insures that neither line ending conversion nor keyword expansion will be done. If you are using @@ -5321,6 +5780,11 @@ to use the optional developer communication features. @c section (for repository & working directory) from the @c rest--that might help avoid confusing people who @c are upgrading (for example) from 1.6 to 1.8. +@c +@c A minor incompatibility is if a current version of CVS +@c puts "Nfoo" into CVS/Tag, then CVS 1.9 or older will +@c see this as if there is no tag. Seems to me this is +@c too obscure to mention. The working directory format is compatible going back to @sc{cvs} 1.5. It did change between @sc{cvs} 1.3 @@ -5570,7 +6034,9 @@ the @code{$CVSROOT} environment variable. @xref{Repository}. @cindex Overriding EDITOR @item -e @var{editor} Use @var{editor} to enter revision log information. Overrides the -setting of the @code{$CVSEDITOR} and @code{$EDITOR} environment variables. +setting of the @code{$CVSEDITOR} and @code{$EDITOR} +environment variables. For more information, see +@ref{Committing your changes}. @item -f Do not read the @file{~/.cvsrc} file. This @@ -5741,6 +6207,10 @@ slightly different way; @pxref{history options}). @c ISO 1996-06-11 02:54:53 @c note: date possibly should be omitted entirely for @c other reasons. +@c cvs editors +@c current Tue Jun 11 02:54:53 1996 GMT +@c cvs history +@c current 06/11 02:54 +0000 @c any others? @c There is a good chance the proper solution has to @c involve at least some level of letting the user @@ -5796,7 +6266,7 @@ See for more details about ISO8601 dates. @c Perhaps we want to also cite other sources in @c case that page goes away. For example: -@c http://www.dsi.unimi.it/Users/Students/pensa/standard/ISO8601.html +@c http://www.saqqara.demon.co.uk/datefmt.htm In addition to the dates allowed in Internet e-mail itself, @sc{cvs} also allows some of the fields to be @@ -7806,15 +8276,10 @@ are available: @table @code @item -a -@c FIXME: What is an "Attic"? And what does this -@c option mean in terms of user concepts, not CVS -@c internals? -@c FIXME-also: Need to explain attic somewhere, since -@c it appears in user messages. Should clarify that -@c whether a file is in the attic is not something users -@c should worry about. Need index entry for "attic". +@c FIXME: What does this option mean in terms of user +@c concepts, not CVS internals? Use the @samp{-a} option to have @code{rtag} look in the -@file{Attic} (@pxref{Removing files}) for removed files +@file{Attic} (@pxref{Attic}) for removed files that contain the specified tag. The tag is removed from these files, which makes it convenient to re-use a symbolic tag as development continues (and files get @@ -9545,8 +10010,7 @@ file, the editor specified in the environment variable @code{$CVSEDITOR} is used instead. If that variable is not set, then the environment variable @code{$EDITOR} is used instead. If that variable is not -set a precompiled default, normally @code{vi}, will be -used. +set a default will be used. See @ref{Committing your changes}. The @file{editinfo} file is often most useful together with the @file{rcsinfo} file, which can be used to @@ -10077,9 +10541,8 @@ directory. @item $EDITOR @itemx $CVSEDITOR Specifies the program to use for recording log messages -during commit. If not set, the default is -@samp{/usr/ucb/vi}. @code{$CVSEDITOR} overrides -@code{$EDITOR}. +during commit. @code{$CVSEDITOR} overrides +@code{$EDITOR}. See @ref{Committing your changes}. @cindex PATH @item $PATH @@ -10215,7 +10678,7 @@ argument lists of most @sc{rcs} commands. @appendix Troubleshooting @menu -* Magic branch numbers:: Magic branch numbers +* Error messages:: Partial list of CVS errors @end menu @ignore @@ -10226,67 +10689,149 @@ argument lists of most @sc{rcs} commands. @c -- Give hints on how to fix them @end ignore -@c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -@node Magic branch numbers -@appendixsec Magic branch numbers - -@c Where does this go? I think probably in with -@c the details of where things are stored in the -@c repository (plus an xref from "log" and "admin"). - -Externally, branch numbers consist of an odd number of -dot-separated decimal integers. @xref{Revision -numbers}. That is not the whole truth, however. For -efficiency reasons @sc{cvs} sometimes inserts an extra 0 -in the second rightmost position (1.2.3 becomes -1.2.0.3, 8.9.10.11.12 becomes 8.9.10.11.0.12 and so -on). - -@sc{cvs} does a pretty good job at hiding these so -called magic branches, but in a few places the hiding -is incomplete: - -@itemize @bullet -@ignore -@c This is in ignore as I'm taking their word for it, -@c that this was fixed -@c a long time ago. But before deleting this -@c entirely, I'd rather verify it (and add a test -@c case to the testsuite). -@item -The magic branch can appear in the output from -@code{cvs status} in vanilla @sc{cvs} 1.3. This is -fixed in @sc{cvs} 1.3-s2. +@node Error messages +@appendixsec Partial list of error messages -@end ignore -@item -The magic branch number appears in the output from -@code{cvs log}. -@c What output should appear instead? +Here is a partial list of error messages that you may +see from @sc{cvs}. It is not a complete list---@sc{cvs} +is capable of printing many, many error messages, often +with parts of them supplied by the operating system, +but the intention is to list the common and/or +potentially confusing error messages. -@item -You cannot specify a symbolic branch name to @code{cvs -admin}. +The messages are alphabetical, but introductory text +such as @samp{cvs update: } is not considered in +ordering them. -@end itemize +In some cases the list includes messages printed by old +versions of @sc{cvs} (partly because users may not be +sure which version of @sc{cvs} they are using at any +particular moment). -@c Can CVS do this automatically the first time -@c you check something in to that branch? Should -@c it? -You can use the @code{admin} command to reassign a -symbolic name to a branch the way @sc{rcs} expects it -to be. If @code{R4patches} is assigned to the branch -1.4.2 (magic branch number 1.4.0.2) in file -@file{numbers.c} you can do this: +@table @code +@item cvs [server aborted]: received broken pipe signal +This message seems to be caused by a hard-to-track-down +bug in @sc{cvs} or the systems it runs on (we don't +know---we haven't tracked it down yet!). It seems to +happen only after a @sc{cvs} command has completed, and +you should be able to just ignore the message. +However, if you have discovered information concerning its +cause, please let us know as described in @ref{BUGS}. + +@c For one example see basica-1a10 in the testsuite +@c For another example, "cvs co ." on NT; see comment +@c at windows-NT/filesubr.c (expand_wild). +@item cannot open CVS/Entries for reading: No such file or directory +This generally indicates a @sc{cvs} internal error, and +can be handled as with other @sc{cvs} bugs +(@pxref{BUGS}). Usually there is a workaround---the +exact nature of which would depend on the situation but +which hopefully could be figured out. + +@item cvs [update aborted]: could not patch @var{file}: No such file or directory +This means that there was a problem finding the +@code{patch} program. Make sure that it is in your +@code{PATH}. Note that despite appearances the message +is @emph{not} referring to whether it can find @var{file}. +@c Future versions of @sc{cvs} are +@c expected to dispense with the need for an external +@c patch program, but might as well not advertise +@c vaporware. +@c Even after that change is made, probably want to +@c preserve this message, see above about old messages. + +@item cvs update: could not patch @var{file}; will refetch +This means that for whatever reason the client was +unable to apply a patch that the server sent. The +message is nothing to be concerned about, because +inability to apply the patch only slows things down and +has no effect on what @sc{cvs} does. +@c xref to update output. Or File status? +@c Or some place else that +@c explains this whole "patch"/P/Needs Patch thing? + +@item dying gasps from @var{server} unexpected +This message seems to be caused by a hard-to-track-down +bug in @sc{cvs} or the systems it runs on (we don't +know---we haven't tracked it down yet!). If you see it, +you probably can just retry the operation which failed, +or if you have discovered information concerning its +cause, please let us know as described in @ref{BUGS}. + +@item end of file from server (consult above messages if any) +The most common cause for this message is if you are +using an external @code{rsh} program and it exited with +an error. In this case the @code{rsh} program should +have printed a message, which will appear before the +above message. For more information on setting up a +@sc{cvs} client and server, see @ref{Remote repositories}. + +@cindex mkmodules +@item cvs commit: Executing 'mkmodules' +This means that your repository is set up for a version +of @sc{cvs} prior to @sc{cvs} 1.8. When using @sc{cvs} +1.8 or later, the above message will be preceded by + +@example +cvs commit: Rebuilding administrative file database +@end example + +If you see both messages, the database is being rebuilt +twice, which is unnecessary but harmless. If you wish +to avoid the duplication, and you have no versions of +@sc{cvs} 1.7 or earlier in use, remove @code{-i mkmodules} +every place it appears in your @code{modules} +file. For more information on the @code{modules} file, +see @ref{modules}. + +@item cvs commit: Up-to-date check failed for `@var{file}' +This means that someone else has committed a change to +that file since the last time that you did a @code{cvs +update}. So before proceeding with your @code{cvs +commit} you need to @code{cvs update}. CVS will merge +the changes that you made and the changes that the +other person made. If it does not detect any conflicts +it will report @samp{M cacErrCodes.h} and you are ready +to @code{cvs commit}. If it detects conflicts it will +print a message saying so, will report @samp{C cacErrCodes.h}, +and you need to manually resolve the +conflict. For more details on this process see +@ref{Conflicts example}. + +@item Usage: diff3 [-exEX3 [-i | -m] [-L label1 -L label3]] file1 file2 file3 +@example +Only one of [exEX3] allowed +@end example +This indicates a problem with the installation of +@code{diff3} and @code{rcsmerge}. Specifically +@code{rcsmerge} was compiled to look for GNU diff3, but +it is finding unix diff3 instead. The exact text of +the message will vary depending on the system. The +solution is to make sure @code{rcsmerge} finds GNU +diff3. Depending on how @code{rcsmerge} was compiled, +it might be sufficient to place GNU diff3 in your +@code{PATH}, or it might be necessary to recompile +@code{rcsmerge} or find a binary distribution of +@code{rcsmerge} which looks in the @code{PATH}. +@c Should we mention the cvsaux binaries here? + +@item cvs commit: warning: editor session failed +This means that the editor which @sc{cvs} is using exits with a nonzero +exit status. Some versions of vi will do this even when there was not +a problem editing the file. If so, point the +@sc{CVSEDITOR} environment variable to a small script +such as: @example -$ cvs admin -NR4patches:1.4.2 numbers.c +#!/bin/sh +vi $* +exit 0 @end example -It only works if at least one revision is already -committed on the branch. Be very careful so that you -do not assign the tag to the wrong number. (There is -no way to see how the tag was assigned yesterday). +@c "warning: foo was lost" and "no longer pertinent" (both normal). +@c Would be nice to write these up--they are +@c potentially confusing for the new user. +@end table @c --------------------------------------------------------------------- @node Copying diff --git a/gnu/usr.bin/cvs/doc/cvsclient.texi b/gnu/usr.bin/cvs/doc/cvsclient.texi index 7feee6c6a90..a95dc68c04e 100644 --- a/gnu/usr.bin/cvs/doc/cvsclient.texi +++ b/gnu/usr.bin/cvs/doc/cvsclient.texi @@ -74,8 +74,16 @@ Do not assume any access to the repository other than via this protocol. It does not depend on NFS, rdist, etc. @item -Providing a reliable transport is outside this protocol. It is expected -that it runs over TCP, UUCP, etc. +Providing a reliable transport is outside this protocol. The protocol +expects a reliable transport that is transparent (that is, there is no +translation of characters, including characters such as such as +linefeeds or carriage returns), and can transmit all 256 octets (for +example for proper handling of binary files, compression, and +encryption). The encoding of characters specified by the protocol (the +names of requests and so on) is the invariant ISO 646 character set (a +subset of most popular character sets including ASCII and others). For +more details on running the protocol over the TCP reliable transport, +see @ref{Connection and Authentication}. @item Security and authentication are handled outside this protocol (but see @@ -202,6 +210,8 @@ to a horizontal tab. * Entries Lines:: * Modes:: * Filenames:: Conventions regarding filenames +* File transmissions:: How file contents are transmitted +* Strings:: Strings in various requests and responses * Requests:: * Responses:: * Example:: @@ -282,18 +292,21 @@ the same answer (and what to do if future server ports are operating on a repository like e:/foo or CVS_ROOT:[FOO.BAR] has not been carefully thought out). -@node Requests -@section Requests +Characters outside the invariant ISO 646 character set should be avoided +in filenames. This restriction may need to be relaxed to allow for +characters such as @samp{[} and @samp{]} (see above about non-unix +servers); this has not been carefully considered (and currently +implementations probably use whatever character sets that the operating +systems they are running on allow, and/or that users specify). Of +course the most portable practice is to restrict oneself further, to the +POSIX portable filename character set as specified in POSIX.1. -By convention, requests which begin with a capital letter do not elicit -a response from the server, while all others do -- save one. The -exception is @samp{gzip-file-contents}. Unrecognized requests will -always elicit a response from the server, even if that request begins -with a capital letter. +@node File transmissions +@section File transmissions File contents (noted below as @var{file transmission}) can be sent in one of two forms. The simpler form is a number of bytes, followed by a -newline, followed by the specified number of bytes of file contents. +linefeed, followed by the specified number of bytes of file contents. These are the entire contents of the specified file. Second, if both client and server support @samp{gzip-file-contents}, a @samp{z} may precede the length, and the `file contents' sent are actually compressed @@ -301,8 +314,42 @@ with @samp{gzip} (RFC1952/1951) compression. The length specified is that of the compressed version of the file. In neither case are the file content followed by any additional data. -The transmission of a file will end with a newline iff that file (or its -compressed form) ends with a newline. +The transmission of a file will end with a linefeed iff that file (or its +compressed form) ends with a linefeed. + +The encoding of file contents depends on the value for the @samp{-k} +option. If the file is binary (as specified by the @samp{-kb} option in +the appropriate place), then it is just a certain number of octets, and +the protocol contributes nothing towards determining the encoding (using +the file name is one widespread, if not universally popular, mechanism). +If the file is text (not binary), then the file is sent as a series of +lines, separated by linefeeds. If the keyword expansion is set to +something other than @samp{-ko}, then it is expected that the file +conform to the RCS expectations regarding keyword expansion---in +particular, that it is in a character set such as ASCII in which 0x24 is +a dollar sign (@samp{$}). + +@node Strings +@section Strings + +In various contexts, for example the @code{Argument} request and the +@code{M} response, one transmits what is essentially an arbitrary +string. Often this will have been supplied by the user (for example, +the @samp{-m} option to the @code{ci} request). The protocol has no +mechanism to specify the character set of such strings; it would be +fairly safe to stick to the invariant ISO 646 character set but the +existing practice is probably to just transmit whatever the user +specifies, and hope that everyone involved agrees which character set is +in use, or sticks to a common subset. + +@node Requests +@section Requests + +By convention, requests which begin with a capital letter do not elicit +a response from the server, while all others do -- save one. The +exception is @samp{gzip-file-contents}. Unrecognized requests will +always elicit a response from the server, even if that request begins +with a capital letter. @table @code @item Root @var{pathname} \n @@ -339,6 +386,65 @@ the top level at which the command is occurring (i.e. the last to indicate that top level, @samp{.} should be send for @var{local-directory}. +Here is an example of where a client gets @var{repository} and +@var{local-directory}. Suppose that there is a module defined by + +@example +moddir 1dir +@end example + +That is, one can check out @code{moddir} and it will take @code{1dir} in +the repository and check it out to @code{moddir} in the working +directory. Then an initial check out could proceed like this: + +@example +C: Root /home/kingdon/zwork/cvsroot +. . . +C: Argument moddir +C: Directory . +C: /home/kingdon/zwork/cvsroot +C: co +S: Clear-sticky moddir/ +S: /home/kingdon/zwork/cvsroot/1dir/ +. . . +S: ok +@end example + +In this example the response shown is @code{Clear-sticky}, but it could +be another response instead. Note that it returns two pathnames. +The first one, @file{moddir/}, indicates the working +directory to check out into. The second one, ending in @file{1dir/}, +indicates the directory to pass back to the server in a subsequent +@code{Directory} request. For example, a subsequent @code{update} +request might look like: + +@example +C: Directory moddir +C: /home/kingdon/zwork/cvsroot/1dir +. . . +C: update +@end example + +For a given @var{local-directory}, the repository will be the same for +each of the responses, so one can use the repository from whichever +response is most convenient. Typically a client will store the +repository along with the sources for each @var{local-directory}, use +that same setting whenever operating on that @var{local-directory}, and +not update the setting as long as the @var{local-directory} exists. + +A client is free to rename a @var{local-directory} at any time (for +example, in response to an explicit user request). While it is true +that the server supplies a @var{local-directory} to the client, as noted +above, this is only the default place to put the directory. Of course, +the various @code{Directory} requests for a single command (for example, +@code{update} or @code{ci} request) should name a particular directory +with the same @var{local-directory}. + +Each @code{Directory} request specifies a brand-new +@var{local-directory} and @var{repository}; that is, +@var{local-directory} and @var{repository} are never relative to paths +specified in any previous @code{Directory} request. + @item Max-dotdot @var{level} \n Response expected: no. Tell the server that @var{level} levels of directories above the @@ -382,8 +488,13 @@ local machine. The name in @var{entry-line} is a name relative to the directory most recently specified with @code{Directory}. If the user is operating on only some files in a directory, @code{Entry} requests for only those files need be included. If an @code{Entry} request is -sent without @code{Modified} or @code{Unchanged}, it means the file is -lost (does not exist in the working directory). +sent without @code{Modified}, @code{Is-modified}, or @code{Unchanged}, +it means the file is +lost (does not exist in the working directory). If both @code{Entry} +and one of @code{Modified}, @code{Is-modified}, or @code{Unchanged} are +sent for the same file, @code{Entry} must be sent first. For a +given file, one can send @code{Modified}, @code{Is-modified}, or +@code{Unchanged}, but not more than one of these three. @item Modified @var{filename} \n Response expected: no. Additional data: mode, \n, file transmission. @@ -393,6 +504,41 @@ the user is operating on only some files in a directory, only those files need to be included. This can also be sent without @code{Entry}, if there is no entry for the file. +@item Is-modified @var{filename} \n +Response expected: no. Additional data: none. Like @code{Modified}, +but used if the server only needs +to know whether the file is modified, not the contents. + +The commands which can take @code{Is-modified} instead of +@code{Modified} with no known change in behavior are: @code{admin}, +@code{diff} (if and only if two @samp{-r} or @samp{-D} options are +specified), @code{watch-on}, @code{watch-off}, @code{watch-add}, +@code{watch-remove}, @code{watchers}, @code{editors}, +@code{log}, and @code{annotate}. + +For the @code{status} command, one can send @code{Is-modified} but if +the client is using imperfect mechanisms such a timestamps to determine +whether to consider a file modified, then the behavior will be +different. That is, if one sends @code{Modified}, then the server will +actually compare the contents of the file sent and the one it derives +from to determine whether the file is genuinely modified. But if one +sends @code{Is-modified}, then the server takes the client's word for +it. A similar situation exists for @code{tag}, if the @samp{-c} option +is specified. + +Commands for which @code{Modified} is necessary are @code{co}, +@code{ci}, @code{update}, and @code{import}. + +Commands which do not need to inform the server about a working +directory, and thus should not be sending either @code{Modified} or +@code{Is-modified}: @code{rdiff}, @code{rtag}, @code{history}, +@code{init}, and @code{release}. + +Commands for which further investigation is warranted are: +@code{remove}, @code{add}, and @code{export}. Pending such +investigation, the more conservative course of action is to stick to +@code{Modified}. + @item Unchanged @var{filename} \n Response expected: no. Tell the server that @var{filename} has not been modified in the checked out directory. The name is relative to the most @@ -413,13 +559,30 @@ responses. Response expected: no. Additional data: @var{notification-type} \t @var{time} \t @var{clienthost} \t @var{working-dir} \t @var{watches} \n @end example -where @var{notification-type} is @samp{E} for edit or @samp{U} for -unedit, @var{time} is the time at which the edit or unedit took place, +where @var{notification-type} is @samp{E} for edit, @samp{U} for +unedit, undefined behavior if @samp{C}, and all other letters should be +silently ignored for future expansion. +@var{time} is the time at which the edit or unedit took place, in a +user-readable format of the client's choice (the server should treat the +time as an opaque string rather than interpreting it). +@c Might be useful to specify a format, but I don't know if we want to +@c specify the status quo (ISO C asctime() format plus timezone) without +@c offering the option of ISO8601 and/or RFC822/1123 (see cvs.texinfo +@c for much much more on date formats). @var{clienthost} is the name of the host on which the edit or unedit took place, and @var{working-dir} is the pathname of the working directory where the edit or unedit took place. @var{watches} are the -temporary watches to set; if it is followed by \t then the tab and the -rest of the line are ignored. +temporary watches to set. If @var{watches} is followed by \t then the +\t and the rest of the line should be ignored, for future expansion. + +Note that a client may be capable of performing an @code{edit} or +@code{unedit} operation without connecting to the server at that time, +and instead connecting to the server when it is convenient (for example, +when a laptop is on the net again) to send the @code{Notify} requests. +Even if a client is capable of deferring notifications, it should +attempt to send them immediately (one can send @code{Notify} requests +together with a @code{noop} request, for example), unless perhaps if +it can know that a connection would be impossible. @item Questionable @var{filename} \n Response expected: no. Additional data: no. Tell the server to check @@ -498,16 +661,58 @@ that the server can assume that this is checkout or export, not rtag or rdiff; the latter do not access the working directory and thus have no need to expand modules on the client side. -@item co \n -@itemx ci \n +Expand may not be the best word for what this request does. It does not +necessarily tell you all the files contained in a module, for example. +Basically it is a way of telling you which working directories the +server needs to know about in order to handle a checkout of the +specified modules. + +For example, suppose that the server has a module defined by + +@example +aliasmodule -a 1dir +@end example + +That is, one can check out @code{aliasmodule} and it will take +@code{1dir} in the repository and check it out to @code{1dir} in the +working directory. Now suppose the client already has this module +checked out and is planning on using the @code{co} request to update it. +Without using @code{expand-modules}, the client would have two bad +choices: it could either send information about @emph{all} working +directories under the current directory, which could be unnecessarily +slow, or it could be ignorant of the fact that @code{aliasmodule} stands +for @code{1dir}, and neglect to send information for @code{1dir}, which +would lead to incorrect operation. +@c Those don't really seem like the only two options. I mean, what +@c about keeping track of the correspondence from when we first checked +@c out a fresh directory? Not that the CVS client does this, or that +@c I've really thought about whether it would be a good idea... + +With @code{expand-modules}, the client would first ask for the module to +be expanded: + +@example +C: Root /home/kingdon/zwork/cvsroot +. . . +C: Argument aliasmodule +C: Directory . +C: /home/kingdon/zwork/cvsroot +C: expand-modules +S: Module-expansion 1dir +S: ok +@end example + +and then it knows to check the @file{1dir} directory and send +requests such as @code{Entry} and @code{Modified} for the files in that +directory. + +@item ci \n @itemx diff \n @itemx tag \n @itemx status \n @itemx log \n @itemx add \n @itemx remove \n -@itemx rdiff \n -@itemx rtag \n @itemx admin \n @itemx export \n @itemx history \n @@ -522,13 +727,30 @@ of the operation. No provision is made for any input from the user. This means that @code{ci} must use a @code{-m} argument if it wants to specify a log message. -@itemx init @var{root-name} \n +@item co \n +Response expected: yes. Get files from the repository. This uses any +previous @code{Argument}, @code{Directory}, @code{Entry}, or +@code{Modified} requests, if they have been sent. Arguments to this +command are module names; the client cannot know what directories they +correspond to except by (1) just sending the @code{co} request, and then +seeing what directory names the server sends back in its responses, and +(2) the @code{expand-modules} request. + +@item rdiff \n +@itemx rtag \n +Response expected: yes. Actually do a cvs command. This uses any +previous @code{Argument} requests, if they have been sent. The client +should not send @code{Directory}, @code{Entry}, or @code{Modified} +requests for this command; they are not used. Arguments to these +commands are module names, as described for @code{co}. + +@item init @var{root-name} \n Response expected: yes. If it doesn't already exist, create a @sc{cvs} repository @var{root-name}. Note that @var{root-name} is a local directory and @emph{not} a fully qualified @code{CVSROOT} variable. The @code{Root} request need not have been previously sent. -@itemx update \n +@item update \n Response expected: yes. Actually do a @code{cvs update} command. This uses any previous @code{Argument}, @code{Directory}, @code{Entry}, or @code{Modified} requests, if they have been sent. The @@ -619,7 +841,7 @@ message and exiting---this should be investigated further). In the following, @var{pathname} actually indicates a pair of pathnames. First, a local directory name relative to the directory in which the command was given (i.e. the last -@code{Directory} before the command). Then a newline and a repository +@code{Directory} before the command). Then a linefeed and a repository name. Then a slash and the filename (without a @samp{,v} ending). For example, for a file @file{i386.mh} @@ -631,6 +853,30 @@ gas.clean/config/ /rel/cvsfiles/devo/gas/config/i386.mh @end example +If the server wants to tell the client to create a directory, then it +merely uses the directory in any response, as described above, and the +client should create the directory if it does not exist. Note that this +should only be done one directory at a time, in order to permit the +client to correctly store the repository for each directory. Servers +can use requests such as @code{Clear-sticky}, +@code{Clear-static-directory}, or any other requests, to create +directories. +@c FIXME: Need example here of how "repository" needs to be sent for +@c each directory, and cannot be correctly deduced from, say, the most +@c deeply nested directory. + +Some server +implementations may poorly distinguish between a directory which should +not exist and a directory which contains no files; in order to refrain +from creating empty directories a client should both send the @samp{-P} +option to @code{update} or @code{co}, and should also detect the case in +which the server asks to create a directory but not any files within it +(in that case the client should remove the directory or refrain from +creating it in the first place). Note that servers could clean this up +greatly by only telling the client to create directories if the +directory in question should exist, but until servers do this, clients +will need to offer the @samp{-P} behavior described above. + Any response always ends with @samp{error} or @samp{ok}. This indicates that the response is over. @@ -678,12 +924,29 @@ This is just like @code{Updated} and takes the same additional data, but is used only if a @code{Entry}, @code{Modified}, or @code{Unchanged} request has been sent for the file in question. +This response, or @code{Merged}, indicates that the server has +determined that it is OK to overwrite the previous contents of the file +specified by @var{pathname}. Provided that the client has correctly +sent @code{Modified} or @code{Is-modified} requests for a modified file, +and the file was not modified while CVS was running, the server can +ensure that a user's modifications are not lost. + @item Merged @var{pathname} \n This is just like @code{Updated} and takes the same additional data, with the one difference that after the new copy of the file is enclosed, it will still not be up to date. Used for the results of a merge, with or without conflicts. +It is useful to preserve an copy of what the file looked like before the +merge. This is basically handled by the server; before sending +@code{Merged} it will send a @code{Copy-file} response. For example, if +the file is @file{aa} and it derives from revision 1.3, the +@code{Copy-file} response will tell the client to copy @file{aa} to +@file{.#aa.1.3}. It is up to the client to decide how long to keep this +file around; traditionally clients have left it around forever, thus +letting the user clean it up as desired. But another answer, such as +until the next commit, might be preferable. + @item Patched @var{pathname} \n This is just like @code{Updated} and takes the same additional data, with the one difference that instead of sending a new copy of the file, diff --git a/gnu/usr.bin/cvs/src/ChangeLog b/gnu/usr.bin/cvs/src/ChangeLog index 42a631ef2be..6fe1e91c768 100644 --- a/gnu/usr.bin/cvs/src/ChangeLog +++ b/gnu/usr.bin/cvs/src/ChangeLog @@ -1,5 +1,276 @@ +Fri Apr 18 11:24:26 1997 Jim Kingdon + + * version.c: Version 1.9.8. + + * commit.c (struct find_data): Add field force. + (find_fileproc, commit): Use it instead of force_ci to decide + whether to send files to server. + (commit): Set it if either -f or -r is specified. + * sanity.sh (basica): Add tests basica-8a0, basica-8a1, and + basica-8a2; tests for above fix. + +Wed Apr 16 11:50:59 1997 Jim Kingdon + + * zlib.c: Remove paragraph with Free Software Foundation address. + See 2 Jan 1997 entry in ../ChangeLog for rationale. + +Tue Apr 15 00:36:23 1997 Jim Kingdon + + * update.c (patch_file_write): Always assign to final_nl, so that + it ends up reflecting whether the data from the last call had a + newline, not whether the data from any of the calls ended in a + newline. Doesn't matter with the current RCS_checkout + implementation, but it will if RCS_checkout is changed to pass + less than the entire file. + + * rcs.c (RCS_cmp_file): Change NULL to RUN_TTY in passing sout to + RCS_checkout, for clarity. + + * import.c (update_rcs_file): Remove unused variable ierrno. + + * add.c, checkout.c, commit.c, diff.c, edit.c, import.c, + history.c, log.c, main.c, patch.c, release.c, remove.c, rtag.c, + status.c, tag.c, update.c, watch.c: Pass "+" to all calls to + getopt. This ensures that we maintain existing behavior even with + glibc2. + + * filesubr.c (fopen_case): Don't set *PATHP if we return an + error. Since the 9 Apr 1997 change, the behavior has been to + sometimes set it and sometimes not. + * rcs.c (RCS_parse): Adjust callers to not free it. Without this + change, they could call free() on an uninitialized variable. + + * checkout.c (checkout): Add comment about export -k. + + * root.c (check_root_consistent): Add comment about wording of + message. + +Mon Apr 14 11:51:49 1997 Jim Kingdon + + * client.c (call_in_directory): If rdirp reaches the end of + reposdirname, then just set it to NULL. If server does not create + directories one at a time, give a warning. + * sanity.sh (modules3): Enable tests modules3-8 through + modules3-11 for remote; tests for above fix. + + * client.c (call_in_directory): Don't set short_pathname to + pathname for a while; just use pathname itself (cleans up a relic + of the old "Repository" (not "Directory") code). Add comment + explaining short_pathname. + +Sun Apr 13 18:07:50 1997 Ian Lance Taylor + + * rcs.c (RCS_checkout): Add pfn and callerdat parameters. Change + all callers. Move setting of expand after retrieval of file + data. + (struct cmp_file_data): Define. + (RCS_cmp_file): New function. + (cmp_file_buffer): New static function. + * rcs.h (RCSCHECKOUTPROC): Define type. + (RCS_checkout): Update declaration. + (RCS_cmp_file): Define. + * diff.c (diff_file_nodiff): Call RCS_cmp_file rather than + RCS_checkout and xcmp. + * import.c (update_rcs_file): Likewise. + * no_diff.c (No_Difference): Likewise. + * update.c (struct patch_file_data): Define. + (patch_file): Just return if noexec, or if binary file. Pass + patch_file_write to RCS_checkout. Don't check for newlines or + compute checksums here. Stat RCS file to set modes. + (patch_file_write): New static function. + + * update.c (patch_file): Checkout directly to file2, rather than + to finfo->file followed by rename. Remove check for whether + result of checkout is readable; that was for an old, obsolete, + form of death support. + +Sun Apr 13 13:16:40 1997 Jim Kingdon + + * checkout.c (build_one_dir): New function. + (struct dir_to_build): New structure. + (build_dirs_and_chir): Rewritten to accept a linked list of struct + dir_to_build rather than the silly string processing we had been + doing before. + (checkout_proc): Rewrite code that calls build_dirs_and_chdir + accordingly. + * sanity.sh: Enable tests modules3-10 and modules3-11 for local CVS; + tests for above fix. + + * rcs.h (RCS_CO): Removed; no longer used. + +Sun Apr 13 00:04:34 1997 Ian Lance Taylor + + Expand RCS keywords internally; never call co: + * rcs.h (struct rcsversnode): Add state field. + * rcs.c (kflags): Move out of RCS_check_kflag, and make file + static. + (enum kflag): Define. + (RCS_reparsercsfile): Always save lock information. Save state in + new state field, rather than other field. + (struct rcs_keyword): Define. + (keywords): New static variable. + (enum keyword): Define. + (printable_date, escape_keyword_value): New static functions. + (expand_keywords): New static function. + (RCS_checkout): Call expand_keywords. Don't call + RCS_exec_checkout. + (RCS_deltas): Add log and loglen parameters. Change all callers. + * log.c (log_version_requested): Use new state field. + (log_version): Likewise. + * cvs.h (RCS_exec_checkout): Don't declare. + * rcscmds.c (RCS_exec_checkout): Remove. + +Sat Apr 12 17:32:59 1997 Ian Lance Taylor + + * sanity.sh (modules3): Remove second-dir at end of tests. + (sticky): Correct removal of directories at end of tests. + + * sanity.sh (keyword): New tests for RCS keyword expansion. + +Sat Apr 12 16:47:13 1997 Jim Kingdon + + * sanity.sh (basicb): New tests basicb-1b, basicb-1c, basicb-9b, + basic-9c test current build_dirs_and_chdir behavior. + +Fri Apr 11 23:54:56 1997 Jim Kingdon + + * sanity.sh (modules3): New tests modules3-7* test for ability to + supply a path in -d in modules. Similar to modules3-8 through + modules3-11 except because the nesting is different, these ones + work. + +Thu Apr 10 00:14:47 1997 Jim Kingdon + + * sanity.sh (modules3): New tests modules3-12 through modules3-15 + test use of a module name which contains a slash. + + * sanity.sh (basicb): New tests basicb-14 to basicb-20 test use of + co -d with two or more arguments. + + * rcscmds.c: Refer to doc/RCSFILES in comment. + +Wed Apr 9 09:49:17 1997 Jim Kingdon + + * sanity.sh (basicb): New tests basicb-11 through basicb-13 test + ability to specify several directory levels in co -d (commented + out). + + * filesubr.c (fopen_case): If CVS_OPENDIR gives an + existence_error, return it to the caller instead of giving a fatal + error. + + * client.c (update_entries): Fix typo in call to error (1 -> errno). + +Tue Apr 8 23:02:22 1997 Jim Kingdon + + * error.h, error.c: Test for #ifdef __STDC__, not #if __STDC__. + This is consistent with other parts of CVS; it means that the + declaration for fperror will match the definition even if __STDC__ + is defined to 0 as the SunPro 4.0 compiler does. Reported by + Richard Smith . + +2 Apr 1997 Jim Kingdon + + * entries.c (ParseTag): Add "break;" after "default:" to avoid + error from Visual C++. + +Wed Apr 2 12:06:44 1997 Vince Del Vecchio + and Jim Kingdon + + * client.c: In reporting errors from socket calls, use + SOCK_STRERROR and SOCK_ERRNO since strerror(errno) doesn't work + for Win32. + +Tue Apr 8 10:45:32 1997 Jim Kingdon + + * sanity.sh (modules3): Add tests modules3-8 to modules3-11, to + test for ability to supply a path to -d in modules. Mostly + commented out as CVS is buggy in this area. + +Mon Apr 7 12:41:44 1997 Jim Kingdon + + * add.c (add): Add comment about SEND_NO_CONTENTS. + +Sun Apr 6 21:46:32 1997 Jim Kingdon + + * update.c (update): Add comment about noexec and SEND_NO_CONTENTS. + +Sun Apr 6 17:34:08 1997 Robert Bihlmeyer + + * Pass +f not f to getopt_long to prevent options from being + permuted with glibc 2.0.1. + +Sun Mar 30 00:07:05 1997 Jim Kingdon + + * cvs.h (struct vers_ts): Adjust comment regarding ts_user. + * server.c (serve_is_modified): New function. Set entries to show + that the file is modified but we don't know the contents. + * server.c (requests): Add "Is-modified" request. + * vers_ts.c (time_stamp_server): If the timestamp in entdata is + "M" or "D", just copy that over into ts_user. + * vers_ts.c (Version_TS): If timestamp is "D", use the entries + line for the sole purpose of passing it to time_stamp_server. + * no_diff.c (No_Difference): If ts_user is "M", conclude the files + are different. + * client.h, client.c (send_files): Replace arguments build_dirs + and force with argument flags. Add flag SEND_NO_CONTENTS and add + to struct send_data. + (send_fileproc): If no_contents, then send Is-modified instead of + Modified. + * add.c, admin.c, client.c, commit.c, diff.c, edit.c, log.c, + rcs.c, remove.c, status.c, tag.c, update.c, watch.c: Change all + send_files callers. + +Fri Mar 28 22:32:25 1997 Jim Kingdon + + * server.c (requests): Change "Repository" to rq_optional. I'm + not sure whether I overlooked this when I removed support for + Repository, or whether I was thinking that servers would need to + support it anyway, for CVS 1.5 to 1.9 clients, but making it + optional doesn't prevent the server from supporting it and it + seems silly for the client to complain about absence of a request + that it never will use. + +Fri Mar 28 10:06:59 1997 Steven Miller + + * entries.c (Subdirs_Known): Don't create Entries.Log if noexec. + +Thu Mar 27 18:14:12 1997 Ian Lance Taylor + + * sanity.sh (death2): Remove commented out test death2-21. It + would now pass, but it duplicates the new test sticky-11. + +Thu Mar 27 10:21:19 1997 Jim Kingdon + + * sanity.sh (dotest_internal): Write test output to logfile even + if test succeeds. This was the behavior prior to 30 Sep 1996. + See the comment for rationale. + Tue Mar 25 13:26:52 1997 Jim Kingdon + * cvs.h, entries.c (WriteTag): Add arguments nonbranch, + update_dir, and repository. Move the server_set_sticky call from + callers to here. + * cvs.h, create_adm.c (Create_Admin): New argument nonbranch. + * cvs.h, entries.c (ParseTag): Add argument nonbranchp. + * cvs.h (struct stickydirtag): Add field nonbranch. + * entries.c (Entries_Open): Set it. + * cvs.h (Vers_TS): Add field nonbranch. + * vers_ts.c (Version_TS): Copy it from struct stickydirtag. + * server.c, server.h (server_set_sticky): Add argument nonbranch. + * add.c, client.c, checkout.c, modules.c, update.c, create_adm.c, + commit.c: Update callers. + * add.c (add): If nonbranch, don't add the file on that "branch". + * commit.c (write_dirnonbranch): New variable. + (commit_fileproc, commit): Set it. + (commit_dirleaveproc): Pass it to WriteTag. + * update.c (rewrite_tag, nonbranch): New variables. + (update, update_dirent_proc, update_fileproc): Set them. + (update_filesdoneproc): If rewrite_tag, call WriteTag. + * sanity.sh (sticky): New tests, test for above fix. + + * version.c: Change version number to 1.9.7. + * version.c: Version 1.9.6. Mon Mar 24 13:02:04 1997 Jim Kingdon diff --git a/gnu/usr.bin/cvs/src/add.c b/gnu/usr.bin/cvs/src/add.c index 28faecc7839..8bba5bb62a1 100644 --- a/gnu/usr.bin/cvs/src/add.c +++ b/gnu/usr.bin/cvs/src/add.c @@ -103,7 +103,7 @@ add (argc, argv) /* parse args */ optind = 1; - while ((c = getopt (argc, argv, "k:m:")) != -1) + while ((c = getopt (argc, argv, "+k:m:")) != -1) { switch (c) { @@ -147,17 +147,18 @@ add (argc, argv) { char *tag; char *date; + int nonbranch; char *rcsdir; /* before we do anything else, see if we have any per-directory tags */ - ParseTag (&tag, &date); + ParseTag (&tag, &date, &nonbranch); rcsdir = combine_dir (repository, argv[i]); strip_trailing_slashes (argv[i]); - Create_Admin (argv[i], argv[i], rcsdir, tag, date); + Create_Admin (argv[i], argv[i], rcsdir, tag, date, nonbranch); if (tag) free (tag); @@ -179,7 +180,8 @@ add (argc, argv) } } send_file_names (argc, argv, SEND_EXPAND_WILD); - send_files (argc, argv, 0, 0, 1, 0); + /* FIXME: should be able to pass SEND_NO_CONTENTS, I think. */ + send_files (argc, argv, 0, 0, SEND_BUILD_DIRS); send_to_server ("add\012", 0); return get_responses_and_close (); } @@ -265,28 +267,39 @@ add (argc, argv) } } - /* There is a user file, so build the entry for it */ - if (build_entry (repository, user, vers->options, - message, entries, vers->tag) != 0) - err++; + if (vers->nonbranch) + { + error (0, 0, + "cannot add file on non-branch tag %s", + vers->tag); + ++err; + } else { - added_files++; - if (!quiet) + /* There is a user file, so build the entry for it */ + if (build_entry (repository, user, vers->options, + message, entries, vers->tag) != 0) + err++; + else { - if (vers->tag) - error (0, 0, "\ + added_files++; + if (!quiet) + { + if (vers->tag) + error (0, 0, "\ scheduling %s `%s' for addition on branch `%s'", - (wrap_name_has (user, WRAP_TOCVS) - ? "wrapper" - : "file"), - user, vers->tag); - else - error (0, 0, "scheduling %s `%s' for addition", - (wrap_name_has (user, WRAP_TOCVS) - ? "wrapper" - : "file"), - user); + (wrap_name_has (user, WRAP_TOCVS) + ? "wrapper" + : "file"), + user, vers->tag); + else + error (0, 0, + "scheduling %s `%s' for addition", + (wrap_name_has (user, WRAP_TOCVS) + ? "wrapper" + : "file"), + user); + } } } } @@ -302,20 +315,31 @@ same name already exists in the repository."); } else { - if (vers->tag) - error (0, 0, "\ -file `%s' will be added on branch `%s' from version %s", - user, vers->tag, vers->vn_rcs); + if (vers->nonbranch) + { + error (0, 0, + "cannot add file on non-branch tag %s", + vers->tag); + ++err; + } else - /* I'm not sure that mentioning vers->vn_rcs makes - any sense here; I can't think of a way to word the - message which is not confusing. */ - error (0, 0, "\ + { + if (vers->tag) + error (0, 0, "\ +file `%s' will be added on branch `%s' from version %s", + user, vers->tag, vers->vn_rcs); + else + /* I'm not sure that mentioning + vers->vn_rcs makes any sense here; I + can't think of a way to word the + message which is not confusing. */ + error (0, 0, "\ re-adding file %s (in place of dead revision %s)", - user, vers->vn_rcs); - Register (entries, user, "0", vers->ts_user, NULL, - vers->tag, NULL, NULL); - ++added_files; + user, vers->vn_rcs); + Register (entries, user, "0", vers->ts_user, NULL, + vers->tag, NULL, NULL); + ++added_files; + } } } else @@ -446,6 +470,7 @@ add_directory (repository, entries, dir) struct saved_cwd cwd; char *message = NULL; char *tag, *date; + int nonbranch; if (strchr (dir, '/') != NULL) { @@ -460,7 +485,7 @@ add_directory (repository, entries, dir) } /* before we do anything else, see if we have any per-directory tags */ - ParseTag (&tag, &date); + ParseTag (&tag, &date, &nonbranch); /* now, remember where we were, so we can get back */ if (save_cwd (&cwd)) @@ -550,9 +575,9 @@ add_directory (repository, entries, dir) #ifdef SERVER_SUPPORT if (!server_active) - Create_Admin (".", dir, rcsdir, tag, date); + Create_Admin (".", dir, rcsdir, tag, date, nonbranch); #else - Create_Admin (".", dir, rcsdir, tag, date); + Create_Admin (".", dir, rcsdir, tag, date, nonbranch); #endif if (tag) free (tag); diff --git a/gnu/usr.bin/cvs/src/admin.c b/gnu/usr.bin/cvs/src/admin.c index 763eb981d29..dd187801dfa 100644 --- a/gnu/usr.bin/cvs/src/admin.c +++ b/gnu/usr.bin/cvs/src/admin.c @@ -93,10 +93,7 @@ admin (argc, argv) send_arg (av[i]); send_file_names (argc, argv, SEND_EXPAND_WILD); - /* FIXME: We shouldn't have to send current files, but I'm not sure - whether it works. So send the files -- - it's slower but it works. */ - send_files (argc, argv, 0, 0, 0, 0); + send_files (argc, argv, 0, 0, SEND_NO_CONTENTS); send_to_server ("admin\012", 0); return get_responses_and_close (); } diff --git a/gnu/usr.bin/cvs/src/checkin.c b/gnu/usr.bin/cvs/src/checkin.c index c5b5d073f16..3c6a3b2cd98 100644 --- a/gnu/usr.bin/cvs/src/checkin.c +++ b/gnu/usr.bin/cvs/src/checkin.c @@ -93,7 +93,8 @@ Checkin (type, finfo, rcs, rev, tag, options, message) /* FIXME: should be checking for errors. */ (void) RCS_checkout (finfo->rcs, finfo->file, rev, - (char *) NULL, options, RUN_TTY); + (char *) NULL, options, RUN_TTY, + (RCSCHECKOUTPROC) NULL, (void *) NULL); xchmod (finfo->file, 1); if (xcmp (finfo->file, fname) == 0) diff --git a/gnu/usr.bin/cvs/src/client.c b/gnu/usr.bin/cvs/src/client.c index 03b0cae7134..2f6b8c673bb 100644 --- a/gnu/usr.bin/cvs/src/client.c +++ b/gnu/usr.bin/cvs/src/client.c @@ -14,7 +14,7 @@ #include "md5.h" -#if defined(AUTH_CLIENT_SUPPORT) || HAVE_KERBEROS || USE_DIRECT_TCP +#if defined(AUTH_CLIENT_SUPPORT) || HAVE_KERBEROS || USE_DIRECT_TCP || defined(SOCK_ERRNO) || defined(SOCK_STRERROR) # ifdef HAVE_WINSOCK_H # include # else /* No winsock.h */ @@ -22,7 +22,31 @@ # include # include # endif /* No winsock.h */ -#endif /* defined(AUTH_CLIENT_SUPPORT) || HAVE_KERBEROS || USE_DIRECT_TCP */ +#endif /* defined(AUTH_CLIENT_SUPPORT) || HAVE_KERBEROS || USE_DIRECT_TCP + || defined(SOCK_ERRNO) || defined(SOCK_STRERROR) */ + +/* If SOCK_ERRNO is defined, then send()/recv() and other socket calls + do not set errno, but that this macro should be used to obtain an + error code. This probably doesn't make sense unless + NO_SOCKET_TO_FD is also defined. */ +#ifndef SOCK_ERRNO +#define SOCK_ERRNO errno +#endif + +/* If SOCK_STRERROR is defined, then the error codes returned by + socket operations are not known to strerror, and this macro must be + used instead to convert those error codes to strings. */ +#ifndef SOCK_STRERROR +# define SOCK_STRERROR strerror + +# if STDC_HEADERS +# include +# endif + +# ifndef strerror +extern char *strerror (); +# endif +#endif /* ! SOCK_STRERROR */ #if HAVE_KERBEROS || USE_DIRECT_TCP #define CVS_PORT 1999 @@ -426,7 +450,11 @@ log_buffer_shutdown (closure) via a socket using send() and recv(). This is because under some operating systems (OS/2 and Windows 95 come to mind), a socket cannot be converted to a file descriptor -- it must be treated as a - socket and nothing else. */ + socket and nothing else. + + We may also need to deal with socket routine error codes differently + in these cases. This is handled through the SOCK_ERRNO and + SOCK_STRERROR macros. */ static int use_socket_style = 0; static int server_sock; @@ -435,6 +463,12 @@ static int server_sock; recv. The buffer is always in blocking mode so we don't implement the block routine. */ +/* Note that it is important that these routines always handle errors + internally and never return a positive errno code, since it would in + general be impossible for the caller to know in general whether any + error code came from a socket routine (to decide whether to use + SOCK_STRERROR or simply strerror to print an error message). */ + /* We use an instance of this structure as the closure field. */ struct socket_buffer @@ -496,7 +530,7 @@ socket_buffer_input (closure, data, need, size, got) { nbytes = recv (sb->socket, data, size, 0); if (nbytes < 0) - error (1, errno, "reading from server"); + error (1, 0, "reading from server: %s", SOCK_STRERROR (SOCK_ERRNO)); if (nbytes == 0) { /* End of file (for example, the server has closed @@ -536,7 +570,7 @@ socket_buffer_output (closure, data, have, wrote) is needed for systems where its return value is something other than the number of bytes written. */ if (send (sb->socket, data, have, 0) < 0) - error (1, errno, "writing to server socket"); + error (1, 0, "writing to server socket: %s", SOCK_STRERROR (SOCK_ERRNO)); #else while (have > 0) { @@ -544,7 +578,7 @@ socket_buffer_output (closure, data, have, wrote) nbytes = send (sb->socket, data, have, 0); if (nbytes < 0) - error (1, errno, "writing to server socket"); + error (1, 0, "writing to server socket: %s", SOCK_STRERROR (SOCK_ERRNO)); have -= nbytes; data += nbytes; @@ -768,8 +802,13 @@ call_in_directory (pathname, func, data) { char *dir_name; char *filename; - /* Just the part of pathname relative to toplevel_repos. */ - char *short_pathname = pathname; + /* This is what we get when we hook up the directory (working directory + name) from PATHNAME with the filename from REPOSNAME. For example: + pathname: ccvs/src/ + reposname: /u/src/master/ccvs/foo/ChangeLog + short_pathname: ccvs/src/ChangeLog + */ + char *short_pathname; char *p; /* @@ -820,7 +859,7 @@ call_in_directory (pathname, func, data) else *p = '\0'; - dir_name = xstrdup (short_pathname); + dir_name = xstrdup (pathname); p = strrchr (dir_name, '/'); if (p == NULL) { @@ -892,7 +931,7 @@ call_in_directory (pathname, func, data) strcpy (r, "/."); Create_Admin (".", ".", repo, (char *) NULL, - (char *) NULL); + (char *) NULL, 0); free (repo); } @@ -907,6 +946,12 @@ call_in_directory (pathname, func, data) /* Directory does not exist, we need to create it. */ newdir = 1; + + /* Provided we are willing to assume that directories get + created one at a time, we could simplify this a lot. + Do note that one aspect still would need to walk the + dir_name path: the checking for "fncmp (dir, CVSADM)". */ + dir = xmalloc (strlen (dir_name) + 1); dirp = dir_name; rdirp = reposdirname; @@ -941,8 +986,10 @@ call_in_directory (pathname, func, data) /* Skip the slash. */ ++dirp; if (rdirp == NULL) - error (0, 0, - "internal error: repository string too short."); + /* This just means that the repository string has + fewer components than the dir_name string. But + that is OK (e.g. see modules3-8 in testsuite). */ + ; else rdirp = strchr (rdirp, '/'); } @@ -1007,6 +1054,13 @@ call_in_directory (pathname, func, data) if (rdirp) { + /* See comment near start of function; the only + way that the server can put the right thing + in each CVS/Repository file is to create the + directories one at a time. I think that the + CVS server has been doing this all along. */ + error (0, 0, "\ +warning: server is not creating directories one at a time"); strncpy (r, reposdirname, rdirp - reposdirname); r[rdirp - reposdirname] = '\0'; } @@ -1014,7 +1068,7 @@ call_in_directory (pathname, func, data) strcpy (r, reposdirname); Create_Admin (dir, dir, repo, - (char *)NULL, (char *)NULL); + (char *)NULL, (char *)NULL, 0); free (repo); b = strrchr (dir, '/'); @@ -1588,7 +1642,7 @@ update_entries (data_arg, ent_list, short_pathname, filename) error (1, 0, "patch original file %s does not exist", short_pathname); if ( CVS_STAT (temp_filename, &s) < 0) - error (1, 1, "can't stat patch file %s", temp_filename); + error (1, errno, "can't stat patch file %s", temp_filename); if (s.st_size == 0) retcode = 0; else @@ -2595,7 +2649,7 @@ client_send_expansions (local, where, build_dirs) { argv[0] = where ? where : modules_vector[i]; if (isfile (argv[0])) - send_files (1, argv, local, 0, build_dirs, 0); + send_files (1, argv, local, 0, build_dirs ? SEND_BUILD_DIRS : 0); } send_a_repository ("", CVSroot_directory, ""); } @@ -2869,7 +2923,7 @@ get_responses_and_close () if (use_socket_style) { if (shutdown (server_sock, 2) < 0) - error (1, errno, "shutting down server socket"); + error (1, 0, "shutting down server socket: %s", SOCK_STRERROR (SOCK_ERRNO)); } else #endif /* NO_SOCKET_TO_FD */ @@ -2878,8 +2932,8 @@ get_responses_and_close () if (server_fd != -1) { if (shutdown (server_fd, 1) < 0) - error (1, errno, "shutting down connection to %s", - CVSroot_hostname); + error (1, 0, "shutting down connection to %s: %s", + CVSroot_hostname, SOCK_STRERROR (SOCK_ERRNO)); /* * This test will always be true because we dup the descriptor */ @@ -3029,8 +3083,8 @@ connect_to_pserver (tofdp, fromfdp, verify_only) init_sockaddr (&client_sai, CVSroot_hostname, port_number); if (connect (sock, (struct sockaddr *) &client_sai, sizeof (client_sai)) < 0) - error (1, errno, "connect to %s:%d failed", CVSroot_hostname, - port_number); + error (1, 0, "connect to %s:%d failed: %s", CVSroot_hostname, + port_number, SOCK_STRERROR (SOCK_ERRNO)); /* Run the authorization mini-protocol before anything else. */ { @@ -3096,7 +3150,8 @@ connect_to_pserver (tofdp, fromfdp, verify_only) for (i = 0; (i < (LARGEST_RESPONSE - 1)) && (ch != '\n'); i++) { if (recv (sock, &ch, 1, 0) < 0) - error (1, errno, "recv() from server %s", CVSroot_hostname); + error (1, 0, "recv() from server %s: %s", CVSroot_hostname, + SOCK_STRERROR (SOCK_ERRNO)); read_buf[i] = ch; } @@ -3109,8 +3164,9 @@ connect_to_pserver (tofdp, fromfdp, verify_only) error (0, 0, "authorization failed: server %s rejected access", CVSroot_hostname); - error (1, errno, - "shutdown() failed (server %s)", CVSroot_hostname); + error (1, 0, + "shutdown() failed (server %s): %s", CVSroot_hostname, + SOCK_STRERROR (SOCK_ERRNO)); } if (verify_only) @@ -3128,7 +3184,9 @@ connect_to_pserver (tofdp, fromfdp, verify_only) error (0, 0, "unrecognized auth response from %s: %s", CVSroot_hostname, read_buf); - error (1, errno, "shutdown() failed, server %s", CVSroot_hostname); + error (1, 0, + "shutdown() failed, server %s: %s", CVSroot_hostname, + SOCK_STRERROR (SOCK_ERRNO)); } error (1, 0, "unrecognized auth response from %s: %s", @@ -3139,7 +3197,8 @@ connect_to_pserver (tofdp, fromfdp, verify_only) if (verify_only) { if (shutdown (sock, 2) < 0) - error (0, errno, "shutdown() failed, server %s", CVSroot_hostname); + error (0, 0, "shutdown() failed, server %s: %s", CVSroot_hostname, + SOCK_STRERROR (SOCK_ERRNO)); return 1; } else @@ -3170,9 +3229,9 @@ connect_to_pserver (tofdp, fromfdp, verify_only) /* * FIXME: this function has not been changed to deal with * NO_SOCKET_TO_FD (i.e., systems on which sockets cannot be converted - * to file descriptors. The first person to try building a kerberos - * client on such a system (OS/2, Windows 95, and maybe others) will - * have to make take care of this. + * to file descriptors) or with SOCK_ERRNO/SOCK_STRERROR. The first + * person to try building a kerberos client on such a system (OS/2, + * Windows 95, and maybe others) will have to make take care of this. */ void start_tcp_server (tofdp, fromfdp) @@ -4098,7 +4157,7 @@ send_modified (file, short_pathname, vers) * one. */ if (newsize > 0) - send_to_server (buf, newsize); + send_to_server (buf, newsize); } free (buf); free (mode_string); @@ -4110,8 +4169,10 @@ send_modified (file, short_pathname, vers) struct send_data { + /* Each of the following flags are zero for clear or nonzero for set. */ int build_dirs; int force; + int no_contents; }; static int send_fileproc PROTO ((void *callerdat, struct file_info *finfo)); @@ -4143,19 +4204,19 @@ send_fileproc (callerdat, finfo) if (vers->vn_user != NULL) { - char *tmp; - - tmp = xmalloc (strlen (filename) + strlen (vers->vn_user) - + strlen (vers->options) + 200); - sprintf (tmp, "Entry /%s/%s/%s%s/%s/", - filename, vers->vn_user, - vers->ts_conflict == NULL ? "" : "+", - (vers->ts_conflict == NULL ? "" - : (vers->ts_user != NULL && - strcmp (vers->ts_conflict, vers->ts_user) == 0 - ? "=" - : "modified")), - vers->options); + char *tmp; + + tmp = xmalloc (strlen (filename) + strlen (vers->vn_user) + + strlen (vers->options) + 200); + sprintf (tmp, "Entry /%s/%s/%s%s/%s/", + filename, vers->vn_user, + vers->ts_conflict == NULL ? "" : "+", + (vers->ts_conflict == NULL ? "" + : (vers->ts_user != NULL && + strcmp (vers->ts_conflict, vers->ts_user) == 0 + ? "=" + : "modified")), + vers->options); /* The Entries request. */ /* Not sure about whether this deals with -k and stuff right. */ @@ -4187,7 +4248,15 @@ send_fileproc (callerdat, finfo) || args->force || strcmp (vers->ts_user, vers->ts_rcs) != 0) { - send_modified (filename, finfo->fullname, vers); + if (args->no_contents + && supported_request ("Is-modified")) + { + send_to_server ("Is-modified ", 0); + send_to_server (filename, 0); + send_to_server ("\012", 1); + } + else + send_modified (filename, finfo->fullname, vers); } else { @@ -4510,23 +4579,22 @@ send_file_names (argc, argv, flags) } -/* - * Send Repository, Modified and Entry. argc and argv contain only - * the files to operate on (or empty for everything), not options. - * local is nonzero if we should not recurse (-l option). build_dirs - * is nonzero if nonexistent directories should be sent. force is - * nonzero if we should send unmodified files to the server as though - * they were modified. Also sends Argument lines for argc and argv, - * so should be called after options are sent. - */ +/* Send Repository, Modified and Entry. argc and argv contain only + the files to operate on (or empty for everything), not options. + local is nonzero if we should not recurse (-l option). flags & + SEND_BUILD_DIRS is nonzero if nonexistent directories should be + sent. flags & SEND_FORCE is nonzero if we should send unmodified + files to the server as though they were modified. flags & + SEND_NO_CONTENTS means that this command only needs to know + _whether_ a file is modified, not the contents. Also sends Argument + lines for argc and argv, so should be called after options are sent. */ void -send_files (argc, argv, local, aflag, build_dirs, force) +send_files (argc, argv, local, aflag, flags) int argc; char **argv; int local; int aflag; - int build_dirs; - int force; + unsigned int flags; { struct send_data args; int err; @@ -4536,8 +4604,9 @@ send_files (argc, argv, local, aflag, build_dirs, force) * But we don't actually use it, so I don't think it matters what we pass * for aflag here. */ - args.build_dirs = build_dirs; - args.force = force; + args.build_dirs = flags & SEND_BUILD_DIRS; + args.force = flags & SEND_FORCE; + args.no_contents = flags & SEND_NO_CONTENTS; err = start_recursion (send_fileproc, send_filesdoneproc, send_dirent_proc, (DIRLEAVEPROC)NULL, (void *) &args, diff --git a/gnu/usr.bin/cvs/src/client.h b/gnu/usr.bin/cvs/src/client.h index d313c965e6e..6d92da51149 100644 --- a/gnu/usr.bin/cvs/src/client.h +++ b/gnu/usr.bin/cvs/src/client.h @@ -83,7 +83,12 @@ send_file_names PROTO((int argc, char **argv, unsigned int flags)); */ void send_files PROTO((int argc, char **argv, int local, int aflag, - int build_dirs, int force)); + unsigned int flags)); + +/* Flags for send_files. */ +#define SEND_BUILD_DIRS 1 +#define SEND_FORCE 2 +#define SEND_NO_CONTENTS 4 /* Send an argument to the remote server. */ void diff --git a/gnu/usr.bin/cvs/src/create_adm.c b/gnu/usr.bin/cvs/src/create_adm.c index e1f7773d3b8..0ef6e57fc5e 100644 --- a/gnu/usr.bin/cvs/src/create_adm.c +++ b/gnu/usr.bin/cvs/src/create_adm.c @@ -16,12 +16,13 @@ /* update_dir includes dir as its last component. */ void -Create_Admin (dir, update_dir, repository, tag, date) +Create_Admin (dir, update_dir, repository, tag, date, nonbranch) char *dir; char *update_dir; char *repository; char *tag; char *date; + int nonbranch; { FILE *fout; char *cp; @@ -123,12 +124,11 @@ Create_Admin (dir, update_dir, repository, tag, date) } /* Create a new CVS/Tag file */ - WriteTag (dir, tag, date); + WriteTag (dir, tag, date, nonbranch, update_dir, repository); #ifdef SERVER_SUPPORT if (server_active) { - server_set_sticky (update_dir, repository, tag, date); server_template (update_dir, repository); } diff --git a/gnu/usr.bin/cvs/src/diff.c b/gnu/usr.bin/cvs/src/diff.c index 24bc7b60d9c..ba618ec6eb0 100644 --- a/gnu/usr.bin/cvs/src/diff.c +++ b/gnu/usr.bin/cvs/src/diff.c @@ -202,7 +202,7 @@ diff (argc, argv) optind = 1; while ((c = getopt_long (argc, argv, - "abcdefhilnpstuwy0123456789BHNRTC:D:F:I:L:U:V:W:k:r:", + "+abcdefhilnpstuwy0123456789BHNRTC:D:F:I:L:U:V:W:k:r:", longopts, &option_index)) != -1) { switch (c) @@ -309,15 +309,12 @@ diff (argc, argv) client_senddate (diff_date2); send_file_names (argc, argv, SEND_EXPAND_WILD); -#if 0 - /* FIXME: We shouldn't have to send current files to diff two - revs, but it doesn't work yet and I haven't debugged it. - So send the files -- it's slower but it works. - gnu@cygnus.com Apr94 */ + /* Send the current files unless diffing two revs from the archive */ if (diff_rev2 == NULL && diff_date2 == NULL) -#endif - send_files (argc, argv, local, 0, 0, 0); + send_files (argc, argv, local, 0, 0); + else + send_files (argc, argv, local, 0, SEND_NO_CONTENTS); send_to_server ("diff\012", 0); err = get_responses_and_close (); @@ -576,7 +573,8 @@ diff_fileproc (callerdat, finfo) (*options ? options : vers->options), - tmp); + tmp, (RCSCHECKOUTPROC) NULL, + (void *) NULL); if (retcode == -1) { (void) CVS_UNLINK (tmp); @@ -596,7 +594,8 @@ diff_fileproc (callerdat, finfo) retcode = RCS_checkout (vers->srcfile, (char *) NULL, use_rev1, (char *) NULL, *options ? options : vers->options, - tmp); + tmp, (RCSCHECKOUTPROC) NULL, + (void *) NULL); if (retcode == -1) { (void) CVS_UNLINK (tmp); @@ -739,7 +738,6 @@ diff_file_nodiff (finfo, vers, empty_file) enum diff_file empty_file; { Vers_TS *xvers; - char *tmp; int retcode; /* free up any old use_rev* variables and reset 'em */ @@ -900,29 +898,10 @@ diff_file_nodiff (finfo, vers, empty_file) * with 0 or 1 -r option specified, run a quick diff to see if we * should bother with it at all. */ - tmp = cvs_temp_name (); - retcode = RCS_checkout (vers->srcfile, (char *) NULL, use_rev1, - (char *) NULL, + + retcode = RCS_cmp_file (vers->srcfile, use_rev1, *options ? options : vers->options, - tmp); - switch (retcode) - { - case 0: /* everything ok */ - if (xcmp (finfo->file, tmp) == 0) - { - (void) CVS_UNLINK (tmp); - free (tmp); - return DIFF_SAME; - } - break; - case -1: /* fork failed */ - (void) CVS_UNLINK (tmp); - error (1, errno, "fork failed during checkout of %s", - vers->srcfile->path); - default: - break; - } - (void) CVS_UNLINK (tmp); - free (tmp); - return DIFF_DIFFERENT; + finfo->file); + + return retcode == 0 ? DIFF_SAME : DIFF_DIFFERENT; } diff --git a/gnu/usr.bin/cvs/src/edit.c b/gnu/usr.bin/cvs/src/edit.c index 7593da43d20..f884c9d12a1 100644 --- a/gnu/usr.bin/cvs/src/edit.c +++ b/gnu/usr.bin/cvs/src/edit.c @@ -61,7 +61,7 @@ watch_onoff (argc, argv) int err; optind = 1; - while ((c = getopt (argc, argv, "l")) != -1) + while ((c = getopt (argc, argv, "+l")) != -1) { switch (c) { @@ -87,10 +87,7 @@ watch_onoff (argc, argv) if (local) send_arg ("-l"); send_file_names (argc, argv, SEND_EXPAND_WILD); - /* FIXME: We shouldn't have to send current files, but I'm not sure - whether it works. So send the files -- - it's slower but it works. */ - send_files (argc, argv, local, 0, 0, 0); + send_files (argc, argv, local, 0, SEND_NO_CONTENTS); send_to_server (turning_on ? "watch-on\012" : "watch-off\012", 0); return get_responses_and_close (); } @@ -356,7 +353,7 @@ edit (argc, argv) setting_tunedit = 0; setting_tcommit = 0; optind = 1; - while ((c = getopt (argc, argv, "la:")) != -1) + while ((c = getopt (argc, argv, "+la:")) != -1) { switch (c) { @@ -488,7 +485,7 @@ unedit (argc, argv) usage (edit_usage); optind = 1; - while ((c = getopt (argc, argv, "l")) != -1) + while ((c = getopt (argc, argv, "+l")) != -1) { switch (c) { @@ -974,7 +971,7 @@ editors (argc, argv) usage (editors_usage); optind = 1; - while ((c = getopt (argc, argv, "l")) != -1) + while ((c = getopt (argc, argv, "+l")) != -1) { switch (c) { @@ -999,10 +996,7 @@ editors (argc, argv) if (local) send_arg ("-l"); send_file_names (argc, argv, SEND_EXPAND_WILD); - /* FIXME: We shouldn't have to send current files, but I'm not sure - whether it works. So send the files -- - it's slower but it works. */ - send_files (argc, argv, local, 0, 0, 0); + send_files (argc, argv, local, 0, SEND_NO_CONTENTS); send_to_server ("editors\012", 0); return get_responses_and_close (); } diff --git a/gnu/usr.bin/cvs/src/entries.c b/gnu/usr.bin/cvs/src/entries.c index 8fb22d0e5c9..1e9dd58cd1e 100644 --- a/gnu/usr.bin/cvs/src/entries.c +++ b/gnu/usr.bin/cvs/src/entries.c @@ -435,6 +435,7 @@ Entries_Open (aflag) struct stickydirtag *sdtp = NULL; Entnode *ent; char *dirtag, *dirdate; + int dirnonbranch; int do_rewrite = 0; FILE *fpin; int sawdir; @@ -446,7 +447,7 @@ Entries_Open (aflag) * Parse the CVS/Tag file, to get any default tag/date settings. Use * list-private storage to tuck them away for Version_TS(). */ - ParseTag (&dirtag, &dirdate); + ParseTag (&dirtag, &dirdate, &dirnonbranch); if (aflag || dirtag || dirdate) { sdtp = (struct stickydirtag *) xmalloc (sizeof (*sdtp)); @@ -454,6 +455,7 @@ Entries_Open (aflag) sdtp->aflag = aflag; sdtp->tag = xstrdup (dirtag); sdtp->date = xstrdup (dirdate); + sdtp->nonbranch = dirnonbranch; /* feed it into the list-private area */ entries->list->data = (char *) sdtp; @@ -597,10 +599,13 @@ AddEntryNode (list, entdata) * Write out/Clear the CVS/Tag file. */ void -WriteTag (dir, tag, date) +WriteTag (dir, tag, date, nonbranch, update_dir, repository) char *dir; char *tag; char *date; + int nonbranch; + char *update_dir; + char *repository; { FILE *fout; char *tmp; @@ -621,8 +626,16 @@ WriteTag (dir, tag, date) fout = open_file (tmp, "w+"); if (tag) { - if (fprintf (fout, "T%s\n", tag) < 0) - error (1, errno, "write to %s failed", tmp); + if (nonbranch) + { + if (fprintf (fout, "N%s\n", tag) < 0) + error (1, errno, "write to %s failed", tmp); + } + else + { + if (fprintf (fout, "T%s\n", tag) < 0) + error (1, errno, "write to %s failed", tmp); + } } else { @@ -636,15 +649,20 @@ WriteTag (dir, tag, date) if (unlink_file (tmp) < 0 && ! existence_error (errno)) error (1, errno, "cannot remove %s", tmp); free (tmp); +#ifdef SERVER_SUPPORT + if (server_active) + server_set_sticky (update_dir, repository, tag, date, nonbranch); +#endif } /* * Parse the CVS/Tag file for the current directory. */ void -ParseTag (tagp, datep) +ParseTag (tagp, datep, nonbranchp) char **tagp; char **datep; + int *nonbranchp; { FILE *fp; @@ -667,13 +685,30 @@ ParseTag (tagp, datep) /* Remove any trailing newline. */ if (line[line_length - 1] == '\n') line[--line_length] = '\0'; - if (*line == 'T' && tagp) - *tagp = xstrdup (line + 1); - else if (*line == 'D' && datep) - *datep = xstrdup (line + 1); - /* if not 'T' or 'D' silently ignore it; it may have been - written by a future version of CVS which extends the - syntax. */ + switch (*line) + { + case 'T': + if (tagp != NULL) + *tagp = xstrdup (line + 1); + if (nonbranchp != NULL) + *nonbranchp = 0; + break; + case 'D': + if (datep != NULL) + *datep = xstrdup (line + 1); + break; + case 'N': + if (tagp != NULL) + *tagp = xstrdup (line + 1); + if (nonbranchp != NULL) + *nonbranchp = 1; + break; + default: + /* Silently ignore it; it may have been + written by a future version of CVS which extends the + syntax. */ + break; + } } (void) fclose (fp); free (line); @@ -700,10 +735,13 @@ Subdirs_Known (entries) FILE *fp; sdtp->subdirs = 1; - /* Create Entries.Log so that Entries_Close will do something. */ - fp = open_file (CVSADM_ENTLOG, "a"); - if (fclose (fp) == EOF) - error (1, errno, "cannot close %s", CVSADM_ENTLOG); + if (!noexec) + { + /* Create Entries.Log so that Entries_Close will do something. */ + fp = open_file (CVSADM_ENTLOG, "a"); + if (fclose (fp) == EOF) + error (1, errno, "cannot close %s", CVSADM_ENTLOG); + } } } diff --git a/gnu/usr.bin/cvs/src/error.c b/gnu/usr.bin/cvs/src/error.c index 0ed7eb24d37..5c7eef500ae 100644 --- a/gnu/usr.bin/cvs/src/error.c +++ b/gnu/usr.bin/cvs/src/error.c @@ -26,7 +26,7 @@ int error_use_protocol; #ifdef HAVE_VPRINTF -#if __STDC__ +#ifdef __STDC__ #include #define VA_START(args, lastarg) va_start(args, lastarg) #else /* ! __STDC__ */ @@ -50,7 +50,7 @@ int error_use_protocol; #include #include #else /* ! STDC_HEADERS */ -#if __STDC__ +#ifdef __STDC__ void exit(int status); #else /* ! __STDC__ */ void exit (); @@ -86,7 +86,7 @@ error_exit PROTO ((void)) no need to print a message. */ /* VARARGS */ void -#if defined (HAVE_VPRINTF) && __STDC__ +#if defined (HAVE_VPRINTF) && defined (__STDC__) error (int status, int errnum, const char *message, ...) #else error (status, errnum, message, va_alist) @@ -213,7 +213,7 @@ error (status, errnum, message, va_alist) Exit with status EXIT_FAILURE if STATUS is nonzero. */ /* VARARGS */ void -#if defined (HAVE_VPRINTF) && ((__STDC__ - 0) > 0) +#if defined (HAVE_VPRINTF) && defined (__STDC__) fperror (FILE *fp, int status, int errnum, char *message, ...) #else fperror (fp, status, errnum, message, va_alist) diff --git a/gnu/usr.bin/cvs/src/error.h b/gnu/usr.bin/cvs/src/error.h index 5d37bb44d75..e0fde4a5bec 100644 --- a/gnu/usr.bin/cvs/src/error.h +++ b/gnu/usr.bin/cvs/src/error.h @@ -37,7 +37,7 @@ # endif #endif -#if __STDC__ +#ifdef __STDC__ void error (int, int, const char *, ...) \ __attribute__ ((__format__ (__printf__, 3, 4))); #else diff --git a/gnu/usr.bin/cvs/src/filesubr.c b/gnu/usr.bin/cvs/src/filesubr.c index f105b454950..70048ae148b 100644 --- a/gnu/usr.bin/cvs/src/filesubr.c +++ b/gnu/usr.bin/cvs/src/filesubr.c @@ -755,9 +755,7 @@ cvs_casecmp (str1, str2) case-insensitivity. Returns errno code or 0 for success. Puts the new file in *FP. NAME and MODE are as for fopen. If PATHP is not NULL, then put a malloc'd string containing the pathname as found - into *PATHP. Note that a malloc'd string is put into *PATHP - even if we return an error. It doesn't mean anything, but it still - must be freed. + into *PATHP. *PATHP is only set if the return value is 0. Might be cleaner to separate the file finding (which just gives *PATHP) from the file opening (which the caller can do). For one @@ -788,7 +786,22 @@ fopen_case (name, mode, fp, pathp) found_name = NULL; dirp = CVS_OPENDIR (dir); if (dirp == NULL) - error (1, errno, "cannot read directory %s", dir); + { + if (existence_error (errno)) + { + /* This can happen if we are looking in the Attic and the Attic + directory does not exist. Return the error to the caller; + they know what to do with it. */ + retval = errno; + goto out; + } + else + { + /* Give a fatal error; that way the error message can be + more specific than if we returned the error to the caller. */ + error (1, errno, "cannot read directory %s", dir); + } + } errno = 0; while ((dp = readdir (dirp)) != NULL) { @@ -829,9 +842,12 @@ fopen_case (name, mode, fp, pathp) if (pathp == NULL) free (dir); + else if (retval != 0) + free (dir); else *pathp = dir; free (found_name); + out: return retval; } #endif /* SERVER_SUPPORT */ diff --git a/gnu/usr.bin/cvs/src/history.c b/gnu/usr.bin/cvs/src/history.c index 1d19418bc8a..bce237f5275 100644 --- a/gnu/usr.bin/cvs/src/history.c +++ b/gnu/usr.bin/cvs/src/history.c @@ -390,7 +390,7 @@ history (argc, argv) backto = xstrdup (""); rec_types = xstrdup (""); optind = 1; - while ((c = getopt (argc, argv, "Tacelow?D:b:f:m:n:p:r:t:u:x:X:z:")) != -1) + while ((c = getopt (argc, argv, "+Tacelow?D:b:f:m:n:p:r:t:u:x:X:z:")) != -1) { switch (c) { diff --git a/gnu/usr.bin/cvs/src/import.c b/gnu/usr.bin/cvs/src/import.c index 38cb55b3e65..4e01e65c616 100644 --- a/gnu/usr.bin/cvs/src/import.c +++ b/gnu/usr.bin/cvs/src/import.c @@ -81,7 +81,7 @@ import (argc, argv) vbranch = xstrdup (CVSBRANCH); optind = 1; - while ((c = getopt (argc, argv, "Qqdb:m:I:k:W:")) != -1) + while ((c = getopt (argc, argv, "+Qqdb:m:I:k:W:")) != -1) { switch (c) { @@ -503,7 +503,6 @@ update_rcs_file (message, vfile, vtag, targc, targv, inattic) { Vers_TS *vers; int letter; - int ierrno; char *tocvsPath; struct file_info finfo; @@ -520,12 +519,7 @@ update_rcs_file (message, vfile, vtag, targc, targv, inattic) if (vers->vn_rcs != NULL && !RCS_isdead(vers->srcfile, vers->vn_rcs)) { - char *xtmpfile; int different; - int retcode = 0; - - xtmpfile = xmalloc (strlen (Tmpdir) + 40); - (void) sprintf (xtmpfile, "%s/cvs-imp%ld", Tmpdir, (long) getpid()); /* * The rcs file does have a revision on the vendor branch. Compare @@ -536,36 +530,14 @@ update_rcs_file (message, vfile, vtag, targc, targv, inattic) * This is to try to cut down the number of "C" conflict messages for * locally modified import source files. */ - retcode = RCS_checkout (vers->srcfile, (char *) NULL, vers->vn_rcs, - (char *) NULL, -#ifdef HAVE_RCS5 - "-ko", -#else - NULL, -#endif - xtmpfile); - if (retcode != 0) - { - ierrno = errno; - fperror (logfp, 0, retcode == -1 ? ierrno : 0, - "ERROR: cannot co revision %s of file %s", vers->vn_rcs, - vers->srcfile->path); - error (0, retcode == -1 ? ierrno : 0, - "ERROR: cannot co revision %s of file %s", vers->vn_rcs, - vers->srcfile->path); - (void) unlink_file (xtmpfile); - free (xtmpfile); - return (1); - } - tocvsPath = wrap_tocvs_process_file (vfile); - different = xcmp (xtmpfile, vfile); + /* FIXME: Why don't we pass tocvsPath to RCS_cmp_file if it is + not NULL? */ + different = RCS_cmp_file (vers->srcfile, vers->vn_rcs, "-ko", vfile); if (tocvsPath) if (unlink_file_dir (tocvsPath) < 0) error (0, errno, "cannot remove %s", tocvsPath); - (void) unlink_file (xtmpfile); - free (xtmpfile); if (!different) { int retval = 0; diff --git a/gnu/usr.bin/cvs/src/log.c b/gnu/usr.bin/cvs/src/log.c index 8c6634ba66c..8fb6910a2f7 100644 --- a/gnu/usr.bin/cvs/src/log.c +++ b/gnu/usr.bin/cvs/src/log.c @@ -168,7 +168,7 @@ cvslog (argc, argv) memset (&log_data, 0, sizeof log_data); optind = 1; - while ((c = getopt (argc, argv, "bd:hlNRr::s:tw::")) != -1) + while ((c = getopt (argc, argv, "+bd:hlNRr::s:tw::")) != -1) { switch (c) { @@ -233,10 +233,7 @@ cvslog (argc, argv) send_arg (argv[i]); send_file_names (argc - i, argv + i, SEND_EXPAND_WILD); -/* FIXME: We shouldn't have to send current files to get log entries, but it - doesn't work yet and I haven't debugged it. So send the files -- - it's slower but it works. gnu@cygnus.com Apr94 */ - send_files (argc - i, argv + i, local, 0, 0, 0); + send_files (argc - i, argv + i, local, 0, SEND_NO_CONTENTS); send_to_server ("log\012", 0); err = get_responses_and_close (); @@ -1000,16 +997,10 @@ log_version_requested (log_data, revlist, rcs, vnode) RCSVers *vnode; { /* Handle the list of states from the -s option. */ - if (log_data->statelist != NULL) + if (log_data->statelist != NULL + && findnode (log_data->statelist, vnode->state) == NULL) { - Node *p; - - p = findnode (vnode->other, "state"); - if (p != NULL - && findnode (log_data->statelist, p->data) == NULL) - { - return 0; - } + return 0; } /* Handle the list of authors from the -w option. */ @@ -1306,8 +1297,7 @@ log_version (log_data, revlist, rcs, ver, trunk) cvs_output (ver->author, 0); cvs_output ("; state: ", 0); - p = findnode (ver->other, "state"); - cvs_output (p->data, 0); + cvs_output (ver->state, 0); cvs_output (";", 1); if (! trunk) diff --git a/gnu/usr.bin/cvs/src/mkmodules.c b/gnu/usr.bin/cvs/src/mkmodules.c index add69b8c5a8..a5be35808ee 100644 --- a/gnu/usr.bin/cvs/src/mkmodules.c +++ b/gnu/usr.bin/cvs/src/mkmodules.c @@ -512,7 +512,8 @@ checkout_file (file, temp) return (1); } rcsnode = RCS_parsercsfile (rcs); - retcode = RCS_checkout (rcsnode, NULL, NULL, NULL, NULL, temp); + retcode = RCS_checkout (rcsnode, NULL, NULL, NULL, NULL, temp, + (RCSCHECKOUTPROC) NULL, (void *) NULL); if (retcode != 0) { error (0, retcode == -1 ? errno : 0, "failed to check out %s file", diff --git a/gnu/usr.bin/cvs/src/modules.c b/gnu/usr.bin/cvs/src/modules.c index 8ec1b7a38f5..814f0cdeb29 100644 --- a/gnu/usr.bin/cvs/src/modules.c +++ b/gnu/usr.bin/cvs/src/modules.c @@ -401,7 +401,7 @@ do_module (db, mname, m_type, msg, callback_proc, where, error (1, 0, "there is no repository %s", nullrepos); Create_Admin (".", dir, - nullrepos, (char *) NULL, (char *) NULL); + nullrepos, (char *) NULL, (char *) NULL, 0); if (!noexec) { FILE *fp; diff --git a/gnu/usr.bin/cvs/src/no_diff.c b/gnu/usr.bin/cvs/src/no_diff.c index 31ef057417f..384800fda6b 100644 --- a/gnu/usr.bin/cvs/src/no_diff.c +++ b/gnu/usr.bin/cvs/src/no_diff.c @@ -22,12 +22,17 @@ No_Difference (finfo, vers) Vers_TS *vers; { Node *p; - char *tmp; int ret; char *ts, *options; int retcode = 0; char *tocvsPath; + /* If ts_user is "Is-modified", we can only conclude the files are + different (since we don't have the file's contents). */ + if (vers->ts_user != NULL + && strcmp (vers->ts_user, "Is-modified") == 0) + return -1; + if (!vers->srcfile || !vers->srcfile->path) return (-1); /* different since we couldn't tell */ @@ -36,88 +41,51 @@ No_Difference (finfo, vers) else options = xstrdup (""); - tmp = cvs_temp_name (); - retcode = RCS_checkout (vers->srcfile, (char *) NULL, vers->vn_user, - (char *) NULL, options, tmp); + tocvsPath = wrap_tocvs_process_file (finfo->file); + retcode = RCS_cmp_file (vers->srcfile, vers->vn_user, options, + tocvsPath == NULL ? finfo->file : tocvsPath); if (retcode == 0) { -#if 0 - /* Why would we want to munge the modes? And only if the timestamps - are different? And even for commands like "cvs status"???? */ - if (!iswritable (finfo->file)) /* fix the modes as a side effect */ - xchmod (finfo->file, 1); -#endif - - tocvsPath = wrap_tocvs_process_file (finfo->file); - - /* do the byte by byte compare */ - if (xcmp (tocvsPath == NULL ? finfo->file : tocvsPath, tmp) == 0) - { -#if 0 - /* Why would we want to munge the modes? And only if the - timestamps are different? And even for commands like - "cvs status"???? */ - if (cvswrite == FALSE) /* fix the modes as a side effect */ - xchmod (finfo->file, 0); -#endif - - /* no difference was found, so fix the entries file */ - ts = time_stamp (finfo->file); - Register (finfo->entries, finfo->file, - vers->vn_user ? vers->vn_user : vers->vn_rcs, ts, - options, vers->tag, vers->date, (char *) 0); + /* no difference was found, so fix the entries file */ + ts = time_stamp (finfo->file); + Register (finfo->entries, finfo->file, + vers->vn_user ? vers->vn_user : vers->vn_rcs, ts, + options, vers->tag, vers->date, (char *) 0); #ifdef SERVER_SUPPORT - if (server_active) - { - /* We need to update the entries line on the client side. */ - server_update_entries - (finfo->file, finfo->update_dir, finfo->repository, SERVER_UPDATED); - } + if (server_active) + { + /* We need to update the entries line on the client side. */ + server_update_entries + (finfo->file, finfo->update_dir, finfo->repository, SERVER_UPDATED); + } #endif - free (ts); + free (ts); - /* update the entdata pointer in the vers_ts structure */ - p = findnode (finfo->entries, finfo->file); - vers->entdata = (Entnode *) p->data; + /* update the entdata pointer in the vers_ts structure */ + p = findnode (finfo->entries, finfo->file); + vers->entdata = (Entnode *) p->data; - ret = 0; - } - else - ret = 1; /* files were really different */ - if (tocvsPath) - { - /* Need to call unlink myself because the noexec variable - * has been set to 1. */ - if (trace) - (void) fprintf (stderr, "%c-> unlink (%s)\n", -#ifdef SERVER_SUPPORT - (server_active) ? 'S' : ' ', -#else - ' ', -#endif - tocvsPath); - if ( CVS_UNLINK (tocvsPath) < 0) - error (0, errno, "could not remove %s", tocvsPath); - } + ret = 0; } else - { - error (0, retcode == -1 ? errno : 0, - "could not check out revision %s of %s", - vers->vn_user, finfo->fullname); - ret = -1; /* different since we couldn't tell */ - } + ret = 1; /* files were really different */ - if (trace) + if (tocvsPath) + { + /* Need to call unlink myself because the noexec variable + * has been set to 1. */ + if (trace) + (void) fprintf (stderr, "%c-> unlink (%s)\n", #ifdef SERVER_SUPPORT - (void) fprintf (stderr, "%c-> unlink2 (%s)\n", - (server_active) ? 'S' : ' ', tmp); + (server_active) ? 'S' : ' ', #else - (void) fprintf (stderr, "-> unlink (%s)\n", tmp); + ' ', #endif - if (CVS_UNLINK (tmp) < 0) - error (0, errno, "could not remove %s", tmp); - free (tmp); + tocvsPath); + if ( CVS_UNLINK (tocvsPath) < 0) + error (0, errno, "could not remove %s", tocvsPath); + } + free (options); return (ret); } diff --git a/gnu/usr.bin/cvs/src/rcs.c b/gnu/usr.bin/cvs/src/rcs.c index 01ac779d0b2..1d0d38a4b89 100644 --- a/gnu/usr.bin/cvs/src/rcs.c +++ b/gnu/usr.bin/cvs/src/rcs.c @@ -11,6 +11,13 @@ #include #include "cvs.h" +/* The RCS -k options, and a set of enums that must match the array. + These come first so that we can use enum kflag in function + prototypes. */ +static const char *const kflags[] = + {"kv", "kvl", "k", "v", "o", "b", (char *) NULL}; +enum kflag { KFLAG_KV = 0, KFLAG_KVL, KFLAG_K, KFLAG_V, KFLAG_O, KFLAG_B }; + static RCSNode *RCS_parsercsfile_i PROTO((FILE * fp, const char *rcsfile)); static void RCS_reparsercsfile PROTO((RCSNode *, int, FILE **)); static char *RCS_getdatebranch PROTO((RCSNode * rcs, char *date, char *branch)); @@ -23,10 +30,16 @@ static void do_symbols PROTO((List * list, char *val)); static void free_rcsnode_contents PROTO((RCSNode *)); static void rcsvers_delproc PROTO((Node * p)); static char *translate_symtag PROTO((RCSNode *, const char *)); +static char *printable_date PROTO((const char *)); +static char *escape_keyword_value PROTO ((const char *, int *)); +static void expand_keywords PROTO((RCSNode *, RCSVers *, const char *, + const char *, size_t, enum kflag, char *, + size_t, char **, size_t *)); +static void cmp_file_buffer PROTO((void *, const char *, size_t)); enum rcs_delta_op {RCS_ANNOTATE, RCS_FETCH}; static void RCS_deltas PROTO ((RCSNode *, FILE *, char *, enum rcs_delta_op, - char **, size_t *)); + char **, size_t *, char **, size_t *)); /* * We don't want to use isspace() from the C library because: @@ -141,11 +154,9 @@ RCS_parse (file, repos) else if (! existence_error (status)) { error (0, status, "cannot open %s", rcsfile); - free (found_path); retval = NULL; goto out; } - free (found_path); (void) sprintf (rcsfile, "%s/%s/%s%s", repos, CVSATTIC, file, RCSEXT); status = fopen_case (rcsfile, "rb", &fp, &found_path); @@ -167,11 +178,9 @@ RCS_parse (file, repos) else if (! existence_error (status)) { error (0, status, "cannot open %s", rcsfile); - free (found_path); retval = NULL; goto out; } - free (found_path); } #endif retval = NULL; @@ -356,7 +365,11 @@ RCS_reparsercsfile (rdata, all, pfp) if (*cp == '\0' && strncmp (RCSDATE, value, strlen (RCSDATE)) == 0) break; - if (all) + /* We always save lock information, so that we can handle + -kkvl correctly when checking out a file. We don't use a + special field for this information, since it will normally + not be set for a CVS file. */ + if (all || strcmp (key, "locks") == 0) { Node *kv; @@ -385,7 +398,6 @@ RCS_reparsercsfile (rdata, all, pfp) for (;;) { char *valp; - Node *kvstate; vnode = (RCSVers *) xmalloc (sizeof (RCSVers)); memset (vnode, 0, sizeof (RCSVers)); @@ -414,30 +426,11 @@ unable to parse rcs file; `author' not in the expected place"); if (key == NULL || strcmp (key, "state") != 0) error (1, 0, "\ unable to parse rcs file; `state' not in the expected place"); + vnode->state = xstrdup (value); if (strcmp (value, "dead") == 0) { vnode->dead = 1; } - if (! all) - kvstate = NULL; - else - { - if (vnode->other == NULL) - vnode->other = getlist (); - kvstate = getnode (); - kvstate->type = RCSFIELD; - kvstate->key = xstrdup (key); - kvstate->data = xstrdup (value); - if (addnode (vnode->other, kvstate) != 0) - { - error (0, 0, - "\ -warning: duplicate key `%s' in version `%s' of RCS file `%s'", - key, vnode->version, rcsfile); - freenode (kvstate); - kvstate = NULL; - } - } /* fill in the branch list (if any branches exist) */ (void) getrcskey (fp, &key, &value, NULL); @@ -480,11 +473,9 @@ warning: duplicate key `%s' in version `%s' of RCS file `%s'", if (strcmp(key, RCSDEAD) == 0) { vnode->dead = 1; - if (kvstate != NULL) - { - free (kvstate->data); - kvstate->data = xstrdup ("dead"); - } + if (vnode->state != NULL) + free (vnode->state); + vnode->state = xstrdup ("dead"); continue; } /* if we have a revision, break and do it */ @@ -2056,8 +2047,6 @@ char * RCS_check_kflag (arg) const char *arg; { - static const char *const kflags[] = - {"kv", "kvl", "k", "v", "o", "b", (char *) NULL}; static const char *const keyword_usage[] = { "%s %s: invalid RCS keyword expansion mode\n", @@ -2166,36 +2155,648 @@ RCS_getexpand (rcs) return rcs->expand; } -/* Check out a revision from RCS. This function optimizes by reading - the head version directly if it is easy. Check out the revision - into WORKFILE, or to standard output if WORKFILE is NULL. REV is - the numeric revision to check out; it may be NULL, which means to - check out the head of the default branch. If NAMETAG is not NULL, - it is the tag that should be used when expanding the RCS Name - keyword. OPTIONS is a string such as -kb or -kkv, for keyword - expansion options, or NULL if there are none. If WORKFILE is NULL, - run regardless of noexec; if non-NULL, noexec inhibits execution. - SOUT is what to do with standard output (typically RUN_TTY). */ +/* RCS keywords, and a matching enum. */ +struct rcs_keyword +{ + const char *string; + size_t len; +}; +#define KEYWORD_INIT(s) (s), sizeof (s) - 1 +static const struct rcs_keyword keywords[] = +{ + { KEYWORD_INIT ("Author") }, + { KEYWORD_INIT ("Date") }, + { KEYWORD_INIT ("Header") }, + { KEYWORD_INIT ("Id") }, + { KEYWORD_INIT ("Locker") }, + { KEYWORD_INIT ("Log") }, + { KEYWORD_INIT ("Name") }, + { KEYWORD_INIT ("RCSfile") }, + { KEYWORD_INIT ("Revision") }, + { KEYWORD_INIT ("Source") }, + { KEYWORD_INIT ("State") }, + { NULL, 0 } +}; +enum keyword +{ + KEYWORD_AUTHOR = 0, + KEYWORD_DATE, + KEYWORD_HEADER, + KEYWORD_ID, + KEYWORD_LOCKER, + KEYWORD_LOG, + KEYWORD_NAME, + KEYWORD_RCSFILE, + KEYWORD_REVISION, + KEYWORD_SOURCE, + KEYWORD_STATE +}; + +/* Convert an RCS date string into a readable string. This is like + the RCS date2str function. */ + +static char * +printable_date (rcs_date) + const char *rcs_date; +{ + int year, mon, mday, hour, min, sec; + char buf[100]; + + (void) sscanf (rcs_date, SDATEFORM, &year, &mon, &mday, &hour, &min, + &sec); + if (year < 1900) + year += 1900; + sprintf (buf, "%04d/%02d/%02d %02d:%02d:%02d", year, mon, mday, + hour, min, sec); + return xstrdup (buf); +} + +/* Escape the characters in a string so that it can be included in an + RCS value. */ + +static char * +escape_keyword_value (value, free_value) + const char *value; + int *free_value; +{ + char *ret, *t; + const char *s; + + for (s = value; *s != '\0'; s++) + { + char c; + + c = *s; + if (c == '\t' + || c == '\n' + || c == '\\' + || c == ' ' + || c == '$') + { + break; + } + } + + if (*s == '\0') + { + *free_value = 0; + return (char *) value; + } + + ret = xmalloc (strlen (value) * 4 + 1); + *free_value = 1; + + for (s = value, t = ret; *s != '\0'; s++, t++) + { + switch (*s) + { + default: + *t = *s; + break; + case '\t': + *t++ = '\\'; + *t = 't'; + break; + case '\n': + *t++ = '\\'; + *t = 'n'; + break; + case '\\': + *t++ = '\\'; + *t = '\\'; + break; + case ' ': + *t++ = '\\'; + *t++ = '0'; + *t++ = '4'; + *t = '0'; + break; + case '$': + *t++ = '\\'; + *t++ = '0'; + *t++ = '4'; + *t = '4'; + break; + } + } + + *t = '\0'; + + return ret; +} + +/* Expand RCS keywords in the memory buffer BUF of length LEN. This + applies to file RCS and version VERS. If NAME is not NULL, and is + not a numeric revision, then it is the symbolic tag used for the + checkout. EXPAND indicates how to expand the keywords. This + function sets *RETBUF and *RETLEN to the new buffer and length. + This function may modify the buffer BUF. If BUF != *RETBUF, then + RETBUF is a newly allocated buffer. */ + +static void +expand_keywords (rcs, ver, name, log, loglen, expand, buf, len, retbuf, retlen) + RCSNode *rcs; + RCSVers *ver; + const char *name; + const char *log; + size_t loglen; + enum kflag expand; + char *buf; + size_t len; + char **retbuf; + size_t *retlen; +{ + struct expand_buffer + { + struct expand_buffer *next; + char *data; + size_t len; + int free_data; + } *ebufs = NULL; + struct expand_buffer *ebuf_last = NULL; + size_t ebuf_len = 0; + char *locker; + char *srch, *srch_next; + size_t srch_len; + + if (expand == KFLAG_O || expand == KFLAG_B) + { + *retbuf = buf; + *retlen = len; + return; + } + + /* If we are using -kkvl, dig out the locker information if any. */ + locker = NULL; + if (expand == KFLAG_KVL && rcs->other != NULL) + { + Node *p; + + p = findnode (rcs->other, "locks"); + if (p != NULL) + { + char *cp; + size_t verlen; + + /* The format of the locking information is + USER:VERSION USER:VERSION ... + If we find our version on the list, we set LOCKER to + the corresponding user name. */ + + verlen = strlen (ver->version); + cp = p->data; + while ((cp = strstr (cp, ver->version)) != NULL) + { + if (cp > p->data + && cp[-1] == ':' + && (cp[verlen] == '\0' + || whitespace (cp[verlen]))) + { + char *cpend; + + --cp; + cpend = cp; + while (cp > p->data && ! whitespace (*cp)) + --cp; + locker = xmalloc (cpend - cp + 1); + memcpy (locker, cp, cpend - cp); + locker[cpend - cp] = '\0'; + break; + } + + ++cp; + } + } + } + + /* RCS keywords look like $STRING$ or $STRING: VALUE$. */ + srch = buf; + srch_len = len; + while ((srch_next = memchr (srch, '$', srch_len)) != NULL) + { + char *s, *send; + size_t slen; + const struct rcs_keyword *keyword; + enum keyword kw; + char *value; + int free_value; + char *sub; + size_t sublen; + + srch_len -= (srch_next + 1) - srch; + srch = srch_next + 1; + + /* Look for the first non alphabetic character after the '$'. */ + send = srch + srch_len; + for (s = srch; s < send; s++) + if (! isalpha (*s)) + break; + + /* If the first non alphabetic character is not '$' or ':', + then this is not an RCS keyword. */ + if (s == send || (*s != '$' && *s != ':')) + continue; + + /* See if this is one of the keywords. */ + slen = s - srch; + for (keyword = keywords; keyword->string != NULL; keyword++) + { + if (keyword->len == slen + && strncmp (keyword->string, srch, slen) == 0) + { + break; + } + } + if (keyword->string == NULL) + continue; + + kw = (enum keyword) (keyword - keywords); + + /* If the keyword ends with a ':', then the old value consists + of the characters up to the next '$'. If there is no '$' + before the end of the line, though, then this wasn't an RCS + keyword after all. */ + if (*s == ':') + { + for (; s < send; s++) + if (*s == '$' || *s == '\n') + break; + if (s == send || *s != '$') + continue; + } + + /* At this point we must replace the string from SRCH to S + with the expansion of the keyword KW. */ + + /* Get the value to use. */ + free_value = 0; + if (expand == KFLAG_K) + value = NULL; + else + { + switch (kw) + { + default: + abort (); + + case KEYWORD_AUTHOR: + value = ver->author; + break; + + case KEYWORD_DATE: + value = printable_date (ver->date); + free_value = 1; + break; + + case KEYWORD_HEADER: + case KEYWORD_ID: + { + char *path; + int free_path; + char *date; + + if (kw == KEYWORD_HEADER) + path = rcs->path; + else + path = last_component (rcs->path); + path = escape_keyword_value (path, &free_path); + date = printable_date (ver->date); + value = xmalloc (strlen (path) + + strlen (ver->version) + + strlen (date) + + strlen (ver->author) + + strlen (ver->state) + + (locker == NULL ? 0 : strlen (locker)) + + 20); + + sprintf (value, "%s %s %s %s %s%s%s", + path, ver->version, date, ver->author, + ver->state, + locker != NULL ? " " : "", + locker != NULL ? locker : ""); + if (free_path) + free (path); + free (date); + free_value = 1; + } + break; + + case KEYWORD_LOCKER: + value = locker; + break; + + case KEYWORD_LOG: + case KEYWORD_RCSFILE: + value = escape_keyword_value (last_component (rcs->path), + &free_value); + break; + + case KEYWORD_NAME: + if (name != NULL && ! isdigit (*name)) + value = (char *) name; + else + value = NULL; + break; + + case KEYWORD_REVISION: + value = ver->version; + break; + + case KEYWORD_SOURCE: + value = escape_keyword_value (rcs->path, &free_value); + break; + + case KEYWORD_STATE: + value = ver->state; + break; + } + } + + sub = xmalloc (keyword->len + + (value == NULL ? 0 : strlen (value)) + + 10); + if (expand == KFLAG_V) + { + /* Decrement SRCH and increment S to remove the $ + characters. */ + --srch; + ++srch_len; + ++s; + sublen = 0; + } + else + { + strcpy (sub, keyword->string); + sublen = strlen (keyword->string); + if (expand != KFLAG_K) + { + sub[sublen] = ':'; + sub[sublen + 1] = ' '; + sublen += 2; + } + } + if (value != NULL) + { + strcpy (sub + sublen, value); + sublen += strlen (value); + } + if (expand != KFLAG_V && expand != KFLAG_K) + { + sub[sublen] = ' '; + ++sublen; + sub[sublen] = '\0'; + } + + if (free_value) + free (value); + + /* The Log keyword requires special handling. This behaviour + is taken from RCS 5.7. The special log message is what RCS + uses for ci -k. */ + if (kw == KEYWORD_LOG + && (sizeof "checked in with -k by " <= loglen + || strncmp (log, "checked in with -k by ", + sizeof "checked in with -k by " - 1) != 0)) + { + char *start; + char *leader; + size_t leader_len, leader_sp_len; + const char *logend; + const char *snl; + int cnl; + char *date; + const char *sl; + + /* We are going to insert the trailing $ ourselves, before + the log message, so we must remove it from S, if we + haven't done so already. */ + if (expand != KFLAG_V) + ++s; + + /* Find the start of the line. */ + start = srch; + while (start > buf && start[-1] != '\n') + --start; + + /* Copy the start of the line to use as a comment leader. */ + leader_len = srch - start; + if (expand != KFLAG_V) + --leader_len; + leader = xmalloc (leader_len); + memcpy (leader, start, leader_len); + leader_sp_len = leader_len; + while (leader_sp_len > 0 && leader[leader_sp_len - 1] == ' ') + --leader_sp_len; + + /* RCS does some checking for an old style of Log here, + but we don't bother. RCS issues a warning if it + changes anything. */ + + /* Count the number of newlines in the log message so that + we know how many copies of the leader we will need. */ + cnl = 0; + logend = log + loglen; + for (snl = log; snl < logend; snl++) + if (*snl == '\n') + ++cnl; + + date = printable_date (ver->date); + sub = xrealloc (sub, + (sublen + + sizeof "Revision" + + strlen (ver->version) + + strlen (date) + + strlen (ver->author) + + loglen + + (cnl + 2) * leader_len + + 20)); + if (expand != KFLAG_V) + { + sub[sublen] = '$'; + ++sublen; + } + sub[sublen] = '\n'; + ++sublen; + memcpy (sub + sublen, leader, leader_len); + sublen += leader_len; + sprintf (sub + sublen, "Revision %s %s %s\n", + ver->version, date, ver->author); + sublen += strlen (sub + sublen); + free (date); + + sl = log; + while (sl < logend) + { + if (*sl == '\n') + { + memcpy (sub + sublen, leader, leader_sp_len); + sublen += leader_sp_len; + sub[sublen] = '\n'; + ++sublen; + ++sl; + } + else + { + const char *slnl; + + memcpy (sub + sublen, leader, leader_len); + sublen += leader_len; + for (slnl = sl; slnl < logend && *slnl != '\n'; ++slnl) + ; + if (slnl < logend) + ++slnl; + memcpy (sub + sublen, sl, slnl - sl); + sublen += slnl - sl; + sl = slnl; + } + } + + memcpy (sub + sublen, leader, leader_sp_len); + sublen += leader_sp_len; + + free (leader); + } + + /* Now SUB contains a string which is to replace the string + from SRCH to S. SUBLEN is the length of SUB. */ + + if (sublen == s - srch) + { + memcpy (srch, sub, sublen); + free (sub); + } + else + { + struct expand_buffer *ebuf; + + /* We need to change the size of the buffer. We build a + list of expand_buffer structures. Each expand_buffer + structure represents a portion of the final output. We + concatenate them back into a single buffer when we are + done. This minimizes the number of potentially large + buffer copies we must do. */ + + if (ebufs == NULL) + { + ebufs = (struct expand_buffer *) xmalloc (sizeof *ebuf); + ebufs->next = NULL; + ebufs->data = buf; + ebufs->free_data = 0; + ebuf_len = srch - buf; + ebufs->len = ebuf_len; + ebuf_last = ebufs; + } + else + { + assert (srch >= ebuf_last->data); + assert (srch - ebuf_last->data <= ebuf_last->len); + ebuf_len -= ebuf_last->len - (srch - ebuf_last->data); + ebuf_last->len = srch - ebuf_last->data; + } + + ebuf = (struct expand_buffer *) xmalloc (sizeof *ebuf); + ebuf->data = sub; + ebuf->len = sublen; + ebuf->free_data = 1; + ebuf->next = NULL; + ebuf_last->next = ebuf; + ebuf_last = ebuf; + ebuf_len += sublen; + + ebuf = (struct expand_buffer *) xmalloc (sizeof *ebuf); + ebuf->data = s; + ebuf->len = srch_len - (s - srch); + ebuf->free_data = 0; + ebuf->next = NULL; + ebuf_last->next = ebuf; + ebuf_last = ebuf; + ebuf_len += srch_len - (s - srch); + } + + srch_len -= (s - srch); + srch = s; + } + + if (locker != NULL) + free (locker); + + if (ebufs == NULL) + { + *retbuf = buf; + *retlen = len; + } + else + { + char *ret; + + ret = xmalloc (ebuf_len); + *retbuf = ret; + *retlen = ebuf_len; + while (ebufs != NULL) + { + struct expand_buffer *next; + + memcpy (ret, ebufs->data, ebufs->len); + ret += ebufs->len; + if (ebufs->free_data) + free (ebufs->data); + next = ebufs->next; + free (ebufs); + ebufs = next; + } + } +} + +/* Check out a revision from an RCS file. + + If PFN is not NULL, then ignore WORKFILE and SOUT. Call PFN zero + or more times with the contents of the file. CALLERDAT is passed, + uninterpreted, to PFN. (The current code will always call PFN + exactly once for a non empty file; however, the current code + assumes that it can hold the entire file contents in memory, which + is not a good assumption, and might change in the future). + + Otherwise, if WORKFILE is not NULL, check out the revision to + WORKFILE. However, if WORKFILE is not NULL, and noexec is set, + then don't do anything. + + Otherwise, if WORKFILE is NULL, check out the revision to SOUT. If + SOUT is RUN_TTY, then write the contents of the revision to + standard output. When using SOUT, the output is generally a + temporary file; don't bother to get the file modes correct. + + REV is the numeric revision to check out. It may be NULL, which + means to check out the head of the default branch. + + If NAMETAG is not NULL, and is not a numeric revision, then it is + the tag that should be used when expanding the RCS Name keyword. + + OPTIONS is a string such as "-kb" or "-kv" for keyword expansion + options. It may be NULL to use the default expansion mode of the + file, typically "-kkv". */ int -RCS_checkout (rcs, workfile, rev, nametag, options, sout) +RCS_checkout (rcs, workfile, rev, nametag, options, sout, pfn, callerdat) RCSNode *rcs; char *workfile; char *rev; char *nametag; char *options; char *sout; + RCSCHECKOUTPROC pfn; + void *callerdat; { int free_rev = 0; + enum kflag expand; FILE *fp; struct stat sb; char *key; char *value; size_t len; int free_value = 0; - char *ouroptions; - int keywords; - int ret; + char *log = NULL; + size_t loglen; + FILE *ofp; if (trace) { @@ -2208,9 +2809,10 @@ RCS_checkout (rcs, workfile, rev, nametag, options, sout) rcs->path, rev != NULL ? rev : "", options != NULL ? options : "", - (workfile != NULL - ? workfile - : (sout != RUN_TTY ? sout : "(stdout)"))); + (pfn != NULL ? "(function)" + : (workfile != NULL + ? workfile + : (sout != RUN_TTY ? sout : "(stdout)")))); } assert (rev == NULL || isdigit (*rev)); @@ -2219,6 +2821,7 @@ RCS_checkout (rcs, workfile, rev, nametag, options, sout) return 0; assert (sout == RUN_TTY || workfile == NULL); + assert (pfn == NULL || (sout == RUN_TTY && workfile == NULL)); /* Some callers, such as Checkin or remove_file, will pass us a branch. */ @@ -2257,6 +2860,12 @@ RCS_checkout (rcs, workfile, rev, nametag, options, sout) getrcsrev (fp, &key); while (getrcskey (fp, &key, &value, &len) >= 0) { + if (strcmp (key, "log") == 0) + { + log = xmalloc (len); + memcpy (log, value, len); + loglen = len; + } if (strcmp (key, "text") == 0) { gothead = 1; @@ -2300,85 +2909,94 @@ RCS_checkout (rcs, workfile, rev, nametag, options, sout) error (1, errno, "cannot fstat %s", rcs->path); } - RCS_deltas (rcs, fp, rev, RCS_FETCH, &value, &len); + RCS_deltas (rcs, fp, rev, RCS_FETCH, &value, &len, &log, &loglen); free_value = 1; } /* If OPTIONS is NULL or the empty string, then the old code would invoke the RCS co program with no -k option, which means that co would use the string we have stored in rcs->expand. */ - if (options != NULL && options[0] != '\0') - { - assert (options[0] == '-' && options[1] == 'k'); - ouroptions = options + 2; - } - else if (rcs->expand != NULL) - ouroptions = rcs->expand; + if ((options == NULL || options[0] == '\0') && rcs->expand == NULL) + expand = KFLAG_KV; else - ouroptions = "kv"; - - keywords = 0; - - if (strcmp (ouroptions, "o") != 0 - && strcmp (ouroptions, "b") != 0) { - register int inkeyword; - register char *s, *send; + const char *ouroptions; + const char * const *cpp; - /* Keyword expansion is being done. Make sure the text does - not contain any keywords. If it does have any, do the - regular checkout. */ - inkeyword = 0; - send = value + len; - for (s = value; s < send; s++) + if (options != NULL && options[0] != '\0') { - register char c; + assert (options[0] == '-' && options[1] == 'k'); + ouroptions = options + 2; + } + else + ouroptions = rcs->expand; - c = *s; - if (c == '$') - { - if (inkeyword) - { - keywords = 1; - break; - } - inkeyword = 1; - } - else if (c == ':') - { - if (inkeyword) - { - keywords = 1; - break; - } - } - else if (inkeyword && ! isalpha ((unsigned char) c)) - inkeyword = 0; + for (cpp = kflags; *cpp != NULL; cpp++) + if (strcmp (*cpp, ouroptions) == 0) + break; + + if (*cpp != NULL) + expand = (enum kflag) (cpp - kflags); + else + { + error (0, 0, + "internal error: unsupported substitution string -k%s", + ouroptions); + expand = KFLAG_KV; } } - if (! keywords) + if (expand != KFLAG_O && expand != KFLAG_B) { - FILE *ofp; + Node *p; + char *newvalue; - /* We have the text we want. */ + p = findnode (rcs->versions, rev == NULL ? rcs->head : rev); + if (p == NULL) + error (1, 0, "internal error: no revision information for %s", + rev == NULL ? rcs->head : rev); + + expand_keywords (rcs, (RCSVers *) p->data, nametag, log, loglen, + expand, value, len, &newvalue, &len); + if (newvalue != value) + { + if (free_value) + free (value); + value = newvalue; + free_value = 1; + } + } + + if (log != NULL) + { + free (log); + log = NULL; + } + + if (pfn != NULL) + { + /* The PFN interface is very simple to implement right now, as + we always have the entire file in memory. */ + if (len != 0) + pfn (callerdat, value, len); + } + else + { if (workfile == NULL) { if (sout == RUN_TTY) ofp = stdout; else { - ofp = CVS_FOPEN (sout, - strcmp (ouroptions, "b") == 0 ? "wb" : "w"); + ofp = CVS_FOPEN (sout, expand == KFLAG_B ? "wb" : "w"); if (ofp == NULL) error (1, errno, "cannot open %s", sout); } } else { - ofp = CVS_FOPEN (workfile, - strcmp (ouroptions, "b") == 0 ? "wb" : "w"); + ofp = CVS_FOPEN (workfile, expand == KFLAG_B ? "wb" : "w"); if (ofp == NULL) error (1, errno, "cannot open %s", workfile); } @@ -2411,41 +3029,129 @@ RCS_checkout (rcs, workfile, rev, nametag, options, sout) if (fclose (ofp) < 0) error (1, errno, "cannot close %s", sout); } + } - if (free_value) - free (value); - if (free_rev) - free (rev); + if (free_value) + free (value); + if (free_rev) + free (rev); - return 0; - } + return 0; +} - /* We were not able to optimize retrieving this revision. */ +/* This structure is passed between RCS_cmp_file and cmp_file_buffer. */ -#if 0 - /* A bit of debugging code to make sure that NAMETAG corresponds - to REV. */ - if (nametag != NULL && strcmp (nametag, rev) != 0) +struct cmp_file_data +{ + const char *filename; + FILE *fp; + int different; +}; + +/* Compare the contents of revision REV of RCS file RCS with the + contents of the file FILENAME. OPTIONS is a string for the keyword + expansion options. Return 0 if the contents of the revision are + the same as the contents of the file, 1 if they are different. */ + +int +RCS_cmp_file (rcs, rev, options, filename) + RCSNode *rcs; + char *rev; + char *options; + const char *filename; +{ + int binary; + FILE *fp; + struct cmp_file_data data; + int retcode; + + if (options != NULL && options[0] != '\0') + binary = (strcmp (options, "-kb") == 0); + else { - char *numtag; + char *expand; - numtag = translate_symtag (rcs, nametag); - assert (rev != NULL && numtag != NULL && strcmp (numtag, rev) == 0); - free (numtag); + expand = RCS_getexpand (rcs); + if (expand != NULL && strcmp (expand, "b") == 0) + binary = 1; + else + binary = 0; } -#endif - if (free_value) - free (value); + fp = CVS_FOPEN (filename, binary ? FOPEN_BINARY_READ : "r"); - ret = RCS_exec_checkout (rcs->path, workfile, - nametag != NULL ? nametag : rev, - options, sout); + data.filename = filename; + data.fp = fp; + data.different = 0; - if (free_rev) - free (rev); + retcode = RCS_checkout (rcs, (char *) NULL, rev, (char *) NULL, + options, RUN_TTY, cmp_file_buffer, + (void *) &data); - return ret; + /* If we have not yet found a difference, make sure that we are at + the end of the file. */ + if (! data.different) + { + if (getc (fp) != EOF) + data.different = 1; + } + + fclose (fp); + + if (retcode != 0) + return 1; + + return data.different; +} + +/* This is a subroutine of RCS_cmp_file. It is passed to + RCS_checkout. */ + +#define CMP_BUF_SIZE (8 * 1024) + +static void +cmp_file_buffer (callerdat, buffer, len) + void *callerdat; + const char *buffer; + size_t len; +{ + struct cmp_file_data *data = (struct cmp_file_data *) callerdat; + char *filebuf; + + /* If we've already found a difference, we don't need to check + further. */ + if (data->different) + return; + + filebuf = xmalloc (len > CMP_BUF_SIZE ? CMP_BUF_SIZE : len); + + while (len > 0) + { + size_t checklen; + + checklen = len > CMP_BUF_SIZE ? CMP_BUF_SIZE : len; + if (fread (filebuf, 1, checklen, data->fp) != checklen) + { + if (ferror (data->fp)) + error (1, errno, "cannot read file %s for comparing", + data->filename); + data->different = 1; + free (filebuf); + return; + } + + if (memcmp (filebuf, buffer, checklen) != 0) + { + data->different = 1; + free (filebuf); + return; + } + + buffer += checklen; + len -= checklen; + } + + free (filebuf); } /* For RCS file RCS, make symbolic tag TAG point to revision REV. @@ -2888,16 +3594,21 @@ month_printname (month) RCS with file position pointing to the deltas. We close the file when we are done. + If LOG is non-NULL, then *LOG is set to the log message of VERSION, + and *LOGLEN is set to the length of the log message. + On error, give a fatal error. */ static void -RCS_deltas (rcs, fp, version, op, text, len) +RCS_deltas (rcs, fp, version, op, text, len, log, loglen) RCSNode *rcs; FILE *fp; char *version; enum rcs_delta_op op; char **text; size_t *len; + char **log; + size_t *loglen; { char *branchversion; char *cpversion; @@ -2993,6 +3704,16 @@ RCS_deltas (rcs, fp, version, op, text, len) while ((n = getrcskey (fp, &key, &value, &vallen)) >= 0) { + if (log != NULL + && isversion + && strcmp (key, "log") == 0 + && strcmp (branchversion, version) == 0) + { + *log = xmalloc (vallen); + memcpy (*log, value, vallen); + *loglen = vallen; + } + if (strcmp (key, "text") == 0) { if (ishead) @@ -3358,7 +4079,8 @@ annotate_fileproc (callerdat, finfo) cvs_outerr (finfo->fullname, 0); cvs_outerr ("\n***************\n", 0); - RCS_deltas (finfo->rcs, fp, version, RCS_ANNOTATE, NULL, NULL); + RCS_deltas (finfo->rcs, fp, version, RCS_ANNOTATE, (char **) NULL, + (size_t) NULL, (char **) NULL, (size_t *) NULL); free (version); return 0; } @@ -3427,10 +4149,7 @@ annotate (argc, argv) if (date) client_senddate (date); send_file_names (argc, argv, SEND_EXPAND_WILD); - /* FIXME: We shouldn't have to send current files, but I'm not sure - whether it works. So send the files -- - it's slower but it works. */ - send_files (argc, argv, local, 0, 0, 0); + send_files (argc, argv, local, 0, SEND_NO_CONTENTS); send_to_server ("annotate\012", 0); return get_responses_and_close (); } diff --git a/gnu/usr.bin/cvs/src/rcs.h b/gnu/usr.bin/cvs/src/rcs.h index 1305b8c754c..699280a79ad 100644 --- a/gnu/usr.bin/cvs/src/rcs.h +++ b/gnu/usr.bin/cvs/src/rcs.h @@ -10,7 +10,6 @@ #define RCS "rcs" #define RCS_CI "ci" -#define RCS_CO "co" #define RCS_DIFF "rcsdiff" #define RCS_RCSMERGE "rcsmerge" @@ -71,6 +70,7 @@ struct rcsversnode char *version; char *date; char *author; + char *state; char *next; int dead; List *branches; @@ -87,6 +87,9 @@ typedef struct rcsversnode RCSVers; */ #define RCS_MAGIC_BRANCH 0 +/* The type of a function passed to RCS_checkout. */ +typedef void (*RCSCHECKOUTPROC) PROTO ((void *, const char *, size_t)); + /* * exported interfaces */ @@ -113,7 +116,9 @@ char *RCS_getbranch PROTO((RCSNode * rcs, char *tag, int force_tag_match)); int RCS_isdead PROTO((RCSNode *, const char *)); char *RCS_getexpand PROTO ((RCSNode *)); -int RCS_checkout PROTO ((RCSNode *, char *, char *, char *, char *, char *)); +int RCS_checkout PROTO ((RCSNode *, char *, char *, char *, char *, char *, + RCSCHECKOUTPROC, void *)); +int RCS_cmp_file PROTO ((RCSNode *, char *, char *, const char *)); int RCS_settag PROTO ((RCSNode *, const char *, const char *)); int RCS_deltag PROTO ((RCSNode *, const char *, int)); int RCS_setbranch PROTO((RCSNode *, const char *)); diff --git a/gnu/usr.bin/cvs/src/release.c b/gnu/usr.bin/cvs/src/release.c index d387e6e5b7b..f2f1edf5b0e 100644 --- a/gnu/usr.bin/cvs/src/release.c +++ b/gnu/usr.bin/cvs/src/release.c @@ -82,7 +82,7 @@ release (argc, argv) if (argc == -1) usage (release_usage); optind = 1; - while ((c = getopt (argc, argv, "Qdq")) != -1) + while ((c = getopt (argc, argv, "+Qdq")) != -1) { switch (c) { diff --git a/gnu/usr.bin/cvs/src/remove.c b/gnu/usr.bin/cvs/src/remove.c index 6f31e0acb55..157125068fe 100644 --- a/gnu/usr.bin/cvs/src/remove.c +++ b/gnu/usr.bin/cvs/src/remove.c @@ -51,7 +51,7 @@ cvsremove (argc, argv) usage (remove_usage); optind = 1; - while ((c = getopt (argc, argv, "flR")) != -1) + while ((c = getopt (argc, argv, "+flR")) != -1) { switch (c) { @@ -100,7 +100,8 @@ cvsremove (argc, argv) if (local) send_arg("-l"); send_file_names (argc, argv, 0); - send_files (argc, argv, local, 0, 0, 0); + /* FIXME: Can't we set SEND_NO_CONTENTS here? Needs investigation. */ + send_files (argc, argv, local, 0, 0); send_to_server ("remove\012", 0); return get_responses_and_close (); } diff --git a/gnu/usr.bin/cvs/src/root.c b/gnu/usr.bin/cvs/src/root.c index 1e38c31478a..26910328fe9 100644 --- a/gnu/usr.bin/cvs/src/root.c +++ b/gnu/usr.bin/cvs/src/root.c @@ -227,7 +227,11 @@ check_root_consistent () cause deadlock, as noted in server_cleanup. Best solution would presumably be to write some code so that error() automatically defers the error in those cases where that is needed. */ - + /* FIXME? Possible that the wording should be more clear (e.g. + Root says "%s" but pserver protocol says "%s" + or something which would aid people who are writing implementations + of the client side of the CVS protocol. I don't see any security + problem with revealing that information. */ if ((Pserver_Repos != NULL) && (CVSroot_directory != NULL)) if (strcmp (Pserver_Repos, CVSroot_directory) != 0) error (1, 0, "repository mismatch: \"%s\" vs \"%s\"", diff --git a/gnu/usr.bin/cvs/src/rtag.c b/gnu/usr.bin/cvs/src/rtag.c index d499e0b3fe5..1e2017b9b0d 100644 --- a/gnu/usr.bin/cvs/src/rtag.c +++ b/gnu/usr.bin/cvs/src/rtag.c @@ -92,7 +92,7 @@ rtag (argc, argv) usage (rtag_usage); optind = 1; - while ((c = getopt (argc, argv, "FanfQqlRdbr:D:")) != -1) + while ((c = getopt (argc, argv, "+FanfQqlRdbr:D:")) != -1) { switch (c) { diff --git a/gnu/usr.bin/cvs/src/sanity.sh b/gnu/usr.bin/cvs/src/sanity.sh index 7906ec804c4..9f556209329 100644 --- a/gnu/usr.bin/cvs/src/sanity.sh +++ b/gnu/usr.bin/cvs/src/sanity.sh @@ -251,11 +251,24 @@ dotest_internal () else if $EXPR "`cat ${TESTDIR}/dotest.tmp`" : \ "$3"${ENDANCHOR} >/dev/null; then + # See below about writing this to the logfile. + cat ${TESTDIR}/dotest.tmp >>${LOGFILE} pass "$1" else if test x"$4" != x; then if $EXPR "`cat ${TESTDIR}/dotest.tmp`" : \ "$4"${ENDANCHOR} >/dev/null; then + # Why, I hear you ask, do we write this to the logfile + # even when the test passes? The reason is that the test + # may give us the regexp which we were supposed to match, + # but sometimes it may be useful to look at the exact + # text which was output. For example, suppose one wants + # to grep for a particular warning, and make _sure_ that + # CVS never hits it (even in cases where the tests might + # match it with .*). Or suppose one wants to see the exact + # date format output in a certain case (where the test will + # surely use a somewhat non-specific pattern). + cat ${TESTDIR}/dotest.tmp >>${LOGFILE} pass "$1" else echo "** expected: " >>${LOGFILE} @@ -466,6 +479,7 @@ RCSINIT=; export RCSINIT if test x"$*" = x; then tests="basica basicb basic1 deep basic2 rdiff death death2 branches multibranch import join new newb conflicts conflicts2 modules modules2 modules3 mflag errmsg1 devcom devcom2 devcom3 ignore binfiles binwrap info serverpatch log log2 crerepos rcs big modes" + tests="${tests} sticky keyword" else tests="$*" fi @@ -642,10 +656,23 @@ done' # Test the -f option to ci cd sdir/ssdir + dotest basica-8a0 "${testcvs} -q ci -m not-modified ssfile" '' dotest basica-8a "${testcvs} -q ci -f -m force-it" \ 'Checking in ssfile; /tmp/cvs-sanity/cvsroot/first-dir/sdir/ssdir/ssfile,v <-- ssfile new revision: 1\.3; previous revision: 1\.2 +done' + dotest basica-8a1 "${testcvs} -q ci -m bump-it -r 2.0" \ +'Checking in ssfile; +/tmp/cvs-sanity/cvsroot/first-dir/sdir/ssdir/ssfile,v <-- ssfile +new revision: 2\.0; previous revision: 1\.3 +done' + # -f should not be necessary, but it should be harmless. + # Also test the "-r 3" (rather than "-r 3.0") usage. + dotest basica-8a2 "${testcvs} -q ci -m bump-it -f -r 3" \ +'Checking in ssfile; +/tmp/cvs-sanity/cvsroot/first-dir/sdir/ssdir/ssfile,v <-- ssfile +new revision: 3\.1; previous revision: 2\.0 done' cd ../.. dotest basica-8b "${testcvs} -q diff -r1.2 -r1.3" \ @@ -704,6 +731,12 @@ done' : mkdir ${CVSROOT_DIRNAME}/first-dir dotest basicb-1 "${testcvs} -q co first-dir" '' dotest basicb-1a "test -d CVS" '' + # See comment at modules3-7f for more on this behavior. + dotest basicb-1b "cat CVS/Repository" \ +"${TESTDIR}/cvsroot/first-dir" "${TESTDIR}/cvsroot/\." + dotest basicb-1c "cat first-dir/CVS/Repository" \ +"${TESTDIR}/cvsroot/first-dir" + cd first-dir mkdir sdir1 sdir2 dotest basicb-2 "${testcvs} add sdir1 sdir2" \ @@ -790,13 +823,84 @@ U first-dir1/sdir2/sfile2' 'U newdir/sdir1/sfile1 U newdir/sdir2/sfile2' dotest basicb-9a "test -d CVS" '' + # See comment at modules3-7f for more on this behavior. + dotest basicb-9b "cat CVS/Repository" \ +"${TESTDIR}/cvsroot/first-dir" "${TESTDIR}/cvsroot/\." + dotest basicb-9c "cat newdir/CVS/Repository" \ +"${TESTDIR}/cvsroot/CVSROOT/Emptydir" dotest basicb-10 "cat newdir/sdir1/sfile1 newdir/sdir2/sfile2" \ "sfile1 develops sfile2 starts" rm -rf newdir + # Hmm, this might be a case for CVSNULLREPOS, but CVS doesn't + # seem to deal with it... + if false; then + dotest basicb-11 "${testcvs} -q co -d sub1/sub2 first-dir" \ +"U sub1/sub2/sdir1/sfile1 +U sub1/sub2/sdir2/sfile2" + cd sub1 + dotest basicb-12 "${testcvs} -q update" '' + touch xx + dotest basicb-13 "${testcvs} add xx" fixme + cd .. + rm -r sub1 + # to test: sub1/sub2/sub3 + fi # end of tests commented out. + + # Create a second directory. + mkdir 1 + cd 1 + dotest basicb-14 "${testcvs} -q co -l ." 'U topfile' + mkdir second-dir + dotest basicb-15 "${testcvs} add second-dir" \ +"Directory ${TESTDIR}/cvsroot/second-dir added to the repository" + cd second-dir + touch aa + dotest basicb-16 "${testcvs} add aa" \ +"${PROG} [a-z]*: scheduling file .aa. for addition +${PROG} [a-z]*: use .cvs commit. to add this file permanently" + dotest basicb-17 "${testcvs} -q ci -m add" \ +'RCS file: /tmp/cvs-sanity/cvsroot/second-dir/aa,v +done +Checking in aa; +/tmp/cvs-sanity/cvsroot/second-dir/aa,v <-- aa +initial revision: 1\.1 +done' + cd ../.. + rm -rf 1 + # Now here is the kicker: note that the semantics of -d + # are fundamentally different if we specify two or more directories + # rather than one! I consider this to be seriously bogus, + # but for the moment I am just trying to figure out what + # CVS's current behaviors are. + dotest basicb-18 "${testcvs} -q co -d test2 first-dir second-dir" \ +"U test2/first-dir/sdir1/sfile1 +U test2/first-dir/sdir2/sfile2 +U test2/second-dir/aa" + cd test2 + touch emptyfile + # The fact that CVS lets us add a file here is a CVS bug, right? + # I can just make this an error message (on the add and/or the + # commit) without getting flamed, right? + # Right? + # Right? + dotest basicb-19 "${testcvs} add emptyfile" \ +"${PROG} [a-z]*: scheduling file .emptyfile. for addition +${PROG} [a-z]*: use .cvs commit. to add this file permanently" + dotest basicb-20 "${testcvs} -q ci -m add" \ +'RCS file: /tmp/cvs-sanity/cvsroot/CVSROOT/Emptydir/emptyfile,v +done +Checking in emptyfile; +/tmp/cvs-sanity/cvsroot/CVSROOT/Emptydir/emptyfile,v <-- emptyfile +initial revision: 1\.1 +done' + cd .. + rm -rf test2 + rm -rf ${CVSROOT_DIRNAME}/first-dir + rm -rf ${CVSROOT_DIRNAME}/second-dir rm -f ${CVSROOT_DIRNAME}/topfile,v ;; @@ -2176,12 +2280,6 @@ ${PROG} [a-z]*: file3 is no longer in the repository" dotest_fail death2-20 "test -f file2" - # Make sure we can't add a file on this nonbranch tag. - # FIXME: Right now CVS will let you add a file on a - # nonbranch tag, so this test is commented out. - # echo "bad revision" > file2 - # dotest death2-21 "${testcvs} add file2" "some error message" - # Make sure diff only reports appropriate files. dotest_fail death2-diff-13 "${testcvs} -q diff -r rdiff-tag" \ "${PROG} [a-z]*: file1 is a new entry, no comparison available" @@ -3931,6 +4029,10 @@ done' cat >modules <>file1 + dotest sticky-6 "${testcvs} -q ci -m modify" \ +"Checking in file1; +${TESTDIR}/cvsroot/first-dir/file1,v <-- file1 +new revision: 1\.2; previous revision: 1\.1 +done" + dotest sticky-7 "${testcvs} -q update -r tag1" "[UP] file1" + dotest sticky-8 "cat file1" '' + dotest sticky-9 "${testcvs} -q update" '' + dotest sticky-10 "cat file1" '' + touch file2 + dotest_fail sticky-11 "${testcvs} add file2" \ +"${PROG} [a-z]*: cannot add file on non-branch tag tag1" + dotest sticky-12 "${testcvs} -q update -A" "[UP] file1 +${QUESTION} file2" "${QUESTION} file2 +[UP] file1" + dotest sticky-13 "${testcvs} add file2" \ +"${PROG} [a-z]*: scheduling file .file2. for addition +${PROG} [a-z]*: use .cvs commit. to add this file permanently" + + cd ../.. + rm -rf 1 ${CVSROOT_DIRNAME}/first-dir + ;; + + keyword) + # Test keyword expansion. + mkdir 1; cd 1 + dotest keyword-1 "${testcvs} -q co -l ." '' + mkdir first-dir + dotest keyword-2 "${testcvs} add first-dir" \ +"Directory ${TESTDIR}/cvsroot/first-dir added to the repository" + cd first-dir + + echo '$''Author$' > file1 + echo '$''Date$' >> file1 + echo '$''Header$' >> file1 + echo '$''Id$' >> file1 + echo '$''Locker$' >> file1 + echo '$''Name$' >> file1 + echo '$''RCSfile$' >> file1 + echo '$''Revision$' >> file1 + echo '$''Source$' >> file1 + echo '$''State$' >> file1 + echo '$''Nonkey$' >> file1 + # Omit the trailing dollar sign + echo '$''Date' >> file1 + # Put two keywords on one line + echo '$''State$' '$''State$' >> file1 + # Use a header for Log + echo 'xx $''Log$' >> file1 + + dotest keyword-3 "${testcvs} add file1" \ +"${PROG} [a-z]*: scheduling file .file1. for addition +${PROG} [a-z]*: use .cvs commit. to add this file permanently" + dotest keyword-4 "${testcvs} -q ci -m add" \ +"RCS file: ${TESTDIR}/cvsroot/first-dir/file1,v +done +Checking in file1; +${TESTDIR}/cvsroot/first-dir/file1,v <-- file1 +initial revision: 1\.1 +done" + dotest keyword-5 "cat file1" \ +'\$'"Author: ${username} "'\$'" +"'\$'"Date: [0-9][0-9][0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]:[0-9][0-9]:[0-9][0-9] "'\$'" +"'\$'"Header: ${TESTDIR}/cvsroot/first-dir/file1,v 1\.1 [0-9/]* [0-9:]* ${username} Exp "'\$'" +"'\$'"Id: file1,v 1\.1 [0-9/]* [0-9:]* ${username} Exp "'\$'" +"'\$'"Locker: "'\$'" +"'\$'"Name: "'\$'" +"'\$'"RCSfile: file1,v "'\$'" +"'\$'"Revision: 1\.1 "'\$'" +"'\$'"Source: ${TESTDIR}/cvsroot/first-dir/file1,v "'\$'" +"'\$'"State: Exp "'\$'" +"'\$'"Nonkey"'\$'" +"'\$'"Date +"'\$'"State: Exp "'\$'" "'\$'"State: Exp "'\$'" +xx "'\$'"Log: file1,v "'\$'" +xx Revision 1\.1 [0-9/]* [0-9:]* ${username} +xx add +xx" + + # Use cvs admin to lock the RCS file in order to check -kkvl + # vs. -kkv. CVS does not normally lock RCS files, but some + # people use cvs admin to enforce reserved checkouts. + dotest keyword-6 "${testcvs} admin -l file1" \ +"RCS file: ${TESTDIR}/cvsroot/first-dir/file1,v +1\.1 locked +done" + + dotest keyword-7 "${testcvs} update -kkv file1" "U file1" + dotest keyword-8 "cat file1" \ +'\$'"Author: ${username} "'\$'" +"'\$'"Date: [0-9][0-9][0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]:[0-9][0-9]:[0-9][0-9] "'\$'" +"'\$'"Header: ${TESTDIR}/cvsroot/first-dir/file1,v 1\.1 [0-9/]* [0-9:]* ${username} Exp "'\$'" +"'\$'"Id: file1,v 1\.1 [0-9/]* [0-9:]* ${username} Exp "'\$'" +"'\$'"Locker: "'\$'" +"'\$'"Name: "'\$'" +"'\$'"RCSfile: file1,v "'\$'" +"'\$'"Revision: 1\.1 "'\$'" +"'\$'"Source: ${TESTDIR}/cvsroot/first-dir/file1,v "'\$'" +"'\$'"State: Exp "'\$'" +"'\$'"Nonkey"'\$'" +"'\$'"Date +"'\$'"State: Exp "'\$'" "'\$'"State: Exp "'\$'" +xx "'\$'"Log: file1,v "'\$'" +xx Revision 1\.1 [0-9/]* [0-9:]* ${username} +xx add +xx" + + dotest keyword-9 "${testcvs} update -kkvl file1" "U file1" + dotest keyword-10 "cat file1" \ +'\$'"Author: ${username} "'\$'" +"'\$'"Date: [0-9][0-9][0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]:[0-9][0-9]:[0-9][0-9] "'\$'" +"'\$'"Header: ${TESTDIR}/cvsroot/first-dir/file1,v 1\.1 [0-9/]* [0-9:]* ${username} Exp ${username} "'\$'" +"'\$'"Id: file1,v 1\.1 [0-9/]* [0-9:]* ${username} Exp ${username} "'\$'" +"'\$'"Locker: ${username} "'\$'" +"'\$'"Name: "'\$'" +"'\$'"RCSfile: file1,v "'\$'" +"'\$'"Revision: 1\.1 "'\$'" +"'\$'"Source: ${TESTDIR}/cvsroot/first-dir/file1,v "'\$'" +"'\$'"State: Exp "'\$'" +"'\$'"Nonkey"'\$'" +"'\$'"Date +"'\$'"State: Exp "'\$'" "'\$'"State: Exp "'\$'" +xx "'\$'"Log: file1,v "'\$'" +xx Revision 1\.1 [0-9/]* [0-9:]* ${username} +xx add +xx" + + dotest keyword-11 "${testcvs} update -kk file1" "U file1" + dotest keyword-12 "cat file1" \ +'\$'"Author"'\$'" +"'\$'"Date"'\$'" +"'\$'"Header"'\$'" +"'\$'"Id"'\$'" +"'\$'"Locker"'\$'" +"'\$'"Name"'\$'" +"'\$'"RCSfile"'\$'" +"'\$'"Revision"'\$'" +"'\$'"Source"'\$'" +"'\$'"State"'\$'" +"'\$'"Nonkey"'\$'" +"'\$'"Date +"'\$'"State"'\$'" "'\$'"State"'\$'" +xx "'\$'"Log"'\$'" +xx Revision 1\.1 [0-9/]* [0-9:]* ${username} +xx add +xx" + + dotest keyword-13 "${testcvs} update -kv file1" "U file1" + dotest keyword-14 "cat file1" \ +"${username} +[0-9][0-9][0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]:[0-9][0-9]:[0-9][0-9] +${TESTDIR}/cvsroot/first-dir/file1,v 1\.1 [0-9/]* [0-9:]* ${username} Exp +file1,v 1\.1 [0-9/]* [0-9:]* ${username} Exp + + +file1,v +1\.1 +${TESTDIR}/cvsroot/first-dir/file1,v +Exp +"'\$'"Nonkey"'\$'" +"'\$'"Date +Exp Exp +xx file1,v +xx Revision 1\.1 [0-9/]* [0-9:]* ${username} +xx add +xx" + + dotest keyword-15 "${testcvs} update -ko file1" "U file1" + dotest keyword-16 "cat file1" \ +'\$'"Author"'\$'" +"'\$'"Date"'\$'" +"'\$'"Header"'\$'" +"'\$'"Id"'\$'" +"'\$'"Locker"'\$'" +"'\$'"Name"'\$'" +"'\$'"RCSfile"'\$'" +"'\$'"Revision"'\$'" +"'\$'"Source"'\$'" +"'\$'"State"'\$'" +"'\$'"Nonkey"'\$'" +"'\$'"Date +"'\$'"State"'\$'" "'\$'"State"'\$'" +xx "'\$'"Log"'\$' + + # Test the Name keyword. First go back to normal expansion. + + # FIXME: When using remote, update -A does not revert the + # keyword expansion mode. We work around that bug here. + # This workaround should be removed when the bug is fixed. + if test "x$remote" = "xyes"; then + cd .. + rm -rf first-dir + dotest keyword-17 "${testcvs} -q co first-dir" "U first-dir/file1" + cd first-dir + else + dotest keyword-17 "${testcvs} update -A file1" "U file1" + fi + + echo '$''Name$' > file1 + dotest keyword-18 "${testcvs} ci -m modify file1" \ +"Checking in file1; +${TESTDIR}/cvsroot/first-dir/file1,v <-- file1 +new revision: 1\.2; previous revision: 1\.1 +done" + dotest keyword-19 "${testcvs} -q tag tag1" "T file1" + echo "change" >> file1 + dotest keyword-20 "${testcvs} -q ci -m mod2 file1" \ +"Checking in file1; +${TESTDIR}/cvsroot/first-dir/file1,v <-- file1 +new revision: 1\.3; previous revision: 1\.2 +done" + dotest keyword-21 "${testcvs} -q update -r tag1" "[UP] file1" + + # FIXME: This test fails when remote. The second expect + # string below should be removed when this is fixed. + dotest keyword-22 "cat file1" '\$'"Name: tag1 "'\$' \ +'\$'"Name: "'\$' + + dotest keyword-23 "${testcvs} update -A file1" "[UP] file1" + + # Test the Log keyword. + echo 'xx $''Log$' > file1 + cat >${TESTDIR}/comment.tmp <> file1 + dotest keyword-26 "${testcvs} ci -m modify file1" \ +"Checking in file1; +${TESTDIR}/cvsroot/first-dir/file1,v <-- file1 +new revision: 1\.5; previous revision: 1\.4 +done" + dotest keyword-27 "cat file1" \ +"xx "'\$'"Log: file1,v "'\$'" +xx Revision 1\.5 [0-9/]* [0-9:]* ${username} +xx modify +xx +xx Revision 1\.4 [0-9/]* [0-9:]* ${username} +xx First log line +xx Second log line +xx +change" + + cd ../.. + rm -rf 1 ${CVSROOT_DIRNAME}/first-dir + ;; + *) echo $what is not the name of a test -- ignored ;; diff --git a/gnu/usr.bin/cvs/src/server.h b/gnu/usr.bin/cvs/src/server.h index e9c5807a53c..cb332250783 100644 --- a/gnu/usr.bin/cvs/src/server.h +++ b/gnu/usr.bin/cvs/src/server.h @@ -71,8 +71,7 @@ extern void server_clear_entstat PROTO((char *update_dir, char *repository)); /* Set or clear a per-directory sticky tag or date. */ extern void server_set_sticky PROTO((char *update_dir, char *repository, - char *tag, - char *date)); + char *tag, char *date, int nonbranch)); /* Send Template response. */ extern void server_template PROTO ((char *, char *)); diff --git a/gnu/usr.bin/cvs/src/status.c b/gnu/usr.bin/cvs/src/status.c index b794a2e43ab..67b71beb565 100644 --- a/gnu/usr.bin/cvs/src/status.c +++ b/gnu/usr.bin/cvs/src/status.c @@ -41,7 +41,7 @@ status (argc, argv) usage (status_usage); optind = 1; - while ((c = getopt (argc, argv, "vlR")) != -1) + while ((c = getopt (argc, argv, "+vlR")) != -1) { switch (c) { @@ -77,9 +77,13 @@ status (argc, argv) send_arg("-l"); send_file_names (argc, argv, SEND_EXPAND_WILD); - /* XXX This should only need to send file info; the file - contents themselves will not be examined. */ - send_files (argc, argv, local, 0, 0, 0); + /* Note that by setting SEND_NO_CONTENTS, we do prevent the + server from updating our timestamp if the timestamp is + unchanged and the file is unmodified. And I think it is a + user-visible thing in that case (shows "locally modified" + instead of "up to date" I would think). But the speed seems + to be worth it. */ + send_files (argc, argv, local, 0, SEND_NO_CONTENTS); send_to_server ("status\012", 0); err = get_responses_and_close (); diff --git a/gnu/usr.bin/cvs/src/tag.c b/gnu/usr.bin/cvs/src/tag.c index cee7aecbbe8..9c49da562bb 100644 --- a/gnu/usr.bin/cvs/src/tag.c +++ b/gnu/usr.bin/cvs/src/tag.c @@ -83,7 +83,7 @@ cvstag (argc, argv) usage (tag_usage); optind = 1; - while ((c = getopt (argc, argv, "FQqlRcdr:D:bf")) != -1) + while ((c = getopt (argc, argv, "+FQqlRcdr:D:bf")) != -1) { switch (c) { @@ -177,10 +177,14 @@ cvstag (argc, argv) send_arg (symtag); send_file_names (argc, argv, SEND_EXPAND_WILD); - /* FIXME: We shouldn't have to send current files, but I'm not sure - whether it works. So send the files -- - it's slower but it works. */ - send_files (argc, argv, local, 0, 0, 0); + + /* SEND_NO_CONTENTS has a mildly bizarre interaction with + check_uptodate; if the timestamp is modified but the file + is unmodified, the check will fail, only to have "cvs diff" + show no differences (and one must do "update" or something to + reset the client's notion of the timestamp). */ + + send_files (argc, argv, local, 0, SEND_NO_CONTENTS); send_to_server ("tag\012", 0); return get_responses_and_close (); } diff --git a/gnu/usr.bin/cvs/src/vers_ts.c b/gnu/usr.bin/cvs/src/vers_ts.c index d7420e7160d..03a0036202c 100644 --- a/gnu/usr.bin/cvs/src/vers_ts.c +++ b/gnu/usr.bin/cvs/src/vers_ts.c @@ -9,7 +9,7 @@ #include "cvs.h" #ifdef SERVER_SUPPORT -static void time_stamp_server PROTO((char *, Vers_TS *)); +static void time_stamp_server PROTO((char *, Vers_TS *, Entnode *)); #endif /* @@ -30,6 +30,7 @@ Version_TS (finfo, options, tag, date, force_tag_match, set_time) RCSNode *rcsdata; Vers_TS *vers_ts; struct stickydirtag *sdtp; + Entnode *entdata; /* get a new Vers_TS struct */ vers_ts = (Vers_TS *) xmalloc (sizeof (Vers_TS)); @@ -51,29 +52,40 @@ Version_TS (finfo, options, tag, date, force_tag_match, set_time) sdtp = (struct stickydirtag *) finfo->entries->list->data; /* list-private */ } + entdata = NULL; if (p != NULL) { - Entnode *entdata = (Entnode *) p->data; + entdata = (Entnode *) p->data; - vers_ts->vn_user = xstrdup (entdata->version); - vers_ts->ts_rcs = xstrdup (entdata->timestamp); - vers_ts->ts_conflict = xstrdup (entdata->conflict); - if (!tag) - { - if (!(sdtp && sdtp->aflag)) - vers_ts->tag = xstrdup (entdata->tag); - } - if (!date) - { - if (!(sdtp && sdtp->aflag)) - vers_ts->date = xstrdup (entdata->date); - } - if (!options || (options && *options == '\0')) +#ifdef SERVER_SUPPORT + /* An entries line with "D" in the timestamp indicates that the + client sent Is-modified without sending Entry. So we want to + use the entries line for the sole purpose of telling + time_stamp_server what is up; we don't want the rest of CVS + to think there is an entries line. */ + if (strcmp (entdata->timestamp, "D") != 0) +#endif { - if (!(sdtp && sdtp->aflag)) - vers_ts->options = xstrdup (entdata->options); + vers_ts->vn_user = xstrdup (entdata->version); + vers_ts->ts_rcs = xstrdup (entdata->timestamp); + vers_ts->ts_conflict = xstrdup (entdata->conflict); + if (!tag) + { + if (!(sdtp && sdtp->aflag)) + vers_ts->tag = xstrdup (entdata->tag); + } + if (!date) + { + if (!(sdtp && sdtp->aflag)) + vers_ts->date = xstrdup (entdata->date); + } + if (!options || (options && *options == '\0')) + { + if (!(sdtp && sdtp->aflag)) + vers_ts->options = xstrdup (entdata->options); + } + vers_ts->entdata = entdata; } - vers_ts->entdata = entdata; } /* @@ -114,7 +126,10 @@ Version_TS (finfo, options, tag, date, force_tag_match, set_time) else if (!vers_ts->entdata && (sdtp && sdtp->aflag == 0)) { if (!vers_ts->tag) + { vers_ts->tag = xstrdup (sdtp->tag); + vers_ts->nonbranch = sdtp->nonbranch; + } if (!vers_ts->date) vers_ts->date = xstrdup (sdtp->date); } @@ -177,7 +192,7 @@ Version_TS (finfo, options, tag, date, force_tag_match, set_time) { #ifdef SERVER_SUPPORT if (server_active) - time_stamp_server (finfo->file, vers_ts); + time_stamp_server (finfo->file, vers_ts, entdata); else #endif vers_ts->ts_user = time_stamp (finfo->file); @@ -195,9 +210,10 @@ Version_TS (finfo, options, tag, date, force_tag_match, set_time) #define mark_unchanged(V) ((V)->ts_user = xstrdup ((V)->ts_rcs)) static void -time_stamp_server (file, vers_ts) +time_stamp_server (file, vers_ts, entdata) char *file; Vers_TS *vers_ts; + Entnode *entdata; { struct stat sb; char *cp; @@ -215,11 +231,16 @@ time_stamp_server (file, vers_ts) lost. I don't know that that's right, but it's not clear to me that either choice is. Besides, would we have an RCS string in that case anyways? */ - if (vers_ts->entdata == NULL) + if (entdata == NULL) mark_lost (vers_ts); - else if (vers_ts->entdata->timestamp - && vers_ts->entdata->timestamp[0] == '=') + else if (entdata->timestamp + && entdata->timestamp[0] == '=') mark_unchanged (vers_ts); + else if (entdata->timestamp != NULL + && (entdata->timestamp[0] == 'M' + || entdata->timestamp[0] == 'D') + && entdata->timestamp[1] == '\0') + vers_ts->ts_user = xstrdup ("Is-modified"); else mark_lost (vers_ts); } diff --git a/gnu/usr.bin/cvs/src/version.c b/gnu/usr.bin/cvs/src/version.c index 8921e787a76..8e19b26bf35 100644 --- a/gnu/usr.bin/cvs/src/version.c +++ b/gnu/usr.bin/cvs/src/version.c @@ -12,7 +12,7 @@ #include "cvs.h" -char *version_string = "\nConcurrent Versions System (CVS) 1.9.6"; +char *version_string = "\nConcurrent Versions System (CVS) 1.9.8"; #ifdef CLIENT_SUPPORT #ifdef SERVER_SUPPORT diff --git a/gnu/usr.bin/cvs/src/watch.c b/gnu/usr.bin/cvs/src/watch.c index 51b50fcd10e..70deb7c3477 100644 --- a/gnu/usr.bin/cvs/src/watch.c +++ b/gnu/usr.bin/cvs/src/watch.c @@ -256,7 +256,7 @@ watch_addremove (argc, argv) the_args.edit = 0; the_args.unedit = 0; optind = 1; - while ((c = getopt (argc, argv, "la:")) != -1) + while ((c = getopt (argc, argv, "+la:")) != -1) { switch (c) { @@ -333,10 +333,7 @@ watch_addremove (argc, argv) send_arg ("none"); } send_file_names (argc, argv, SEND_EXPAND_WILD); - /* FIXME: We shouldn't have to send current files, but I'm not sure - whether it works. So send the files -- - it's slower but it works. */ - send_files (argc, argv, local, 0, 0, 0); + send_files (argc, argv, local, 0, SEND_NO_CONTENTS); send_to_server (the_args.adding ? "watch-add\012" : "watch-remove\012", 0); @@ -483,7 +480,7 @@ watchers (argc, argv) usage (watchers_usage); optind = 1; - while ((c = getopt (argc, argv, "l")) != -1) + while ((c = getopt (argc, argv, "+l")) != -1) { switch (c) { @@ -508,10 +505,7 @@ watchers (argc, argv) if (local) send_arg ("-l"); send_file_names (argc, argv, SEND_EXPAND_WILD); - /* FIXME: We shouldn't have to send current files, but I'm not sure - whether it works. So send the files -- - it's slower but it works. */ - send_files (argc, argv, local, 0, 0, 0); + send_files (argc, argv, local, 0, SEND_NO_CONTENTS); send_to_server ("watchers\012", 0); return get_responses_and_close (); } diff --git a/gnu/usr.bin/cvs/src/zlib.c b/gnu/usr.bin/cvs/src/zlib.c index 776e1bfb5e4..02ad70c2f53 100644 --- a/gnu/usr.bin/cvs/src/zlib.c +++ b/gnu/usr.bin/cvs/src/zlib.c @@ -11,11 +11,7 @@ This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ + GNU General Public License for more details. */ /* The routines in this file are the interface between the CVS client/server support and the zlib compression library. */ diff --git a/gnu/usr.bin/cvs/windows-NT/ChangeLog b/gnu/usr.bin/cvs/windows-NT/ChangeLog index 3ec249be90d..9db56c70e32 100644 --- a/gnu/usr.bin/cvs/windows-NT/ChangeLog +++ b/gnu/usr.bin/cvs/windows-NT/ChangeLog @@ -1,3 +1,46 @@ +Thu Apr 17 00:15:36 1997 Jim Kingdon + + * Makefile.in: Add sockerror.c. + +Wed Apr 9 15:29:45 1997 Jim Kingdon + + * filesubr.c (expand_wild): Add comments about "." and comparing + NULL pointers. + +8 Apr 1997 Jim Kingdon + + * rcmd.c: Instead of returning -1 and passing that back to + startserver.c which will print a very vague error message, call + error() right away with a specific message. This also fixes + some places where we had bogusly called GetLastError instead of + WSAGetLastError. + (init_winsock): Remove call to setsockopt. It was an artifact + from before the time that we defined NO_SOCKET_TO_FD, doesn't + seem to be needed any more, and fails with some non-Microsoft + winsock implementations. + +Wed Apr 2 14:08:10 1997 Vince Del Vecchio + and Jim Kingdon + + * sockerror.c: New file. + * config.h (SOCK_STRERROR, SOCK_ERRNO): New macros. + * startserver.c: In reporting errors from socket calls, use + SOCK_STRERROR and SOCK_ERRNO since strerror(errno) doesn't work + for Win32. + * rcmd.c (rcmd_authenticate): Use WSASetLastError instead of + assigning to errno, since that is where the caller will look. + +Sun Apr 6 17:22:19 1997 Jim Kingdon + + * filesubr.c (copy_file): Add comment about CopyFile. + +Wed Mar 26 13:13:41 1997 Jim Kingdon + + * README: Also mention tar and gzip. + + * README: Binaries are now under 1.9, not 1.8.3, on + ftp.cyclic.com. Also mention http URL. + 13 Mar 1997 Jim Kingdon * filesubr.c (get_homedir): Allocate pathbuf; removes arbitrary diff --git a/gnu/usr.bin/cvs/windows-NT/Makefile.in b/gnu/usr.bin/cvs/windows-NT/Makefile.in index 1798db912ee..f901edfe4e4 100644 --- a/gnu/usr.bin/cvs/windows-NT/Makefile.in +++ b/gnu/usr.bin/cvs/windows-NT/Makefile.in @@ -26,6 +26,7 @@ SOURCES = \ pwd.c \ rcmd.c \ run.c \ + sockerror.c \ startserver.c \ stripslash.c \ waitpid.c \ diff --git a/gnu/usr.bin/cvs/windows-NT/README b/gnu/usr.bin/cvs/windows-NT/README index f4115e9f7d2..2a821746b4b 100644 --- a/gnu/usr.bin/cvs/windows-NT/README +++ b/gnu/usr.bin/cvs/windows-NT/README @@ -50,9 +50,12 @@ following packages: ftp://ftp.netcom.com/pub/al/alexande/rcs57nt.zip ftp://ftp.netcom.com/pub/al/alexande/diff57nt.zip -Copies of these zip files can be also be found at: +Copies of these zip files can be also be found in the windows-nt +directory for the latest CVS release (cvs-1.9/windows-nt, for example) +under: - ftp://ftp.cyclic.com/pub/cvs/cvs-1.8.3/windows-nt + ftp://ftp.cyclic.com/pub/cvs/ or + http://www.cyclic.com/archive/pub/cvs/ If you want to try other versions of these utilities, you might have luck with the Congruent ports of these packages to Windows NT, binary @@ -60,6 +63,10 @@ and source: ftp://microlib.cc.utexas.edu/microlib/nt/gnu/ +In particular, microlib seems to have versions of GNU tar and gzip +which support long file names, which you will need to unpack the CVS +source distribution. + The CYGWIN32 package is a port of various GNU tools for NT, providing bash as the shell and gcc as the compiler. The tools are still in development, but they are useful for running a modified version of diff --git a/gnu/usr.bin/cvs/windows-NT/SCC/.cvsignore b/gnu/usr.bin/cvs/windows-NT/SCC/.cvsignore index fa65c0961ea..be11970367c 100644 --- a/gnu/usr.bin/cvs/windows-NT/SCC/.cvsignore +++ b/gnu/usr.bin/cvs/windows-NT/SCC/.cvsignore @@ -1,3 +1,4 @@ SCC.mdp SCC.ncb Debug +Makefile diff --git a/gnu/usr.bin/cvs/windows-NT/config.h b/gnu/usr.bin/cvs/windows-NT/config.h index abcf0189597..0fb42bf9d3b 100644 --- a/gnu/usr.bin/cvs/windows-NT/config.h +++ b/gnu/usr.bin/cvs/windows-NT/config.h @@ -314,6 +314,19 @@ extern void init_winsock(); it because _open_osfhandle doesn't work. */ #define NO_SOCKET_TO_FD 1 +/* This tells the client that, in addition to needing to use + send()/recv() to do socket I/O, the error codes for send()/recv() + and other socket operations are not available through errno. + Instead, this macro should be used to obtain an error code. */ +#define SOCK_ERRNO (WSAGetLastError ()) + +/* This tells the client that, in addition to needing to use + send()/recv() to do socket I/O, the error codes for send()/recv() + and other socket operations are not known to strerror. Instead, + this macro should be used to convert the error codes to strings. */ +#define SOCK_STRERROR sock_strerror +extern char *sock_strerror (int errnum); + /* The internal rsh client uses sockets not file descriptors. Note that as the code stands now, it often takes values from a SOCKET and puts them in an int. This is ugly but it seems like sizeof diff --git a/gnu/usr.bin/cvs/windows-NT/filesubr.c b/gnu/usr.bin/cvs/windows-NT/filesubr.c index da5a3c86230..6ad8d76359f 100644 --- a/gnu/usr.bin/cvs/windows-NT/filesubr.c +++ b/gnu/usr.bin/cvs/windows-NT/filesubr.c @@ -24,9 +24,13 @@ static int deep_remove_dir PROTO((const char *path)); -/* - * Copies "from" to "to". - */ +/* Copies "from" to "to". Note that the functionality here is similar + to the win32 function CopyFile, but (1) we copy LastAccessTime and + CopyFile doesn't, (2) we set file attributes to the default set by + the C library and CopyFile copies them. Neither #1 nor #2 was intentional + as far as I know, but changing them could be confusing, unless there + is some reason they should be changed (this would need more + investigation). */ void copy_file (from, to) const char *from; @@ -905,6 +909,14 @@ expand_wild (argc, argv, pargc, pargv) char *last_forw_slash, *last_back_slash, *end_of_dirname; int dirname_length = 0; + /* FIXME: If argv[i] is ".", this code will expand it to the + name of the current directory in its parent directory which + will cause start_recursion to do all manner of strange things + with it (culminating in an error). This breaks "cvs co .". + As nearly as I can guess, this bug has existed since + expand_wild was first created. At least, it is in CVS 1.9 (I + just tried it). */ + /* FindFirstFile doesn't return pathnames, so we have to do this ourselves. Luckily, it's no big deal, since globbing characters under Win32s can only occur in the last segment @@ -920,6 +932,9 @@ expand_wild (argc, argv, pargc, pargv) #define cvs_max(x,y) ((x >= y) ? (x) : (y)) + /* FIXME: this comparing a NULL pointer to a non-NULL one is + extremely ugly, and I strongly suspect *NOT* sanctioned by + ANSI C. The code should just use last_component instead. */ end_of_dirname = cvs_max (last_forw_slash, last_back_slash); if (end_of_dirname == NULL) diff --git a/gnu/usr.bin/cvs/windows-NT/rcmd.c b/gnu/usr.bin/cvs/windows-NT/rcmd.c index e0f3619ae45..d31cba2c04b 100644 --- a/gnu/usr.bin/cvs/windows-NT/rcmd.c +++ b/gnu/usr.bin/cvs/windows-NT/rcmd.c @@ -16,23 +16,21 @@ void init_winsock () { WSADATA data; - int optionValue = SO_SYNCHRONOUS_NONALERT; if (WSAStartup (MAKEWORD (1, 1), &data)) { fprintf (stderr, "cvs: unable to initialize winsock\n"); exit (1); } - - if (setsockopt(INVALID_SOCKET, SOL_SOCKET, - SO_OPENTYPE, (char *)&optionValue, sizeof(optionValue)) - == SOCKET_ERROR) - { - fprintf (stderr, "cvs: unable to setup winsock\n"); - exit (1); - } } +/* The rest of this file contains the rcmd() code, which is used + only by START_SERVER. The idea for a long-term direction is + that this code can be made portable (by using SOCK_ERRNO and + so on), and then moved to client.c or someplace it can be + shared with the VMS port and any other ports which may want it. */ + + static int resolve_address (const char **ahost, struct sockaddr_in *sai) { @@ -61,34 +59,9 @@ resolve_address (const char **ahost, struct sockaddr_in *sai) } } - return -1; + error (1, 0, "no such host %s", *ahost); } -#if 0 -static int -bind_local_end (SOCKET s) -{ - struct sockaddr_in sai; - int result; - u_short port; - - sai.sin_family = AF_INET; - sai.sin_addr.s_addr = htonl (INADDR_ANY); - - for (port = IPPORT_RESERVED - 2; port >= IPPORT_RESERVED/2; port--) - { - int error; - sai.sin_port = htons (port); - result = bind (s, (struct sockaddr *) &sai, sizeof (sai)); - error = GetLastError (); - if (result != SOCKET_ERROR || error != WSAEADDRINUSE) - break; - } - - return result; -} -#endif - static SOCKET bind_and_connect (struct sockaddr_in *server_sai) { @@ -103,41 +76,43 @@ bind_and_connect (struct sockaddr_in *server_sai) client_port >= IPPORT_RESERVED/2; client_port--) { - int result, error; + int result, errcode; client_sai.sin_port = htons (client_port); if ((s = socket (PF_INET, SOCK_STREAM, 0)) == INVALID_SOCKET) - return INVALID_SOCKET; + error (1, 0, "cannot create socket: %s", + SOCK_STRERROR (SOCK_ERRNO)); result = bind (s, (struct sockaddr *) &client_sai, sizeof (client_sai)); - error = GetLastError (); + errcode = SOCK_ERRNO; if (result == SOCKET_ERROR) { closesocket (s); - if (error == WSAEADDRINUSE) + if (errcode == WSAEADDRINUSE) continue; else - return INVALID_SOCKET; + error (1, 0, "cannot bind to socket: %s", + SOCK_STRERROR (errcode)); } result = connect (s, (struct sockaddr *) server_sai, sizeof (*server_sai)); - error = GetLastError (); + errcode = SOCK_ERRNO; if (result == SOCKET_ERROR) { closesocket (s); - if (error == WSAEADDRINUSE) + if (errcode == WSAEADDRINUSE) continue; else - return INVALID_SOCKET; + error (1, 0, "cannot connect to socket: %s", + SOCK_STRERROR (errcode)); } return s; } - /* We couldn't find a free port. */ - return INVALID_SOCKET; + error (1, 0, "cannot find free port"); } static int @@ -156,17 +131,21 @@ rcmd_authenticate (int fd, char *locuser, char *remuser, char *command) || (send (fd, locuser, strlen (locuser) + 1, 0) == SOCKET_ERROR) || (send (fd, remuser, strlen (remuser) + 1, 0) == SOCKET_ERROR) || (send (fd, command, strlen (command) + 1, 0) == SOCKET_ERROR)) - return -1; + error (1, 0, "cannot send authentication info to rshd: %s", + SOCK_STRERROR (SOCK_ERRNO)); /* They sniff our butt, and send us a '\0' character if they like us. */ { char c; - if (recv (fd, &c, 1, 0) == SOCKET_ERROR - || c != '\0') + if (recv (fd, &c, 1, 0) == SOCKET_ERROR) { - errno = EPERM; - return -1; + error (1, 0, "cannot receive authentication info from rshd: %s", + SOCK_STRERROR (SOCK_ERRNO)); + } + if (c != '\0') + { + error (1, 0, "Permission denied by rshd"); } } @@ -187,27 +166,15 @@ rcmd (const char **ahost, assert (fd2p == 0); if (resolve_address (ahost, &sai) < 0) - return -1; + error (1, 0, "internal error: resolve_address < 0"); sai.sin_port = htons (inport); -#if 0 - if ((s = socket (PF_INET, SOCK_STREAM, 0)) == INVALID_SOCKET) - return -1; - - if (bind_local_end (s) < 0) - return -1; - - if (connect (s, (struct sockaddr *) &sai, sizeof (sai)) - == SOCKET_ERROR) - return -1; -#else if ((s = bind_and_connect (&sai)) == INVALID_SOCKET) - return -1; -#endif + error (1, 0, "internal error: bind_and_connect < 0"); if (rcmd_authenticate (s, locuser, remuser, cmd) < 0) - return -1; + error (1, 0, "internal error: rcmd_authenticate < 0"); return s; } diff --git a/gnu/usr.bin/cvs/windows-NT/sockerror.c b/gnu/usr.bin/cvs/windows-NT/sockerror.c new file mode 100644 index 00000000000..ebc1a17e9e5 --- /dev/null +++ b/gnu/usr.bin/cvs/windows-NT/sockerror.c @@ -0,0 +1,136 @@ +/* sockerror.c --- convert WinSock error number to string + Vince Del Vecchio + + This file is part of GNU CVS. + + GNU CVS is free software; you can redistribute it and/or modify it + under the terms of the GNU General Public License as published by the + Free Software Foundation; either version 2, or (at your option) any + later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. */ + +#include +#include + +struct err_strs { + char **strs; + int first; + int last; +}; + +static char *errs1[] = { + /* EINTR */ "Interrupted system call" +}; + +static char *errs2[] = { + /* EBADF */ "Bad file descriptor" +}; + +static char *errs3[] = { + /* EACCES */ "Permission denied", + /* EFAULT */ "Bad address" +}; + +static char *errs4[] = { + /* EINVAL */ "Invalid argument" +}; + +static char *errs5[] = { + /* EMFILE */ "Too many open files", +}; + +static char *errs6[] = { + /* EWOULDBLOCK */ "Resource temporarily unavailable", + /* EINPROGRESS */ "Operation now in progress", + /* EALREADY */ "Operation already in progress", + /* ENOTSOCK */ "Socket operation on non-socket", + /* EDESTADDRREQ */ "Destination address required", + /* EMSGSIZE */ "Message too long", + /* EPROTOTYPE */ "Protocol wrong type for socket", + /* ENOPROTOOPT */ "Protocol not available", + /* EPROTONOSUPPORT */ "Protocol not supported", + /* ESOCKTNOSUPPORT */ "Socket type not supported", + /* EOPNOTSUPP */ "Operation not supported on socket", + /* EPFNOSUPPORT */ "Protocol family not supported", + /* EAFNOSUPPORT */ "Address family not supported by protocol", + /* EADDRINUSE */ "Address already in use", + /* EADDRNOTAVAIL */ "Can't assign requested address", + /* ENETDOWN */ "Network is down", + /* ENETUNREACH */ "Network is unreachable", + /* ENETRESET */ "Network connection dropped on reset", + /* ECONNABORTED */ "Software caused connection abort", + /* ECONNRESET */ "Connection reset by peer", + /* ENOBUFS */ "No buffer space available", + /* EISCONN */ "Socket is already connected", + /* ENOTCONN */ "Socket is not connected", + /* ESHUTDOWN */ "Can't send after socket shutdown", + /* ETOOMANYREFS */ "Too many references: can't splice", + /* ETIMEDOUT */ "Connection timed out", + /* ECONNREFUSED */ "Connection refused", + /* ELOOP */ "Too many levels of symbolic links", + /* ENAMETOOLONG */ "File name too long", + /* EHOSTDOWN */ "Host is down", + /* EHOSTUNREACH */ "No route to host", + /* ENOTEMPTY */ "Directory not empty", + /* EPROCLIM */ "Too many processes", + /* EUSERS */ "Too many users", + /* EDQUOT */ "Disc quota exceeded", + /* ESTALE */ "Stale NFS file handle", + /* EREMOTE */ "Object is remote" +}; + +static char *errs7[] = { + /* SYSNOTREADY */ "Network subsystem unavailable", + /* VERNOTSUPPORTED */ "Requested WinSock version not supported", + /* NOTINITIALISED */ "WinSock was not initialized" +}; + +#ifdef WSAEDISCON +static char *errs8[] = { + /* EDISCON */ "Graceful shutdown in progress" +}; +#endif + +static char *errs9[] = { + /* HOST_NOT_FOUND */ "Unknown host", + /* TRY_AGAIN */ "Host name lookup failure", + /* NO_RECOVERY */ "Unknown server error", + /* NO_DATA */ "No address associated with name", +}; + +/* Some of these errors are defined in the winsock.h header file I have, + but not in the Winsock 1.1 spec. I include them some of them anyway, + where it is not too hard to avoid referencing the symbolic constant. */ + +static struct err_strs sock_errlist[] = { + { errs1, WSAEINTR, WSAEINTR }, + { errs2, WSAEBADF, WSAEBADF }, + { errs3, WSAEACCES, WSAEFAULT }, + { errs4, WSAEINVAL, WSAEINVAL }, + { errs5, WSAEMFILE, WSAEMFILE }, + { errs6, WSAEWOULDBLOCK, WSAEHOSTUNREACH + 6 }, + { errs7, WSASYSNOTREADY, WSANOTINITIALISED }, +#ifdef WSAEDISCON + { errs8, WSAEDISCON, WSAEDISCON }, +#endif + { errs9, WSAHOST_NOT_FOUND, WSANO_DATA } +}; + +char * +sock_strerror (int errnum) +{ + static char buf[40]; + int i; + + for (i = 0; i < (sizeof sock_errlist / sizeof *sock_errlist); i++) + { + if (errnum >= sock_errlist[i].first && errnum <= sock_errlist[i].last) + return sock_errlist[i].strs[errnum - sock_errlist[i].first]; + } + sprintf(buf, "Unknown socket error: %d", errnum); + return buf; +} diff --git a/gnu/usr.bin/cvs/windows-NT/startserver.c b/gnu/usr.bin/cvs/windows-NT/startserver.c index 3de8cca6a7b..0856d972b20 100644 --- a/gnu/usr.bin/cvs/windows-NT/startserver.c +++ b/gnu/usr.bin/cvs/windows-NT/startserver.c @@ -46,7 +46,8 @@ wnt_start_server (int *tofd, int *fromfd, command, 0); if (read_fd < 0) - error (1, errno, "cannot start server via rcmd"); + error (1, 0, "cannot start server via rcmd: %s", + SOCK_STRERROR (SOCK_ERRNO)); *tofd = read_fd; *fromfd = read_fd; @@ -61,7 +62,9 @@ wnt_shutdown_server (int fd) s = fd; if (shutdown (s, 2) == SOCKET_ERROR) - error (1, 0, "couldn't shutdown server connection"); + error (1, 0, "couldn't shutdown server connection: %s", + SOCK_STRERROR (SOCK_ERRNO)); if (closesocket (s) == SOCKET_ERROR) - error (1, 0, "couldn't close server connection"); + error (1, 0, "couldn't close server connection: %s", + SOCK_STRERROR (SOCK_ERRNO)); }