Subject: bug#5665: 23.1; VC commands fail when the version control back end is SCCS

From: Dan Nicolaescu <[email-masked]>
Date: Tue, 2 Mar 2010 11:07:20 -0800 (PST)

"Ron Mitchell" <[email-masked]> writes:

  > I can't send mail from the host system, so I used report-emacs-bug to
  > generate a mail which I've copied below.
  > 
  > From: "RON MITCHELL (UNIVERSE USER)" <rmitchel@tntcg004>
  > To: [email-masked]
  > Subject: 23.1; VC commands fail when the version control back end is
  > SCCS
  > --text follows this line--
  > 
  > I'm running emacs on HP-UX.  
  > 
  > Our SCCS repository is under location /common, as set in the environment
  > variable PROJECTDIR:
  > $ env | grep PROJECTDIR
  > PROJECTDIR=/common
  > $ 
  > 
  > I create a file called 'myfile' in the current directory.  It is not yet
  > registered to SCCS.
  > 
  > I visit the file.
  > 
  > Attempt to register the file with C-x v v
  > -----------------------------------------
  > 
  > It fails. There is an error message shown in the *vc* buffer:  
  > ERROR: missing file arg (cm3)
  > 
  > Backtrace:
  > 
  > Debugger entered--Lisp error: (error "Running sccs admin -r1.1 -fb
  > -imyfile -y ../../common/SCCS/s.myfile...FAILED (status 1)")
  >   signal(error ("Running sccs admin -r1.1 -fb -imyfile -y

[snip similar issues]

  > Preliminary Diagnosis
  > ---------------------
  > 
  > It seems to me that emacs is attempting to run the SCCS front-end
  > command, sccs(1), against the repository filename,
  > '/common/SCCS/s.myfile', instead of against the plain filename
  > 'myfile' as required.

VC with SCCS on a system that does not use the PROJECTDIR environment
variable seems to work fine.

PROJECTDIR is used in one place in vc-sccs.el: vc-sccs-search-project-dir.
That function does:
      (and dir (expand-file-name (concat "s." basename) dir)))

so it looks like your diagnosis is probably right.
The code in question has not changed in a very long time, so probably
PROJECDIR support never worked.
If you want to fix this vc-sccs-search-project-dir and maybe it's users
is what you'd have to change.