[SCM] hydrogen packaging branch, master, updated. 0e5b279b27fcef251c185d059977342af18424f9

js at users.alioth.debian.org js at users.alioth.debian.org
Wed Mar 10 13:53:59 UTC 2010


The following commit has been merged in the master branch:
commit 01b8fc47c466fd6ded8f00181cc71f86c6699329
Author: Jonas Smedegaard <dr at jones.dk>
Date:   Mon Mar 8 13:52:15 2010 +0100

    Drop local copyright-check.mk: In utils.mk since cdbs 0.4.69.

diff --git a/debian/cdbs/1/rules/copyright-check.mk b/debian/cdbs/1/rules/copyright-check.mk
deleted file mode 100644
index 7ae8076..0000000
--- a/debian/cdbs/1/rules/copyright-check.mk
+++ /dev/null
@@ -1,136 +0,0 @@
-# -*- mode: makefile; coding: utf-8 -*-
-# Copyright © 2005-2010 Jonas Smedegaard <dr at jones.dk>
-# Description: Check for changes to copyright notices in source
-#
-# 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, or (at
-# your option) any later version.
-#
-# This program is distributed in the hope that it will be useful, 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.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.
-
-_cdbs_scripts_path ?= /usr/lib/cdbs
-_cdbs_rules_path ?= /usr/share/cdbs/1/rules
-_cdbs_class_path ?= /usr/share/cdbs/1/class
-
-ifndef _cdbs_rules_copyright_check
-_cdbs_rules_copyright_check := 1
-
-include $(_cdbs_rules_path)/buildcore.mk$(_cdbs_makefile_suffix)
-
-CDBS_BUILD_DEPENDS := $(CDBS_BUILD_DEPENDS), devscripts (>= 2.10.7)
-
-# Routines convenient for maintainers but unsuitable for build daemons
-#  * strict checking makes rule fail if changed/new hints are found
-ifneq (,$(DEB_MAINTAINER_MODE))
-  DEB_COPYRIGHT_CHECK_STRICT = yes
-endif
-
-# Single regular expression for files to include or ignore
-DEB_COPYRIGHT_CHECK_REGEX ?= .*
-DEB_COPYRIGHT_CHECK_IGNORE_REGEX ?= ^\./debian/(changelog|copyright(|_hints|_newhints))$
-
-# number of lines from the top of each file to investigate
-DEB_COPYRIGHT_CHECK_PARSELINES ?= 99999
-
-DEB_COPYRIGHT_CHECK_SCRIPT ?= licensecheck
-DEB_COPYRIGHT_CHECK_ARGS ?= -c '$(DEB_COPYRIGHT_CHECK_REGEX)' -r --copyright -i '$(DEB_COPYRIGHT_CHECK_IGNORE_REGEX)' -l '$(DEB_COPYRIGHT_CHECK_PARSELINES)' ./*
-DEB_COPYRIGHT_CHECK_INVOKE ?= $(DEB_COPYRIGHT_CHECK_SCRIPT) $(DEB_COPYRIGHT_CHECK_ARGS)
-
-pre-build:: debian/stamp-copyright-check
-debian/stamp-copyright-check:
-	@echo 'Scanning upstream source for new/changed copyright notices...'
-	@echo $(DEB_COPYRIGHT_CHECK_INVOKE) \
-		"| some-output-filtering..."
-
-# Perl in shell in make requires extra care:
-#  * Single-quoting ('...') protects against shell expansion
-#  * Double-dollar ($$) expands to plain dollar ($) in make
-	@export LC_ALL=C; $(DEB_COPYRIGHT_CHECK_INVOKE) \
-		| perl -e \
-	'print "Format-Specification: http://svn.debian.org/wsvn/dep/web/deps/dep5.mdwn?rev=135\n";'\
-	'print "X-Draft: Autogenerated by CDBS snippet copyright-check.mk\n\n";'\
-	'$$n=0; while (<>) {'\
-	'	if (/^([^:\s][^:]+):[\s]+(\S.*?)\s*$$/) {'\
-	'		$$files[$$n]{name}=$$1;'\
-	'		$$files[$$n]{license}=$$2;'\
-	'	};'\
-	'	if (/^\s*\[Copyright:\s*(\S.*?)\s*\]/) {'\
-	'		$$files[$$n]{copyright}=$$1;'\
-	'	};'\
-	'	/^$$/ and $$n++;'\
-	'};'\
-	'foreach $$file (@files) {'\
-	'	$$file->{license} =~ s/\s*\(unversioned\/unknown version\)//;'\
-	'	$$file->{license} =~ s/\s*\(with incorrect FSF address\)//;'\
-	'	$$file->{license} =~ s/\s+\(v([^)]+) or later\)/-$$1+/;'\
-	'	$$file->{license} =~ s/\s+\(v([^)]+)\)/-$$1/;'\
-	'	$$file->{license} =~ s/\s*(\*No copyright\*)\s*// and $$file->{copyright} = $$1;'\
-	'	$$file->{license} =~ s/^\s*(GENERATED FILE)/UNKNOWN/;'\
-	'	$$file->{license} =~ s/\s+(GENERATED FILE)//;'\
-	'	$$file->{copyright} =~ s/^&copy;\s*//;'\
-	'	$$file->{copyright} =~ s/(?<=(\b\d{4}))(?{$$y=$$^N})\s*[,-]\s*((??{$$y+1}))\b/-$$2/g;'\
-	'	$$file->{copyright} =~ s/(?<=\b\d{4})\s*-\s*\d{4}(?=\s*-\s*(\d{4})\b)//g;'\
-	'	$$file->{copyright} =~ s/\b(\d{4}),?\s+([\S^\d])/$$1, $$2/g;'\
-	'	my @ownerlines = grep {/\w\w/} split /\s\/\s/, $$file->{copyright};'\
-	'	my @ownerlines_clean = ();'\
-	'	my %owneryears = ();'\
-	'	for $$ownerline ( @ownerlines ) {'\
-	'		my ($$owneryear, $$owner) = $$ownerline =~ /^([\d-,\s]*)\s*+(.*)/;'\
-	'		$$owner =~ s/^by\s+//;'\
-	'		$$owner =~ s/,?\s+All Rights Reserved\.?//gi;'\
-	'		push @ownerlines_clean, "$$owneryear$$owner";'\
-	'		push @{ $$owneryears{"$$owner"} }, $$owneryear;'\
-	'	};'\
-	'	my @owners = sort keys %owneryears;'\
-	'	my $$pattern = join ("\n", $$file->{license}, @owners);'\
-	'	push @{ $$patternfiles{"$$pattern"} }, $$file->{name};'\
-	'	push @{ $$patternownerlines{"$$pattern"} }, @ownerlines_clean;'\
-	'	$$patternlicense{"$$pattern"} = $$file->{license};'\
-	'};'\
-	'foreach $$pattern ( sort {'\
-	'			@{$$patternfiles{$$b}} <=> @{$$patternfiles{$$a}}'\
-	'			||'\
-	'			$$a cmp $$b'\
-	'		} keys %patternfiles ) {'\
-	'	my $$prev;'\
-	'	@ownerlines_unique = grep($$_ ne $$prev && (($$prev) = $$_), sort @{ $$patternownerlines{$$pattern} });'\
-	'	print "Files: ", join(",\n\t", sort @{ $$patternfiles{$$pattern} }), "\n";'\
-	'	print "Copyright: ", join("\n\t", @ownerlines_unique), "\n";'\
-	'	print "License: $$patternlicense{$$pattern}\n FIXME\n\n";'\
-	'};'\
-		> debian/copyright_newhints
-	@export LC_ALL=C; patterncount="`cat debian/copyright_newhints | sed 's/^[^:]*://' | sort -u | grep . -c -`"; \
-		echo "Found $$patterncount different copyright and licensing combinations."
-	@if [ ! -f debian/copyright_hints ]; then touch debian/copyright_hints; fi
-	@export LC_ALL=C; newstrings=`diff -a -u debian/copyright_hints debian/copyright_newhints | sed '1,2d' | egrep -a '^\+' - | sed 's/^\+//'`; \
-		if [ -n "$$newstrings" ]; then \
-			echo "$(if $(DEB_COPYRIGHT_CHECK_STRICT),ERROR,WARNING): The following (and possibly more) new or changed notices discovered:"; \
-			echo; \
-			echo "$$newstrings" \
-				| perl -ne '/^.{0,60}$$/ or s/^(.{0,60})\b.*$$/$$1…/;s/[^[:print:][:space:]…]//g;$$_ ne $$prev and (($$prev) = $$_) and print' \
-				| sort -m \
-				| head -n 200; \
-			echo; \
-			echo "To fix the situation please do the following:"; \
-			echo "  1) Fully compare debian/copyright_hints with debian/copyright_newhints"; \
-			echo "  2) Update debian/copyright as needed"; \
-			echo "  3) Replace debian/copyright_hints with debian/copyright_newhints"; \
-			$(if $(DEB_COPYRIGHT_CHECK_STRICT),exit 1,:); \
-		else \
-			echo 'No new copyright notices found - assuming no news is good news...'; \
-			rm -f debian/copyright_newhints; \
-		fi
-	touch $@
-
-clean::
-	$(if $(DEB_COPYRIGHT_CHECK_STRICT),:,rm -f debian/copyright_newhints)
-	rm -f debian/stamp-copyright-check
-
-endif

-- 
hydrogen packaging



More information about the pkg-multimedia-commits mailing list