Header is now added to master interfaces.
This commit is contained in:
parent
f7a25bd47a
commit
a6505ef990
8
Makefile
8
Makefile
|
@ -21,16 +21,16 @@ s48 : $(s48-targets)
|
||||||
scsh : $(scsh-targets)
|
scsh : $(scsh-targets)
|
||||||
|
|
||||||
s48-interfaces.scm : $(s48-interfaces)
|
s48-interfaces.scm : $(s48-interfaces)
|
||||||
cat $(s48-interfaces) > s48-interfaces.scm
|
cat build/header.scm $(s48-interfaces) > s48-interfaces.scm
|
||||||
|
|
||||||
s48-packages.scm : $(s48-packages)
|
s48-packages.scm : $(s48-packages)
|
||||||
build/xpackages.scm s48-packages.scm $(s48-packages)
|
build/xpackages.scm s48-packages.scm build/header.scm $(s48-packages)
|
||||||
|
|
||||||
interfaces.scm : $(s48-interfaces) $(scsh-interfaces)
|
interfaces.scm : $(s48-interfaces) $(scsh-interfaces)
|
||||||
cat $(s48-interfaces) $(scsh-interfaces) > interfaces.scm
|
cat build/header.scm $(s48-interfaces) $(scsh-interfaces) > interfaces.scm
|
||||||
|
|
||||||
packages.scm : $(s48-packages) $(scsh-packages)
|
packages.scm : $(s48-packages) $(scsh-packages)
|
||||||
build/xpackages.scm packages.scm $(s48-packages) $(scsh-packages)
|
build/xpackages.scm packages.scm build/header.scm $(s48-packages) $(scsh-packages)
|
||||||
|
|
||||||
.PHONY : clean
|
.PHONY : clean
|
||||||
clean :
|
clean :
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
;;; This file was automatically generated by the sunterlib
|
||||||
|
;;; makefile, so do not edit it.
|
||||||
|
|
|
@ -30,10 +30,17 @@ exec scsh -o filenames -o pp -s "$0" "$@"
|
||||||
;;; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
;;; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||||
;;; THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
;;; THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
|
|
||||||
(define header-message
|
(define copy-header
|
||||||
";; This file was automatically generated by the sunterlib
|
(lambda (header)
|
||||||
;; makefile, so do not edit it.
|
(with-current-input-port
|
||||||
")
|
(open-input-file header)
|
||||||
|
(let loop ()
|
||||||
|
(let ((ch (read-char)))
|
||||||
|
(if (eof-object? ch)
|
||||||
|
(values)
|
||||||
|
(begin
|
||||||
|
(write-char ch)
|
||||||
|
(loop))))))))
|
||||||
|
|
||||||
(define process-source
|
(define process-source
|
||||||
(lambda (source)
|
(lambda (source)
|
||||||
|
@ -81,14 +88,14 @@ exec scsh -o filenames -o pp -s "$0" "$@"
|
||||||
(error "unexpected form in packages" source form))))))))
|
(error "unexpected form in packages" source form))))))))
|
||||||
|
|
||||||
(define xpackages
|
(define xpackages
|
||||||
;; Copy each source file to the target file, adding the source
|
;; Copy the header and each source file to the target file, adding
|
||||||
;; directory to each package's file-specs.
|
;; the source directory to each package's file-specs.
|
||||||
(lambda (target sources)
|
(lambda (target header sources)
|
||||||
(with-current-output-port
|
(with-current-output-port
|
||||||
(open-output-file target)
|
(open-output-file target)
|
||||||
(display header-message)
|
(copy-header header)
|
||||||
(newline)
|
|
||||||
(for-each process-source sources))))
|
(for-each process-source sources))))
|
||||||
|
|
||||||
(xpackages (car command-line-arguments)
|
(xpackages (car command-line-arguments)
|
||||||
(cdr command-line-arguments))
|
(cadr command-line-arguments)
|
||||||
|
(cddr command-line-arguments))
|
||||||
|
|
Loading…
Reference in New Issue