]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
disk-utils: add SPDX and Copyright notices
authorKarel Zak <kzak@redhat.com>
Wed, 1 Nov 2023 13:47:41 +0000 (14:47 +0100)
committerKarel Zak <kzak@redhat.com>
Wed, 1 Nov 2023 13:47:41 +0000 (14:47 +0100)
Explicitly state the license (usually GPL-2.0-or-later; our default)
and include copyright statements in all files to prevent false positive
reports from license analysis tools. Add also add SPDX-License-Identifier
tag to all files.

Signed-off-by: Karel Zak <kzak@redhat.com>
26 files changed:
README.licensing
disk-utils/addpart.c
disk-utils/blockdev.c
disk-utils/cfdisk.c
disk-utils/cramfs.h
disk-utils/cramfs_common.c
disk-utils/delpart.c
disk-utils/fdformat.c
disk-utils/fdisk-list.c
disk-utils/fdisk-list.h
disk-utils/fdisk-menu.c
disk-utils/fdisk.c
disk-utils/fdisk.h
disk-utils/fsck.c
disk-utils/fsck.cramfs.c
disk-utils/fsck.minix.c
disk-utils/isosize.c
disk-utils/minix_programs.h
disk-utils/mkfs.bfs.c
disk-utils/mkfs.c
disk-utils/mkfs.cramfs.c
disk-utils/mkfs.minix.c
disk-utils/mkswap.c
disk-utils/partx.c
disk-utils/resizepart.c
disk-utils/swaplabel.c

index 3258f55b58cb91897102f7a787677ae4c21ee22d..2af64624658118ae7f7776db50338c3c7a4d597a 100644 (file)
@@ -2,11 +2,13 @@
 The project util-linux doesn't use the same license for all of the code.
 There is code under:
 
-   * GPL-3.0-or-later   - GNU General Public License version 3, or any later version
+   * GPL-1.0-or-later   - GNU General Public License version 1, or any later version
+
+   * GPL-2.0            - GNU General Public License version 2
 
    * GPL-2.0-or-later   - GNU General Public License version 2, or any later version
 
-   * GPL-2.0            - GNU General Public License version 2
+   * GPL-3.0-or-later   - GNU General Public License version 3, or any later version
 
    * LGPL-2.1-or-later  - GNU Lesser General Public License 2.1 or any later version
 
index 2cf664b98f12f192bb3825b526a433197949d415..6bdb3366284d9da21c62f3fe5ecc6a040ec0fb63 100644 (file)
@@ -1,3 +1,13 @@
+/*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * Copyright (C) 2012-2023 Karel Zak <kzak@redhat.com>
+ */
 #include <getopt.h>
 #include <stdio.h>
 #include <stdlib.h>
index 22497d23ad8c4749717d66f69cc435a09bda04fe..92c02602b7a9986e3e096aec46690db27dbdec5f 100644 (file)
@@ -1,8 +1,16 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
  * blockdev.c --- Do various simple block device ioctls from the command line
  * aeb, 991028
+ *
+ * Copyright (C) 2007-2023 Karel Zak <kzak@redhat.com>
  */
-
 #include <stdio.h>
 #include <fcntl.h>
 #include <stdlib.h>
index 01069b7af2375b0f25a81c26563e391deeb6e0b1..9cf03464258a4bf7479a7f97468183345abe474a 100644 (file)
@@ -1,4 +1,11 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
  * cfdisk.c - Display or manipulate a disk partition table.
  *
  *     Copyright (C) 2014-2023 Karel Zak <kzak@redhat.com>
