From 4acc3dbcccee343a027bfbb8119920046009e433 Mon Sep 17 00:00:00 2001 From: "H. Peter Anvin" Date: Wed, 1 Oct 2025 12:05:34 -0700 Subject: [PATCH] Fix more license headers --- Makefile.in | 10 ++++------ Mkfiles/msvc.mak | 8 ++++---- doc/Makefile.in | 4 ++++ headers/asm | 3 +++ headers/c | 2 +- headers/doc | 2 +- headers/mac | 2 -- headers/make | 3 +++ headers/perl | 3 ++- headers/sh | 2 +- misc/Makefile.in | 4 ++++ nasm.spec.in | 3 +++ tools/spdx.pl | 3 ++- 13 files changed, 32 insertions(+), 17 deletions(-) create mode 100644 headers/asm delete mode 100644 headers/mac create mode 100644 headers/make diff --git a/Makefile.in b/Makefile.in index 2f49992a..30886f5a 100644 --- a/Makefile.in +++ b/Makefile.in @@ -1,10 +1,8 @@ -# +# -*- makefile -*- +# SPDX-License-Identifier: BSD-2-Clause +# Copyright 1996-2025 The NASM Authors - All Rights Reserved + # Auto-configuring Makefile for the Netwide Assembler. -# -# The Netwide Assembler is copyright (C) 1996 Simon Tatham and -# Julian Hall. All rights reserved. The software is -# redistributable under the license given in the file "LICENSE" -# distributed in the NASM archive. @SET_MAKE@ diff --git a/Mkfiles/msvc.mak b/Mkfiles/msvc.mak index 6cfa555a..a8fe93ad 100644 --- a/Mkfiles/msvc.mak +++ b/Mkfiles/msvc.mak @@ -1,11 +1,11 @@ # -*- makefile -*- +# SPDX-License-Identifier: BSD-2-Clause +# Copyright 1996-2025 The NASM Authors - All Rights Reserved # # Makefile for building NASM using Microsoft Visual C++ and NMAKE. -# Tested on Microsoft Visual C++ 2005 Express Edition. -# -# Make sure to put the appropriate directories in your PATH, in -# the case of MSVC++ 2005, they are ...\VC\bin and ...\Common7\IDE. +# Last tested on Visual Studio 2022 Community Edition. # +# Make sure to have the proper directories in your path. # This is typically done by opening the Visual Studio Command Prompt. # diff --git a/doc/Makefile.in b/doc/Makefile.in index 484f718a..6a0b0f1b 100644 --- a/doc/Makefile.in +++ b/doc/Makefile.in @@ -1,3 +1,7 @@ +# -*- makefile -*- +# SPDX-License-Identifier: BSD-2-Clause +# Copyright 1996-20xx The NASM Authors - All Rights Reserved + # # UNIX Makefile for NASM documentation # diff --git a/headers/asm b/headers/asm new file mode 100644 index 00000000..b754016d --- /dev/null +++ b/headers/asm @@ -0,0 +1,3 @@ +;; -*- nasm -*- +;; SPDX-License-Identifier: BSD-2-Clause +;; Copyright 1996-20xx The NASM Authors - All Rights Reserved diff --git a/headers/c b/headers/c index 0db4c333..3edc0644 100644 --- a/headers/c +++ b/headers/c @@ -1,2 +1,2 @@ /* SPDX-License-Identifier: BSD-2-Clause */ -/* Copyright 1996-2010 The NASM Authors - All Rights Reserved */ +/* Copyright 1996-20xx The NASM Authors - All Rights Reserved */ diff --git a/headers/doc b/headers/doc index 1992e040..bc1a7026 100644 --- a/headers/doc +++ b/headers/doc @@ -1,2 +1,2 @@ \# SPDX-License-Identifier: BSD-2-Clause -\# Copyright 1996-2010 The NASM Authors - All Rights Reserved +\# Copyright 1996-20xx The NASM Authors - All Rights Reserved diff --git a/headers/mac b/headers/mac deleted file mode 100644 index 99f22c39..00000000 --- a/headers/mac +++ /dev/null @@ -1,2 +0,0 @@ -;; SPDX-License-Identifier: BSD-2-Clause -;; Copyright 1996-2010 The NASM Authors - All Rights Reserved diff --git a/headers/make b/headers/make new file mode 100644 index 00000000..3b5e4af2 --- /dev/null +++ b/headers/make @@ -0,0 +1,3 @@ +# -*- makefile -*- +# SPDX-License-Identifier: BSD-2-Clause +# Copyright 1996-20xx The NASM Authors - All Rights Reserved diff --git a/headers/perl b/headers/perl index 1fd62ef9..728636ab 100644 --- a/headers/perl +++ b/headers/perl @@ -1,2 +1,3 @@ +#!/usr/bin/perl - # SPDX-License-Identifier: BSD-2-Clause -# Copyright 1996-2010 The NASM Authors - All Rights Reserved +# Copyright 1996-20xx The NASM Authors - All Rights Reserved diff --git a/headers/sh b/headers/sh index 3f0bee05..87acda3b 100644 --- a/headers/sh +++ b/headers/sh @@ -1,3 +1,3 @@ -#!/bin/sh +#!/bin/sh - # Copyright 1996-20xx The NASM Authors - All Rights Reserved # SPDX-License-Identifier: BSD-2-Clause diff --git a/misc/Makefile.in b/misc/Makefile.in index 72628522..fecd4cf6 100644 --- a/misc/Makefile.in +++ b/misc/Makefile.in @@ -1,3 +1,7 @@ +# -*- makefile -*- +# SPDX-License-Identifier: BSD-2-Clause +# Copyright 1996-2025 The NASM Authors - All Rights Reserved + # # Makefile for various extra NASM programs and files # diff --git a/nasm.spec.in b/nasm.spec.in index 2e83ab58..d6896c28 100644 --- a/nasm.spec.in +++ b/nasm.spec.in @@ -1,4 +1,7 @@ # -*- coding: utf-8 -*- +# SPDX-License-Identifier: BSD-2-Clause +# Copyright 1996-2025 The NASM Authors - All Rights Reserved + %define nasm_version @@NASM_VER@@ Summary: The Netwide Assembler, a portable x86 assembler with Intel-like syntax Name: nasm diff --git a/tools/spdx.pl b/tools/spdx.pl index 700631d8..50ccc98c 100755 --- a/tools/spdx.pl +++ b/tools/spdx.pl @@ -57,7 +57,8 @@ foreach my $file (@ARGV) { $nsuf = ' */'; } my @hdr = (); - if (scalar(@lines) && $lines[0] =~ /^\#\!/) { + # Shebang and emacs mode lines should be left at the top + while (scalar(@lines) && $lines[0] =~ /^(?:\#\!|.*\-\*\-)/) { push(@hdr, shift(@lines)); } push(@hdr, $npfx.'SPDX-License-Identifier: BSD-2-Clause'.$nsuf);