From 905593af060a0c001d6e8caadf831243085c1db7 Mon Sep 17 00:00:00 2001 From: Jonathan Wakely Date: Tue, 10 Jun 2025 09:56:05 +0100 Subject: [PATCH] libstdc++: Improve documentation on copyright notices in new tests Clarify that FSF copyright notices in tests are incorrect for contributions under DCO terms. Clarify the sentence about copying existing tests to clarify that it is only referring to copying the code in the test file, rather than just copying an existing file as a template for a new test. libstdc++-v3/ChangeLog: * doc/xml/manual/test.xml: Improve discussion of copyright notices in new test cases. * doc/html/manual/test.html: Regenerate. --- libstdc++-v3/doc/html/manual/test.html | 11 ++++++++--- libstdc++-v3/doc/xml/manual/test.xml | 12 +++++++++--- 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/libstdc++-v3/doc/html/manual/test.html b/libstdc++-v3/doc/html/manual/test.html index f6776f2e041..497ee1ad36e 100644 --- a/libstdc++-v3/doc/html/manual/test.html +++ b/libstdc++-v3/doc/html/manual/test.html @@ -389,10 +389,15 @@ cat 27_io/objects/char/3_xin.in | a.out
DCO terms. + If new tests do add the FSF copyright notice and GPL licence text, then the first copyright year should correspond to the date - the file was checked in to version control. If a test is copied from - an existing file it should retain the copyright years from the + the file was checked in to version control. If the test code is copied + from an existing file it should retain the copyright years from the original file.

The DejaGnu instructions say to always return 0 diff --git a/libstdc++-v3/doc/xml/manual/test.xml b/libstdc++-v3/doc/xml/manual/test.xml index f0139dfd793..df49f56b0d0 100644 --- a/libstdc++-v3/doc/xml/manual/test.xml +++ b/libstdc++-v3/doc/xml/manual/test.xml @@ -650,10 +650,16 @@ cat 27_io/objects/char/3_xin.in | a.out We no longer require that, because most tests are uninteresting and contain no "original authorship", and so would not be protected by copyright anyway. - If you do want to add the FSF copyright notice and GPL licence text, + Adding the FSF copyright notice to new tests is incorrect unless you + (or your employer) have a copyright assignment on file with the FSF, + or if the test contains code copied from another test under FSF copyright. + In particular, new tests that contain original code are not copyright FSF + if contributed under the DCO terms. + If new tests do add the FSF copyright notice and GPL licence text, then the first copyright year should correspond to the date - the file was checked in to version control. If a test is copied from - an existing file it should retain the copyright years from the + the file was checked in to version control. If the test code is copied + from an existing file it should retain the copyright years from the original file. -- 2.47.2