Re: [patch] Create cleanups.[ch]

Sergio Durigan Junior
2012-04-19T17:33:02Z

On Wednesday, April 18 2012, Pedro Alves wrote:

> On 04/16/2012 07:50 PM, Sergio Durigan Junior wrote:
>
>> I always thought that the Copyright referred to the file itself, so if
>> you create a new file you should "restart" the Copyright notice even if
>> this file doesn't contain new things. After all, if you moved things
>> around, they were already covered by the copyright of the file which
>> they belonged before.
>
>
> But then if you follow that patch one extra step, you can rename
> the files back to their original names, and what you end up with
> is exactly with you started with, except you've lost all your copyright
> years. If that's okay, then I've just proven that a copyright year list
> is insignificant and unnecessary, and we can just go do a wholesale pass
> on the whole codebase replacing all the multiple years by a single
> "2012" year.

Turns out you are right. Here is the reply from FSF:

----

From: "Donald R Robertson III via RT" <copyright-clerk@fsf.org>
Subject: [gnu.org #745974] Question about Copyright notice on files
To: sergiodj@redhat.com
Date: Thu, 19 Apr 2012 13:01:52 -0400
Reply-To: copyright-clerk@fsf.org
X-Sent: 22 minutes, 40 seconds ago

Hello,

Thanks for checking in on this.

> [sergiodj@redhat.com - Wed Apr 18 01:59:09 2012]:
>
> Hello,
>
> On behalf of the GDB Project, I am sending you a question that arose
> while discussing some patch in the gdb-patches mailing list. The
> question is about the Copyright notice on files of the project. If you
> are interested in the discussion, please have a look at this specific
> thread:
>
> > http://sourceware.org/ml/gdb-patches/2012-04/msg00395.html>
> To make it "short": we would like to know if, when we move an already
> existing piece of code from one file (say `old-file.c', for example) to
> another, newly created file (say `new-file.c', which was created during
> this code movement), what should be the year specified in the Copyright
> notice above the file? If `old-file.c' has a copyright like this:
>
>
> > Copyright (C) 1986, 1988-2005, 2007-2012 Free Software Foundation, Inc.
>
> Should the `new-file.c' contain these same years on its own Copyright
> notice, or should it contain only the year when it was created, e.g.,
> supposing `new-file.c' was created today, should it display:
>
> > Copyright (C) 2012 Free Software Foundation, Inc.
>
> as the notice?
>
> Please correct me if I'm wrong, but if you prefer, maybe you can
> interpret this question as: "Is the Copyright notice related to the
> contents of the file, or to the file itself?"
>
> Thank you very much,

The short answer is that the notice relates to what is in the file.

This is the relevant section in the maintainers guide
(http://www.gnu.org/prep/maintain/maintain.html#Copyright-Notices):

"To update the list of year numbers, add each year in which you have made nontrivial changes to
the package. (Here we assume you’re using a publicly accessible revision control server, so that
every revision installed is also immediately and automatically published.) When you add the new
year, it is not required to keep track of which files have seen significant changes in the new
year and which have not. It is recommended and simpler to add the new year to all files in the
package, and be done with it for the rest of the year.

Don’t delete old year numbers, though; they are significant since they indicate when older
versions might theoretically go into the public domain, if the movie companies don’t continue
buying laws to further extend copyright. If you copy a file into the package from some other
program, keep the copyright years that come with the file."

As you can see, it turns on when changes are made, not when the file is created. Since the code
itself was created in previous years, we need to maintain those years in the copyright notice.
So in your example, the notice should read like this:

Copyright (C) 1986, 1988-2005, 2007-2012 Free Software Foundation, Inc.

As the manual notes, you can just add the most recent year to all non-trivial files, without
divining whether each individual file has been updated. I hope this answers your question but
let me know if you need any more information.

>
>
>
--
Sincerely,

Donald R. Robertson, III, J.D.
Assignment Administrator
Free Software Foundation
51 Franklin Street, Fifth Floor
Boston, MA 02110
Phone +1-617-542-5942
Fax +1-617-542-2652

---

--
Sergio