From 8452db040905a7de460f8ff2c8b1dda28eed737c Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 9 May 2017 21:31:46 -0400 Subject: [PATCH] Put license information in each generated uni-*.el * admin/unidata/unidata-gen.el (unidata-gen-file): Get Copyright line from copyright.html. Put information in file header, not separate README. (unidata-gen-charprop): Mention the source location. * lisp/international/README: Remove file. --- admin/unidata/unidata-gen.el | 24 ++++++++++++++++-------- lisp/international/README | 15 --------------- 2 files changed, 16 insertions(+), 23 deletions(-) delete mode 100644 lisp/international/README diff --git a/admin/unidata/unidata-gen.el b/admin/unidata/unidata-gen.el index 64e2babd4b9..e1e896ce29c 100644 --- a/admin/unidata/unidata-gen.el +++ b/admin/unidata/unidata-gen.el @@ -1401,19 +1401,26 @@ Property value is a symbol `o' (Open), `c' (Close), or `n' (None)." data-dir (or (pop command-line-args-left) default-directory) unidata-text-file (or (pop command-line-args-left) (expand-file-name "unidata.txt")))) - (let ((coding-system-for-write 'utf-8-unix) - (coding-system-for-read 'utf-8) - (unidata-dir data-dir)) + (let* ((coding-system-for-write 'utf-8-unix) + (coding-system-for-read 'utf-8) + (unidata-dir data-dir) + (copyright (with-temp-buffer + (insert-file-contents + (expand-file-name "copyright.html" unidata-dir)) + (re-search-forward "^Copyright .*Unicode, Inc.") + (match-string 0)))) (or unidata-list (unidata-setup-list unidata-text-file)) (let* ((basename (file-name-nondirectory file)) (elt (assoc basename unidata-file-alist))) (or elt (user-error "Unknown output file: %s" basename)) (or noninteractive (message "Generating %s..." file)) (with-temp-file file - (insert ";; Copyright (C) 1991-2014 Unicode, Inc. -;; This file was generated from the Unicode data files at -;; http://www.unicode.org/Public/UNIDATA/. -;; See lisp/international/README for the copyright and permission notice.\n") + (insert ";; " copyright " +;; Generated from Unicode data files by unidata-gen.el. +;; The sources for this file are found in the admin/unidata/ directory in +;; the Emacs sources. The Unicode data files are used under the +;; Unicode Terms of Use, as contained in the file copyright.html in that +;; same directory.\n") (dolist (proplist (cdr elt)) (let ((prop (unidata-prop-prop proplist)) (index (unidata-prop-index proplist)) @@ -1443,7 +1450,8 @@ Property value is a symbol `o' (Open), `c' (Close), or `n' (None)." (defun unidata-gen-charprop (&optional charprop-file) (or charprop-file (setq charprop-file (pop command-line-args-left))) (with-temp-file charprop-file - (insert ";; Automatically generated by unidata-gen.el.\n") + (insert ";; Automatically generated by unidata-gen.el.\n" + ";; See the admin/unidata/ directory in the Emacs sources.\n") (dolist (elt unidata-file-alist) (dolist (proplist (cdr elt)) (insert (format "(define-char-code-property '%S %S\n %S)\n" diff --git a/lisp/international/README b/lisp/international/README deleted file mode 100644 index 88b6041a937..00000000000 --- a/lisp/international/README +++ /dev/null @@ -1,15 +0,0 @@ -The following files in this directory are derived from the Unicode -Data File at http://www.unicode.org/Public/UNIDATA/UnicodeData.txt: - - charprop.el uni-bidi.el uni-brackets.el uni-category.el - uni-combining.el uni-comment.el uni-decimal.el uni-decomposition.el - uni-digit.el uni-lowercase.el uni-mirrored.el uni-name.el - uni-numeric.el uni-old-name.el uni-special-lowercase.el - uni-special-titlecase.el uni-special-uppercase.el uni-titlecase.el - uni-uppercase.el - -These files were generated from the version admin/unidata/UnicodeData.txt -in the Emacs sources, using the file unidata-gen.el in the same directory. - -The file UnicodeData.txt is used under the Unicode Terms of Use, -contained in the file admin/unidata/copyright.html. -- 2.39.2