TESTS = blowfish-check.sh
CLEANFILES += test
-check-local:
- ./check-doc.sh
-
tags: tags-am
./tags-fix.sh blowfish
EXTRA_DIST += $(all_sources) $(cdecls) compile.scm blowfish.pkg
EXTRA_DIST += blowfish-test.scm blowfish-check.sh
-EXTRA_DIST += make.scm optiondb.scm check-doc.sh tags-fix.sh debian
+EXTRA_DIST += make.scm optiondb.scm tags-fix.sh debian
install-data-hook:
( echo '(add-plugin "blowfish" "@MIT_SCHEME_PROJECT@"'; \
+++ /dev/null
-#!/bin/bash
-# -*-Scheme-*-
-#
-# Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015,
-# 2016, 2017 Matthew Birkholz
-#
-# This file is part of a Blowfish plugin for MIT/GNU Scheme Pucked.
-#
-# This plugin 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.
-#
-# This plugin 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 plugin; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-# 02110-1301, USA.
-
-# Check the documentation.
-
-set -e
-: ${MIT_SCHEME_EXE=mit-scheme}
-${MIT_SCHEME_EXE} --batch-mode <<\EOF
-
-(let ((pkgset "blowfish")
- (texi "blowfish.texi")
- (pkg '(blowfish)))
- ;; Check that every binding exported to () or PKG has a
- ;; corresponding @deffn in TEXI.
-
- (parameterize ((param:suppress-loading-message? #t))
- (load-option 'cref)
- (load-option 'regular-expression))
- (define read-package-model)
- (define pmodel/packages)
- (define package/name)
- (define package/bindings)
- (define package/links)
- (define link/source)
- (define link/destination)
- (define binding/package)
- (define binding/name)
- (let ((cref (->environment '(cross-reference))))
- (set! read-package-model (access read-package-model cref))
- (set! pmodel/packages (access pmodel/packages cref))
- (set! package/name (access package/name cref))
- (set! package/bindings (access package/bindings cref))
- (set! package/links (access package/links cref))
- (set! link/source (access link/source cref))
- (set! link/destination (access link/destination cref))
- (set! binding/package (access binding/package cref))
- (set! binding/name (access binding/name cref)))
-
- (define (deffn-name line)
- (let ((regs (re-string-match
- (string-append "@deffnx?"
- " \\(Class\\|Procedure\\|{Generic Procedure}\\)"
- " \\([-A-Za-z0-9<>?!+./:]+\\)")
- line)))
- (if regs
- (intern (re-match-extract line regs 2))
- (error "Could not find binding name:" line))))
-
- (define (texinfo-deffns lines)
- (let ((len (vector-length lines)))
- (let loop ((i 0) (deffns '()))
- (if (fix:< i len)
- (let ((line (vector-ref lines i)))
- (loop (fix:1+ i)
- (if (string-prefix? "@deffn" line)
- (cons (deffn-name line) deffns)
- deffns)))
- deffns))))
-
- (define (read-lines port)
- (let loop ()
- (let ((line (read-line port)))
- (if (eof-object? line)
- '()
- (cons line (loop))))))
-
- (define (pmodel/find-package pmodel package-name)
- (find-matching-item (pmodel/packages pmodel)
- (lambda (p) (equal? package-name (package/name p)))))
-
- (define (pmodel/global-exports pmodel)
- (define (global-exports package)
- (append-map! (lambda (link)
- (if (eq? '() (package/name
- (binding/package
- (link/destination link))))
- (list (binding/name (link/destination link)))
- '()))
- (package/links package)))
- (append-map! global-exports (pmodel/packages pmodel)))
-
- (define (pmodel/package-bindings pmodel package-name)
- (let ((package (pmodel/find-package pmodel package-name)))
- (if package
- (map binding/name (package/bindings package))
- (error "No such package:" package-name))))
-
- (define (duplicates listset)
- (let loop ((items listset) (duplicates '()))
- (cond ((null? items)
- (reverse! duplicates))
- ((memq (car items) (cdr items))
- (if (memq (car items) duplicates)
- (loop (cdr items) duplicates)
- (loop (cdr items) (cons (car items) duplicates))))
- (else
- (loop (cdr items) duplicates)))))
-
- (define (minus set1 set2)
- (let loop ((items set1) (difference '()))
- (cond ((null? items)
- difference)
- ((memq (car items) set2)
- (loop (cdr items) difference))
- (else
- (loop (cdr items) (cons (car items) difference))))))
-
- (define (check)
- (let* ((texinfo (list->vector (call-with-input-file texi read-lines)))
- (deffns (texinfo-deffns texinfo))
- (dups (duplicates deffns))
- (pmodel (read-package-model pkgset microcode-id/operating-system))
- (bindings (append (pmodel/global-exports pmodel)
- (if (null? pkg)
- '()
- (pmodel/package-bindings pmodel pkg))))
- (missing (minus bindings deffns))
- (extras (minus deffns bindings)))
- (if (not (null? dups))
- (for-each (lambda (name) (warn "multiple-descriptions:" name)) dups))
- (if (not (null? extras))
- (for-each (lambda (name) (warn "not bound:" name)) extras))
- (if (not (null? missing))
- (for-each (lambda (name) (warn "not documented:" name)) missing))))
-
- (check)
- )
-EOF
TESTS = cairo-check.sh
-check-local:
- ./check-doc.sh
-
tags: tags-am
./tags-fix.sh cairo
EXTRA_DIST += $(sources) $(cdecls) compile.sh cairo.pkg
EXTRA_DIST += cairo-check.sh
-EXTRA_DIST += make.scm optiondb.scm check-doc.sh tags-fix.sh debian
+EXTRA_DIST += make.scm optiondb.scm tags-fix.sh debian
install-data-hook:
( echo '(add-plugin "cairo" "@MIT_SCHEME_PROJECT@"'; \
+++ /dev/null
-#!/bin/bash
-# -*-Scheme-*-
-#
-# Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015,
-# 2016, 2017 Matthew Birkholz
-#
-# This file is part of a Cairo plugin for MIT/GNU Scheme Pucked.
-#
-# This plugin 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.
-#
-# This plugin 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 plugin; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-# 02110-1301, USA.
-
-# Check the documentation.
-
-set -e
-: ${MIT_SCHEME_EXE=mit-scheme}
-${MIT_SCHEME_EXE} --batch-mode <<\EOF
-
-(let ((pkgset "cairo")
- (texi "cairo.texi")
- (pkg '()))
- ;; Check that every binding exported to () or PKG has a
- ;; corresponding @deffn in TEXI.
-
- (parameterize ((param:suppress-loading-message? #t))
- (load-option 'cref)
- (load-option 'regular-expression))
- (define read-package-model)
- (define pmodel/packages)
- (define package/name)
- (define package/bindings)
- (define package/links)
- (define link/source)
- (define link/destination)
- (define binding/package)
- (define binding/name)
- (let ((cref (->environment '(cross-reference))))
- (set! read-package-model (access read-package-model cref))
- (set! pmodel/packages (access pmodel/packages cref))
- (set! package/name (access package/name cref))
- (set! package/bindings (access package/bindings cref))
- (set! package/links (access package/links cref))
- (set! link/source (access link/source cref))
- (set! link/destination (access link/destination cref))
- (set! binding/package (access binding/package cref))
- (set! binding/name (access binding/name cref)))
-
- (define (deffn-name line)
- (let ((regs (re-string-match
- (string-append "@deffnx?"
- " \\(Class\\|Procedure\\|{Generic Procedure}\\)"
- " \\([-A-Za-z0-9<>?!+./:]+\\)")
- line)))
- (if regs
- (intern (re-match-extract line regs 2))
- (error "Could not find binding name:" line))))
-
- (define (texinfo-deffns lines)
- (let ((len (vector-length lines)))
- (let loop ((i 0) (deffns '()))
- (if (fix:< i len)
- (let ((line (vector-ref lines i)))
- (loop (fix:1+ i)
- (if (string-prefix? "@deffn" line)
- (cons (deffn-name line) deffns)
- deffns)))
- deffns))))
-
- (define (read-lines port)
- (let loop ()
- (let ((line (read-line port)))
- (if (eof-object? line)
- '()
- (cons line (loop))))))
-
- (define (pmodel/find-package pmodel package-name)
- (find-matching-item (pmodel/packages pmodel)
- (lambda (p) (equal? package-name (package/name p)))))
-
- (define (pmodel/global-exports pmodel)
- (define (global-exports package)
- (append-map! (lambda (link)
- (if (eq? '() (package/name
- (binding/package
- (link/destination link))))
- (list (binding/name (link/destination link)))
- '()))
- (package/links package)))
- (append-map! global-exports (pmodel/packages pmodel)))
-
- (define (pmodel/package-bindings pmodel package-name)
- (let ((package (pmodel/find-package pmodel package-name)))
- (if package
- (map binding/name (package/bindings package))
- (error "No such package:" package-name))))
-
- (define (duplicates listset)
- (let loop ((items listset) (duplicates '()))
- (cond ((null? items)
- (reverse! duplicates))
- ((memq (car items) (cdr items))
- (if (memq (car items) duplicates)
- (loop (cdr items) duplicates)
- (loop (cdr items) (cons (car items) duplicates))))
- (else
- (loop (cdr items) duplicates)))))
-
- (define (minus set1 set2)
- (let loop ((items set1) (difference '()))
- (cond ((null? items)
- difference)
- ((memq (car items) set2)
- (loop (cdr items) difference))
- (else
- (loop (cdr items) (cons (car items) difference))))))
-
- (define (check)
- (let* ((texinfo (list->vector (call-with-input-file texi read-lines)))
- (deffns (texinfo-deffns texinfo))
- (dups (duplicates deffns))
- (pmodel (read-package-model pkgset microcode-id/operating-system))
- (bindings (append (pmodel/global-exports pmodel)
- (if (null? pkg)
- '()
- (pmodel/package-bindings pmodel pkg))))
- (missing (minus bindings deffns))
- (extras (minus deffns bindings)))
- (if (not (null? dups))
- (for-each (lambda (name) (warn "multiple-descriptions:" name)) dups))
- (if (not (null? extras))
- (for-each (lambda (name) (warn "not bound:" name)) extras))
- (if (not (null? missing))
- (for-each (lambda (name) (warn "not documented:" name)) missing))))
-
- (check)
- )
-EOF
TESTS = gdbm-check.sh
CLEANFILES += gdbm-check.db
-check-local:
- ./check-doc.sh
-
tags: tags-am
./tags-fix.sh gdbm
EXTRA_DIST += $(all_sources) $(cdecls) compile.scm gdbm.pkg
EXTRA_DIST += gdbm-check.scm gdbm-check.sh
-EXTRA_DIST += make.scm optiondb.scm check-doc.sh tags-fix.sh debian
+EXTRA_DIST += make.scm optiondb.scm tags-fix.sh debian
install-data-hook:
( echo '(add-plugin "gdbm" "@MIT_SCHEME_PROJECT@"'; \
+++ /dev/null
-#!/bin/bash
-# -*-Scheme-*-
-#
-# Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015,
-# 2016, 2017 Matthew Birkholz
-#
-# This file is part of a Gdbm plugin for MIT/GNU Scheme Pucked.
-#
-# This plugin 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.
-#
-# This plugin 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 plugin; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-# 02110-1301, USA.
-
-# Check the documentation.
-
-set -e
-: ${MIT_SCHEME_EXE=mit-scheme}
-${MIT_SCHEME_EXE} --batch-mode <<\EOF
-
-(let ((pkgset "gdbm")
- (texi "gdbm.texi")
- (pkg '(gdbm)))
- ;; Check that every binding exported to () or PKG has a
- ;; corresponding @deffn in TEXI.
-
- (parameterize ((param:suppress-loading-message? #t))
- (load-option 'cref)
- (load-option 'regular-expression))
- (define read-package-model)
- (define pmodel/packages)
- (define package/name)
- (define package/bindings)
- (define package/links)
- (define link/source)
- (define link/destination)
- (define binding/package)
- (define binding/name)
- (let ((cref (->environment '(cross-reference))))
- (set! read-package-model (access read-package-model cref))
- (set! pmodel/packages (access pmodel/packages cref))
- (set! package/name (access package/name cref))
- (set! package/bindings (access package/bindings cref))
- (set! package/links (access package/links cref))
- (set! link/source (access link/source cref))
- (set! link/destination (access link/destination cref))
- (set! binding/package (access binding/package cref))
- (set! binding/name (access binding/name cref)))
-
- (define (deffn-name line)
- (let ((regs (re-string-match
- (string-append "@deffnx?"
- " \\(Class\\|Procedure\\|{Generic Procedure}\\)"
- " \\([-A-Za-z0-9<>?!+./:]+\\)")
- line)))
- (if regs
- (intern (re-match-extract line regs 2))
- (error "Could not find binding name:" line))))
-
- (define (texinfo-deffns lines)
- (let ((len (vector-length lines)))
- (let loop ((i 0) (deffns '()))
- (if (fix:< i len)
- (let ((line (vector-ref lines i)))
- (loop (fix:1+ i)
- (if (string-prefix? "@deffn" line)
- (cons (deffn-name line) deffns)
- deffns)))
- deffns))))
-
- (define (read-lines port)
- (let loop ()
- (let ((line (read-line port)))
- (if (eof-object? line)
- '()
- (cons line (loop))))))
-
- (define (pmodel/find-package pmodel package-name)
- (find-matching-item (pmodel/packages pmodel)
- (lambda (p) (equal? package-name (package/name p)))))
-
- (define (pmodel/global-exports pmodel)
- (define (global-exports package)
- (append-map! (lambda (link)
- (if (eq? '() (package/name
- (binding/package
- (link/destination link))))
- (list (binding/name (link/destination link)))
- '()))
- (package/links package)))
- (append-map! global-exports (pmodel/packages pmodel)))
-
- (define (pmodel/package-bindings pmodel package-name)
- (let ((package (pmodel/find-package pmodel package-name)))
- (if package
- (map binding/name (package/bindings package))
- (error "No such package:" package-name))))
-
- (define (duplicates listset)
- (let loop ((items listset) (duplicates '()))
- (cond ((null? items)
- (reverse! duplicates))
- ((memq (car items) (cdr items))
- (if (memq (car items) duplicates)
- (loop (cdr items) duplicates)
- (loop (cdr items) (cons (car items) duplicates))))
- (else
- (loop (cdr items) duplicates)))))
-
- (define (minus set1 set2)
- (let loop ((items set1) (difference '()))
- (cond ((null? items)
- difference)
- ((memq (car items) set2)
- (loop (cdr items) difference))
- (else
- (loop (cdr items) (cons (car items) difference))))))
-
- (define (check)
- (let* ((texinfo (list->vector (call-with-input-file texi read-lines)))
- (deffns (texinfo-deffns texinfo))
- (dups (duplicates deffns))
- (pmodel (read-package-model pkgset microcode-id/operating-system))
- (bindings (append (pmodel/global-exports pmodel)
- (if (null? pkg)
- '()
- (pmodel/package-bindings pmodel pkg))))
- (missing (minus bindings deffns))
- (extras (minus deffns bindings)))
- (if (not (null? dups))
- (for-each (lambda (name) (warn "multiple-descriptions:" name)) dups))
- (if (not (null? extras))
- (for-each (lambda (name) (warn "not bound:" name)) extras))
- (if (not (null? missing))
- (for-each (lambda (name) (warn "not documented:" name)) missing))))
-
- (check)
- )
-EOF
TESTS = glib-check-copy.sh glib-check-list.sh
CLEANFILES += test-copy-1.txt
-check-local:
- ./check-doc.sh
-
tags: tags-am
./tags-fix.sh glib
EXTRA_DIST += $(all_sources) $(cdecls) compile.sh glib.pkg
EXTRA_DIST += glib-tests.scm glib-check-copy.sh glib-check-list.sh
-EXTRA_DIST += make.scm optiondb.scm check-doc.sh tags-fix.sh debian
+EXTRA_DIST += make.scm optiondb.scm tags-fix.sh debian
install-data-hook:
( echo '(add-plugin "glib" "@MIT_SCHEME_PROJECT@"'; \
+++ /dev/null
-#!/bin/bash
-# -*-Scheme-*-
-#
-# Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015,
-# 2016, 2017 Matthew Birkholz
-#
-# This file is part of a GLib plugin for MIT/GNU Scheme Pucked.
-#
-# This plugin 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.
-#
-# This plugin 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 plugin; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-# 02110-1301, USA.
-
-# Check the documentation.
-
-set -e
-: ${MIT_SCHEME_EXE=mit-scheme}
-${MIT_SCHEME_EXE} --batch-mode <<\EOF
-
-(let ((pkgset "glib")
- (texi "glib.texi")
- (pkg '(glib)))
- ;; Check that every binding exported to () or PKG has a
- ;; corresponding @deffn in TEXI.
-
- (parameterize ((param:suppress-loading-message? #t))
- (load-option 'cref)
- (load-option 'regular-expression))
- (define read-package-model)
- (define pmodel/packages)
- (define package/name)
- (define package/bindings)
- (define package/links)
- (define link/source)
- (define link/destination)
- (define binding/package)
- (define binding/name)
- (let ((cref (->environment '(cross-reference))))
- (set! read-package-model (access read-package-model cref))
- (set! pmodel/packages (access pmodel/packages cref))
- (set! package/name (access package/name cref))
- (set! package/bindings (access package/bindings cref))
- (set! package/links (access package/links cref))
- (set! link/source (access link/source cref))
- (set! link/destination (access link/destination cref))
- (set! binding/package (access binding/package cref))
- (set! binding/name (access binding/name cref)))
-
- (define (deffn-name line)
- (let ((regs (re-string-match
- (string-append "@deffnx?"
- " \\(Class\\|Procedure\\|{Generic Procedure}\\)"
- " \\([-A-Za-z0-9<>?!+./:]+\\)")
- line)))
- (if regs
- (intern (re-match-extract line regs 2))
- (error "Could not find binding name:" line))))
-
- (define (texinfo-deffns lines)
- (let ((len (vector-length lines)))
- (let loop ((i 0) (deffns '()))
- (if (fix:< i len)
- (let ((line (vector-ref lines i)))
- (loop (fix:1+ i)
- (if (string-prefix? "@deffn" line)
- (cons (deffn-name line) deffns)
- deffns)))
- deffns))))
-
- (define (read-lines port)
- (let loop ()
- (let ((line (read-line port)))
- (if (eof-object? line)
- '()
- (cons line (loop))))))
-
- (define (pmodel/find-package pmodel package-name)
- (find-matching-item (pmodel/packages pmodel)
- (lambda (p) (equal? package-name (package/name p)))))
-
- (define (pmodel/global-exports pmodel)
- (define (global-exports package)
- (append-map! (lambda (link)
- (if (eq? '() (package/name
- (binding/package
- (link/destination link))))
- (list (binding/name (link/destination link)))
- '()))
- (package/links package)))
- (append-map! global-exports (pmodel/packages pmodel)))
-
- (define (pmodel/package-bindings pmodel package-name)
- (let ((package (pmodel/find-package pmodel package-name)))
- (if package
- (map binding/name (package/bindings package))
- (error "No such package:" package-name))))
-
- (define (duplicates listset)
- (let loop ((items listset) (duplicates '()))
- (cond ((null? items)
- (reverse! duplicates))
- ((memq (car items) (cdr items))
- (if (memq (car items) duplicates)
- (loop (cdr items) duplicates)
- (loop (cdr items) (cons (car items) duplicates))))
- (else
- (loop (cdr items) duplicates)))))
-
- (define (minus set1 set2)
- (let loop ((items set1) (difference '()))
- (cond ((null? items)
- difference)
- ((memq (car items) set2)
- (loop (cdr items) difference))
- (else
- (loop (cdr items) (cons (car items) difference))))))
-
- (define (check)
- (let* ((texinfo (list->vector (call-with-input-file texi read-lines)))
- (deffns (texinfo-deffns texinfo))
- (dups (duplicates deffns))
- (pmodel (read-package-model pkgset microcode-id/operating-system))
- (bindings (append (pmodel/global-exports pmodel)
- (if (null? pkg)
- '()
- (pmodel/package-bindings pmodel pkg))))
- (missing (minus bindings deffns))
- (extras (minus deffns bindings)))
- (if (not (null? dups))
- (for-each (lambda (name) (warn "multiple-descriptions:" name)) dups))
- (if (not (null? extras))
- (for-each (lambda (name) (warn "not bound:" name)) extras))
- (if (not (null? missing))
- (for-each (lambda (name) (warn "not documented:" name)) missing))))
-
- (check)
- )
-EOF
TESTS = gtk-check.sh
-check-local:
- ./check-doc.sh
-
tags: tags-am
./tags-fix.sh gtk
EXTRA_DIST += $(all_sources) $(cdecls) compile.sh gtk.pkg
EXTRA_DIST += gtk-tests.scm gtk-check.sh
-EXTRA_DIST += make.scm optiondb.scm check-doc.sh tags-fix.sh
+EXTRA_DIST += make.scm optiondb.scm tags-fix.sh
EXTRA_DIST += gtkpanedview-3.6.0.c gtkscrolledview-3.6.0.c
EXTRA_DIST += gtkpanedview-3.10.8.c gtkscrolledview-3.10.8.c
EXTRA_DIST += gtkpanedview-3.14.13.c gtkscrolledview-3.14.13.c
+++ /dev/null
-#!/bin/bash
-# -*-Scheme-*-
-#
-# Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015,
-# 2016, 2017 Matthew Birkholz
-#
-# This file is part of a Gtk plugin for MIT/GNU Scheme Pucked.
-#
-# This plugin 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.
-#
-# This plugin 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 plugin; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-# 02110-1301, USA.
-
-# Check the documentation.
-
-set -e
-: ${MIT_SCHEME_EXE=mit-scheme}
-${MIT_SCHEME_EXE} --batch-mode <<\EOF
-
-(let ((pkgset "gtk")
- (texi "gtk.texi")
- (pkg '(gtk)))
- ;; Check that every binding exported to () or PKG has a
- ;; corresponding @deffn in TEXI.
-
- (parameterize ((param:suppress-loading-message? #t))
- (load-option 'cref)
- (load-option 'regular-expression))
- (define read-package-model)
- (define pmodel/packages)
- (define package/name)
- (define package/bindings)
- (define package/links)
- (define link/source)
- (define link/destination)
- (define binding/package)
- (define binding/name)
- (let ((cref (->environment '(cross-reference))))
- (set! read-package-model (access read-package-model cref))
- (set! pmodel/packages (access pmodel/packages cref))
- (set! package/name (access package/name cref))
- (set! package/bindings (access package/bindings cref))
- (set! package/links (access package/links cref))
- (set! link/source (access link/source cref))
- (set! link/destination (access link/destination cref))
- (set! binding/package (access binding/package cref))
- (set! binding/name (access binding/name cref)))
-
- (define (deffn-name line)
- (let ((regs (re-string-match
- (string-append "@deffnx?"
- " \\(Class\\|Procedure\\|{Generic Procedure}\\)"
- " \\([-A-Za-z0-9<>?!+./:]+\\)")
- line)))
- (if regs
- (intern (re-match-extract line regs 2))
- (error "Could not find binding name:" line))))
-
- (define (texinfo-deffns lines)
- (let ((len (vector-length lines)))
- (let loop ((i 0) (deffns '()))
- (if (fix:< i len)
- (let ((line (vector-ref lines i)))
- (loop (fix:1+ i)
- (if (string-prefix? "@deffn" line)
- (cons (deffn-name line) deffns)
- deffns)))
- deffns))))
-
- (define (read-lines port)
- (let loop ()
- (let ((line (read-line port)))
- (if (eof-object? line)
- '()
- (cons line (loop))))))
-
- (define (pmodel/find-package pmodel package-name)
- (find-matching-item (pmodel/packages pmodel)
- (lambda (p) (equal? package-name (package/name p)))))
-
- (define (pmodel/global-exports pmodel)
- (define (global-exports package)
- (append-map! (lambda (link)
- (if (eq? '() (package/name
- (binding/package
- (link/destination link))))
- (list (binding/name (link/destination link)))
- '()))
- (package/links package)))
- (append-map! global-exports (pmodel/packages pmodel)))
-
- (define (pmodel/package-bindings pmodel package-name)
- (let ((package (pmodel/find-package pmodel package-name)))
- (if package
- (map binding/name (package/bindings package))
- (error "No such package:" package-name))))
-
- (define (duplicates listset)
- (let loop ((items listset) (duplicates '()))
- (cond ((null? items)
- (reverse! duplicates))
- ((memq (car items) (cdr items))
- (if (memq (car items) duplicates)
- (loop (cdr items) duplicates)
- (loop (cdr items) (cons (car items) duplicates))))
- (else
- (loop (cdr items) duplicates)))))
-
- (define (minus set1 set2)
- (let loop ((items set1) (difference '()))
- (cond ((null? items)
- difference)
- ((memq (car items) set2)
- (loop (cdr items) difference))
- (else
- (loop (cdr items) (cons (car items) difference))))))
-
- (define (check)
- (let* ((texinfo (list->vector (call-with-input-file texi read-lines)))
- (deffns (texinfo-deffns texinfo))
- (dups (duplicates deffns))
- (pmodel (read-package-model pkgset microcode-id/operating-system))
- (bindings (append (pmodel/global-exports pmodel)
- (if (null? pkg)
- '()
- (pmodel/package-bindings pmodel pkg))))
- (missing (minus bindings deffns))
- (extras (minus deffns bindings)))
- (if (not (null? dups))
- (for-each (lambda (name) (warn "multiple-descriptions:" name)) dups))
- (if (not (null? extras))
- (for-each (lambda (name) (warn "not bound:" name)) extras))
- (if (not (null? missing))
- (for-each (lambda (name) (warn "not documented:" name)) missing))))
-
- (check)
- )
-EOF
TESTS = pango-check.sh
-check-local:
- ./check-doc.sh
-
tags: tags-am
./tags-fix.sh pango
EXTRA_DIST += $(sources) $(cdecls) compile.sh pango.pkg
EXTRA_DIST += pango-check.sh
-EXTRA_DIST += make.scm optiondb.scm check-doc.sh tags-fix.sh debian
+EXTRA_DIST += make.scm optiondb.scm tags-fix.sh debian
install-data-hook:
( echo '(add-plugin "pango" "@MIT_SCHEME_PROJECT@"'; \
+++ /dev/null
-#!/bin/bash
-# -*-Scheme-*-
-#
-# Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015,
-# 2016, 2017 Matthew Birkholz
-#
-# This file is part of a Pango plugin for MIT/GNU Scheme Pucked.
-#
-# This plugin 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.
-#
-# This plugin 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 plugin; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-# 02110-1301, USA.
-
-# Check the documentation.
-
-set -e
-: ${MIT_SCHEME_EXE=mit-scheme}
-${MIT_SCHEME_EXE} --batch-mode <<\EOF
-
-(let ((pkgset "pango")
- (texi "pango.texi")
- (pkg '()))
- ;; Check that every binding exported to () or PKG has a
- ;; corresponding @deffn in TEXI.
-
- (parameterize ((param:suppress-loading-message? #t))
- (load-option 'cref)
- (load-option 'regular-expression))
- (define read-package-model)
- (define pmodel/packages)
- (define package/name)
- (define package/bindings)
- (define package/links)
- (define link/source)
- (define link/destination)
- (define binding/package)
- (define binding/name)
- (let ((cref (->environment '(cross-reference))))
- (set! read-package-model (access read-package-model cref))
- (set! pmodel/packages (access pmodel/packages cref))
- (set! package/name (access package/name cref))
- (set! package/bindings (access package/bindings cref))
- (set! package/links (access package/links cref))
- (set! link/source (access link/source cref))
- (set! link/destination (access link/destination cref))
- (set! binding/package (access binding/package cref))
- (set! binding/name (access binding/name cref)))
-
- (define (deffn-name line)
- (let ((regs (re-string-match
- (string-append "@deffnx?"
- " \\(Class\\|Procedure\\|{Generic Procedure}\\)"
- " \\([-A-Za-z0-9<>?!+./:]+\\)")
- line)))
- (if regs
- (intern (re-match-extract line regs 2))
- (error "Could not find binding name:" line))))
-
- (define (texinfo-deffns lines)
- (let ((len (vector-length lines)))
- (let loop ((i 0) (deffns '()))
- (if (fix:< i len)
- (let ((line (vector-ref lines i)))
- (loop (fix:1+ i)
- (if (string-prefix? "@deffn" line)
- (cons (deffn-name line) deffns)
- deffns)))
- deffns))))
-
- (define (read-lines port)
- (let loop ()
- (let ((line (read-line port)))
- (if (eof-object? line)
- '()
- (cons line (loop))))))
-
- (define (pmodel/find-package pmodel package-name)
- (find-matching-item (pmodel/packages pmodel)
- (lambda (p) (equal? package-name (package/name p)))))
-
- (define (pmodel/global-exports pmodel)
- (define (global-exports package)
- (append-map! (lambda (link)
- (if (eq? '() (package/name
- (binding/package
- (link/destination link))))
- (list (binding/name (link/destination link)))
- '()))
- (package/links package)))
- (append-map! global-exports (pmodel/packages pmodel)))
-
- (define (pmodel/package-bindings pmodel package-name)
- (let ((package (pmodel/find-package pmodel package-name)))
- (if package
- (map binding/name (package/bindings package))
- (error "No such package:" package-name))))
-
- (define (duplicates listset)
- (let loop ((items listset) (duplicates '()))
- (cond ((null? items)
- (reverse! duplicates))
- ((memq (car items) (cdr items))
- (if (memq (car items) duplicates)
- (loop (cdr items) duplicates)
- (loop (cdr items) (cons (car items) duplicates))))
- (else
- (loop (cdr items) duplicates)))))
-
- (define (minus set1 set2)
- (let loop ((items set1) (difference '()))
- (cond ((null? items)
- difference)
- ((memq (car items) set2)
- (loop (cdr items) difference))
- (else
- (loop (cdr items) (cons (car items) difference))))))
-
- (define (check)
- (let* ((texinfo (list->vector (call-with-input-file texi read-lines)))
- (deffns (texinfo-deffns texinfo))
- (dups (duplicates deffns))
- (pmodel (read-package-model pkgset microcode-id/operating-system))
- (bindings (append (pmodel/global-exports pmodel)
- (if (null? pkg)
- '()
- (pmodel/package-bindings pmodel pkg))))
- (missing (minus bindings deffns))
- (extras (minus deffns bindings)))
- (if (not (null? dups))
- (for-each (lambda (name) (warn "multiple-descriptions:" name)) dups))
- (if (not (null? extras))
- (for-each (lambda (name) (warn "not bound:" name)) extras))
- (if (not (null? missing))
- (for-each (lambda (name) (warn "not documented:" name)) missing))))
-
- (check)
- )
-EOF