declarative egg ideas: matchable.egg pasted by DerGuteMoritz on Tue Nov 3 10:38:58 2015
((synopsis "Hygienic MATCH replacement")
(license "Public Domain")
(category lang-exts)
;; This is plural now and allows multiple values
(authors "Alex Shinn")
;; Versions are per egg now rather than per installed extension / program
(version "3.3")
(components
;; short form
(extension matchable)))
matchable-verbose.egg pasted by DerGuteMoritz on Tue Nov 3 10:39:22 2015
((synopsis "Hygienic MATCH replacement")
(license "Public Domain")
(category lang-exts)
;; This is plural now and allows multiple values
(authors "Alex Shinn")
;; Versions are per egg now rather than per installed extension / program
(version "3.3")
(components
;; long form
(extension matchable
(dependencies "matchable.scm")
(artifacts (compiled-library "matchable")
;; (compiled-library "matchable.import")
(import-library "matchable"))
(build-static (lambda (...) ...))
(build (lambda (self dependencies)
(let* ((module (alist-ref 'name self))
(import-file (make-pathname (symbol->string module) "import" "scm")))
(compile -O3 -d1 -j ,module -s ,(alist-ref 'source-file self))
(compile -O3 -d1 ,import-file)))))))
ncurses.egg pasted by DerGuteMoritz on Tue Nov 3 10:40:10 2015
((synopsis "An interface to the UNIX ncurses package")
(category ui)
(license "BSD")
(version "1.5")
(dependencies easyffi)
(foreign-dependencies ncurses)
(authors "felix winkelmann")
(components
(extension ncurses
;; These apply to the main source file (not the import file)
(csc-options -L -lncurses))))
hyde.egg pasted by DerGuteMoritz on Tue Nov 3 10:40:29 2015
((synopsis "A static website compiler")
(authors "Moritz Heidkamp")
(category web)
(license "BSD")
(version "0.21.0")
(dependencies filepath
sxml-transforms
doctype
(scss "0.5.0")
(spiffy "4.9")
colorize
intarweb
(uri-common "1.2")
svnwiki-sxml
multidoc
atom
rfc3339)
(build-dependencies
matchable
defstruct)
(components
(extension hyde-page-eval-env)
(extension hyde
(dependencies hyde-page-eval-env))
(extension hyde-atom
(dependencies hyde))
(program hyde
(dependencies hyde "hyde-cmd.scm")
(source-file "hyde-cmd.scm"))))
termbox.egg pasted by DerGuteMoritz on Tue Nov 3 10:41:40 2015
(meta (synopsis "Library for writing text-based user interfaces") (authors "Richard van Roy") (version "v0.11") (license "BSD") (category ui)) (components (extension termbox (dependencies "utf8.c" "ctermbox.c" "termbox.scm") (csc-options -O3 -d1) (csc-files "utf8.c" "ctermbox.c" "termbox.scm"))) ; Hm, redundant and lame ; ... actually this could be ; done via foreign-declare, so ; perhaps we don't need to ; support this kind of thing ; via the declarative API?
posix-shm.egg pasted by DerGuteMoritz on Tue Nov 3 10:42:17 2015
(meta (synopsis "POSIX Shared Memory API") (authors "Ivan Raikov") (version "1.0") (license "BSD") (category os) (test-dependencies test)) (components (extension posix-shm (csc-options -O2 -d0 -S (conditional (ldflags cflags) (((-lfoo) (-DHAVE_FOO)) ((-lrt) (-DHAVE_POSIX_SHM))) "#include <sys/mman.h>" "#include <sys/stat.h>" "#include <fcntl.h>" "" "int main(int argc, char **argv) {" " shm_open(\"test\",0,0);" " return 0;" "}"))))
spock.egg added by DerGuteMoritz on Tue Nov 3 10:42:37 2015
((synopsis "A compiler and runtime system for R5RS Scheme on top of JavaScript")
(license "BSD")
(category web)
(version "0.09")
(test-dependencies)
(build-dependencies jsmin make)
(runtime-dependencies matchable)
(authors "felix winkelmann")
(components
(extension spock-compiler
(dependencies "misc.scm"
"expand.scm"
"core.scm"
"opt.scm"
"xref.scm"
"sections.scm"
"spock/library.scm"
"driver.scm"
"codegen.scm")
(csc-options -sS -O3 -d1))
(program chicken-spock
(dependencies spock-compiler
"chicken-spock.scm"
"top.scm")
(csc-options -S -O3 -d0 -feature standalone))
(extension spock
(dependencies spock-compiler)
(source-file "spock-module.scm")
(csc-options -sS -O3 -d1))
(custom spock-runtime
(dependencies chicken-spock
"config.js"
"runtime.js"
"debug.js"
"spock/library.scm")
;; This procedure could also be a definition in spock.setup
;; which would be loaded before the build process starts
(build (lambda (self dependencies)
(use utils jsmin make)
(define (cat out . files)
(print " cat " (string-intersperse files) " > " out)
(with-output-to-file out
(lambda ()
(for-each
(lambda (f) (display (read-all f)))
files))))
(define (jsmin from to)
(with-output-to-file to
(cut display (jsmin-file from))))
(define executable
(alist-ref 'chicken-spock (alist-ref 'programs dependencies)))
(define results
'("spock/spock-runtime.js"
"spock/spock-runtime-debug.js"
"spock/spock-runtime-min.js"
"spock/spock-runtime-debug-min.js"))
(make/proc (list (list "spock/spock-runtime.js"
'("config.js" "runtime.js" "library.js")
(lambda ()
(cat "spock/spock-runtime.js" "config.js" "runtime.js" "library.js")))
(list "spock/spock-runtime-debug.js"
'("config.js" "runtime.js" "debug.js" "library-debug.js")
(lambda () (cat "spock/spock-runtime-debug.js"
"config.js" "runtime.js" "debug.js"
"library-debug.js")))
(list "spock/spock-runtime-min.js"
'("spock/spock-runtime.js")
(lambda ()
(jsmin "spock/spock-runtime.js" "spock/spock-runtime-min.js")))
(list "spock/spock-runtime-debug-min.js"
'("spock/spock-runtime-debug.js")
(lambda ()
(jsmin "spock/spock-runtime-debug.js" "spock/spock-runtime-debug-min.js")))
(list "library.js"
(list "spock/library.scm" executable)
(lambda ()
(run (./chicken-spock -library-path spock -optimize -library -o library.js))))
(list "library-debug.js"
(list "spock/library.scm" executable)
(lambda ()
(run (./chicken-spock -library-path spock -optimize -debug -library
-o library-debug.js)))))
results)
results)))))