GDB (xrefs)
Functions | Variables
copyright Namespace Reference

Functions

def get_update_list ()
 
def update_files (update_list)
 
def may_have_copyright_notice (filename)
 
def main ()
 

Variables

tuple EXCLUDE_LIST
 Some constants, placed at the end because they take up a lot of room. More...
 
tuple EXCLUDE_ALL_LIST
 
tuple BY_HAND
 
 MULTIPLE_COPYRIGHT_HEADERS
 
 NOT_FSF_LIST
 

Function Documentation

◆ get_update_list()

def copyright.get_update_list ( )
Return the list of files to update.

Assumes that the current working directory when called is the root
of the GDB source tree (NOT the gdb/ subdirectory!).  The names of
the files are relative to that root directory.

Definition at line 39 of file copyright.py.

Referenced by main().

◆ main()

def copyright.main ( )
The main subprogram.

Definition at line 142 of file copyright.py.

References get_update_list(), exsummary.help_and_exit(), exsummary.main(), and exsummary.mark_functions().

Referenced by maintenance_set_profile_cmd().

◆ may_have_copyright_notice()

def copyright.may_have_copyright_notice (   filename)
Check that the given file does not seem to have a copyright notice.

The filename is relative to the root directory.
This function assumes that the current working directory is that root
directory.

The algorigthm is fairly crude, meaning that it might return
some false positives.  I do not think it will return any false
negatives...  We might improve this function to handle more
complex cases later...

Definition at line 113 of file copyright.py.

Referenced by update_files().

◆ update_files()

def copyright.update_files (   update_list)
Update the copyright header of the files in the given list.

We use gnulib's update-copyright script for that.

Definition at line 70 of file copyright.py.

References may_have_copyright_notice().

Variable Documentation

◆ BY_HAND

tuple copyright.BY_HAND
Initial value:
1 = (
2  # Nothing at the moment :-).

Definition at line 202 of file copyright.py.

◆ EXCLUDE_ALL_LIST

tuple copyright.EXCLUDE_ALL_LIST
Initial value:
1 = (
2  "COPYING", "COPYING.LIB", "CVS", "configure", "copying.c",
3  "fdl.texi", "gpl.texi", "aclocal.m4",
4 )

Definition at line 196 of file copyright.py.

◆ EXCLUDE_LIST

tuple copyright.EXCLUDE_LIST
Initial value:
1 = (
2  'gdb/nat/glibc_thread_db.h',
3  'gdb/CONTRIBUTE',
4  'gdb/gnulib/import'
5 )

Some constants, placed at the end because they take up a lot of room.

The actual value of these constants is not significant to the understanding of the script.

Definition at line 182 of file copyright.py.

◆ MULTIPLE_COPYRIGHT_HEADERS

copyright.MULTIPLE_COPYRIGHT_HEADERS

Definition at line 209 of file copyright.py.

◆ NOT_FSF_LIST

copyright.NOT_FSF_LIST

Definition at line 217 of file copyright.py.