@@ -6,11 +13,6 @@
  *
  *     The original cfdisk was inspired by the fdisk program
  *           by A. V. Le Blanc (leblanc@mcc.ac.uk.
- *
- * cfdisk 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 of the License, or
- * (at your option) any later version.
  */
 #include <stdlib.h>
 #include <stdio.h>
index 43bbf526491cbc3e0f6494b188a17f78f82f6bc4..322dbf38af0c79c6af64f28f3202366d26337088 100644 (file)
@@ -1,4 +1,6 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
  * cramfs_common - cramfs common code
  *
  * Copyright (c) 2008 Roy Peled, the.roy.peled  -at-  gmail
@@ -13,9 +15,7 @@
  * 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.
- *
  */
-
 #ifndef __CRAMFS_H
 #define __CRAMFS_H
 
index 9fe3fa10550925ebdfbb478fefc92194cd0ec2e3..400b146cd4ba4cc8cd674a3a5c717a422262eabb 100644 (file)
@@ -1,4 +1,6 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
  * cramfs_common - cramfs common code
  *
  * Copyright (c) 2008 Roy Peled, the.roy.peled  -at-  gmail.com
index cd6bf5c55d9d476de2ae2b4034d1248f2d864599..85060699cefa26f978c6a77ffa4a48d522ab94ce 100644 (file)
@@ -1,3 +1,13 @@
+/*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * Copyright (C) 2012-2023 Karel Zak <kzak@redhat.com>
+ */
 #include <getopt.h>
 #include <stdio.h>
 #include <stdlib.h>
index e776a278d75ca61f9be64ce6c07279ada7f38bf0..ccd3942a8b6e250a9b59ac659323d610c84428ae 100644 (file)
@@ -1,4 +1,13 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * Copyright (C) 1992 Werner Almesberger
+ *
  * fdformat.c  -  Low-level formats a floppy disk - Werner Almesberger
  */
 #include <errno.h>
index 4080b757d3a19ffc43d920431e76d6d82b5981f0..26ae1bd1ebc242c8ec3e743aa97016cfd15c18d2 100644 (file)
@@ -1,3 +1,13 @@
+/*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * Copyright (C) 2014 Karel Zak <kzak@redhat.com>
+ */
 #include <libfdisk.h>
 #include <libsmartcols.h>
 #include <assert.h>
index 6c7552892815ae3a5bc481875ff3fd2bce5765a8..a30cd6a5159c4e082c05d257ef95a32f1c3a7951 100644 (file)
@@ -1,3 +1,13 @@
+/*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * Copyright (C) 2014-2023 Karel Zak <kzak@redhat.com>
+ */
 #ifndef UTIL_LINUX_FDISK_LIST_H
 #define UTIL_LINUX_FDISK_LIST_H
 
index 52282dde614b8665dd996ba8009ccc21b568f624..5cf00026ae377b5d8a2e0d6d16b9f2ea5073c09d 100644 (file)
@@ -1,4 +1,13 @@
-
+/*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * Copyright (C) 2014 Karel Zak <kzak@redhat.com>
+ */
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
index c5c5f0fc713b6a9d9ab03c8a130283930f6875aa..7c04cb5ff729e168f84f2e27fb4c3bdb2c9163de 100644 (file)
@@ -1,13 +1,15 @@
 /*
+ * SPDX-License-Identifier: GPL-1.0-or-later
+ *
+ * This program 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 1 of the License, or
+ * (at your option) any later version.
+ *
  * Copyright (C) 1992  A. V. Le Blanc (LeBlanc@mcc.ac.uk)
  * Copyright (C) 2012  Davidlohr Bueso <dave@gnu.org>
  *
  * Copyright (C) 2007-2013 Karel Zak <kzak@redhat.com>
- *
- * This program 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 1 or
- * (at your option) any later version.
  */
 #include <unistd.h>
 #include <stdio.h>
index e1147e20bfdec0a508135ccf64b98da6d0ef8c57..e7edc0651e708d0f8009567874a9e31816a79c0a 100644 (file)
@@ -1,3 +1,13 @@
+/*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * Copyright (C) 2014-2023 Karel Zak <kzak@redhat.com>
+ */
 #ifndef UTIL_LINUX_FDISK_H
 #define UTIL_LINUX_FDISK_H
 /*
index 49f1b995d71039a8c36bfea52de26c7d1bfa2d34..2a54dc5d1cff052c5fec7dc66354f329c8be5804 100644 (file)
@@ -1,4 +1,12 @@
 /*
+ *
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
  * fsck --- A generic, parallelizing front-end for the fsck program.
  * It will automatically try to run fsck programs in parallel if the
  * devices are on separate spindles.  It is based on the same ideas as
  *              2001, 2002, 2003, 2004, 2005 by  Theodore Ts'o.
  *
  * Copyright (C) 2009-2014 Karel Zak <kzak@redhat.com>
- *
- * This file may be redistributed under the terms of the GNU Public
- * License.
  */
-
 #define _XOPEN_SOURCE 600 /* for inclusion of sa_handler in Solaris */
 
 #include <sys/types.h>
index 789a9b5cfad99d835b6570fabc122c0c30e9efae..b5d64c36aa6c401ad04f7e7e6b422121c2d7fac7 100644 (file)
@@ -1,4 +1,6 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
  * cramfsck - check a cramfs file system
  *
  * Copyright (C) 2000-2002 Transmeta Corporation
index 11b10562cca84a3806050c8b5d7061541e5ea544..03a47460ecb88ae374eacbb41a7edda0639c0d4b 100644 (file)
@@ -1,11 +1,17 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
  * fsck.minix.c - a file system consistency checker for Linux.
  *
  * (C) 1991, 1992 Linus Torvalds. This file may be redistributed
  * as per the GNU copyleft.
- */
-
-/*
+ *
+ *
  * 09.11.91  -  made the first rudimentary functions
  *
  * 10.11.91  -  updated, does checking, no repairs yet.
index bd74e93d032a9c7fea9f05701cc98e3e46755d16..a0b2b87cdc83f47278687efa96f76e634e70d6d8 100644 (file)
@@ -1,5 +1,13 @@
 /*
- * isosize.c - Andries Brouwer, 000608
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * Copyright (C) 2000 Andries Brouwer
+ * Copyright (C) 2023 Karel Zak <kzak@redhat.com>
  *
  * use header info to find size of iso9660 file system
  * output a number - useful in scripts
@@ -16,7 +24,6 @@
  *     - add "-d <num>" option and use long long to fix things > 2 GB
  *  Version 2.02 2000/10/11
  *     - error messages on IO failures [D. Gilbert]
- *
  */
 #include <stdio.h>
 #include <stdlib.h>
index 7ad308d3cc7af66c7475342e530b73fcf52b6418..2bb311ceefbc42318290c69c92da5ae9a3b0cea7 100644 (file)
@@ -1,3 +1,13 @@
+/*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * Copyright (C) 2011 Sami Kerola <kerolasa@iki.fi>
+ */
 #ifndef UTIL_LINUX_MINIX_PROGRAMS_H
 #define UTIL_LINUX_MINIX_PROGRAMS_H
 
index 866776b7d7daad02c0413b4655729257b7d72bf2..895a1f27b7a5c242b60a1571fca8129f3c308d98 100644 (file)
@@ -1,9 +1,17 @@
 /*
- *  mkfs.bfs - Create SCO BFS filesystem - aeb, 1999-09-07
+ * SPDX-License-Identifier: GPL-2.0-or-later
  *
- *     Usage: mkfs.bfs [-N nr-of-inodes] [-V volume-name] [-F fsname] device
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * mkfs.bfs - Create SCO BFS filesystem - aeb, 1999-09-07
+ *
+ * Copyright (C) 1999 Andries E. Brouwe
+ *
+ * Usage: mkfs.bfs [-N nr-of-inodes] [-V volume-name] [-F fsname] device
  */
-
 #include <errno.h>
 #include <fcntl.h>
 #include <getopt.h>
index 58856d87160ef112ac82e445e4282dc50823dfb9..00d224f9b4e45145fe91fbe2487cd7de24699693 100644 (file)
@@ -1,10 +1,17 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
  * mkfs                A simple generic frontend for the mkfs program
  *             under Linux.  See the manual page for details.
  *
- * Authors:    David Engel, <david@ods.com>
- *             Fred N. van Kempen, <waltje@uWalt.NL.Mugnet.ORG>
- *             Ron Sommeling, <sommel@sci.kun.nl>
+ * Copyright (C) David Engel, <david@ods.com>
+ * Copyright (C) Fred N. van Kempen, <waltje@uWalt.NL.Mugnet.ORG>
+ * Copyright (C) Ron Sommeling, <sommel@sci.kun.nl>
  *
  * Mon Jul  1 18:52:58 1996: janl@math.uio.no (Nicolai Langfeldt):
  *     Incorporated fix by Jonathan Kamens <jik@annex-1-slip-jik.cam.ov.com>
index 482375351953f55b7b76c03c919c0a025c2949b8..840ec8d55867b7b351df58cb86cfc047a0ce0d63 100644 (file)
@@ -1,4 +1,6 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
  * mkcramfs - make a cramfs file system
  *
  * Copyright (C) 1999-2002 Transmeta Corporation
index 334f07fc0a28a69bc55cdd4cd52dde239fbbbdf3..f6f2f489611fefb84efe6d84d69771045eea80d8 100644 (file)
@@ -1,11 +1,15 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
  * mkfs.minix.c - make a linux (minix) file-system.
  *
  * (C) 1991 Linus Torvalds. This file may be redistributed as per
  * the Linux copyright.
- */
-
-/*
+*
  * DD.MM.YY
  *
  * 24.11.91  - Time began. Used the fsck sources to get started.
index 3d988b7376dda8fa17cb0abe4f754a46d96f931d..9280af1262e9a32fb322aa22d124ed164b4bf31d 100644 (file)
@@ -1,4 +1,11 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
  * mkswap.c - set up a linux swap device
  *
  * Copyright (C) 1991 Linus Torvalds
index dc6bac33bc5492dd6bc3553374734c315aff54b4..b0d552c3cf4d267ebaa29097b382fa4e8177e7c1 100644 (file)
@@ -1,4 +1,12 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ *
  * partx: tell the kernel about your disk's partitions
  * [This is not an fdisk - adding and removing partitions
  * is not a change of the disk, but just telling the kernel
@@ -10,7 +18,6 @@
  *      Rewritten to use libblkid for util-linux
  *      based on ideas from Karel Zak <kzak@redhat.com>
  */
-
 #include <stdio.h>
 #include <errno.h>
 #include <stdlib.h>
index df5ee73069f350619f87945b02dc00bf5dd9d7dd..e29021b3758c80ad230e024eb8923ecf0bafb381 100644 (file)
@@ -1,3 +1,13 @@
+/*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
+ * This program 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 of the License, or
+ * (at your option) any later version.
+ *
+ * Copyright (C) 2012 Karel Zak <kzak@redhat.com>
+ */
 #include <getopt.h>
 #include <stdio.h>
 #include <stdlib.h>
index b804a92bc31de459b9781febb3fb87c9af54c6fb..6b5078677fba7ef7de770623564e68e9e38cee0a 100644 (file)
@@ -1,4 +1,6 @@
 /*
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ *
  * swaplabel.c - Print or change the label / UUID of a swap partition
  *
  * Copyright (C) 2010 Jason Borden <jborden@bluehost.com>