├── mats ├── patch-compile-3-f-f-t ├── patch-compile-3-f-t-f ├── patch-compile-3-t-f-f ├── patch-compile-3-t-f-t ├── patch-compile-3-t-t-f ├── freq.out ├── m4test.out ├── freq.in ├── bldnt.bat ├── killme.c ├── Mf-a6fb ├── Mf-a6nb ├── Mf-a6ob ├── Mf-i3fb ├── Mf-i3nb ├── Mf-i3ob ├── Mf-a6le ├── Mf-i3le ├── Mf-ta6fb ├── Mf-ta6nb ├── Mf-ta6ob ├── Mf-ti3fb ├── Mf-ti3nb ├── Mf-ti3ob ├── Mf-a6osx ├── Mf-a6s2 ├── Mf-arm32le ├── Mf-i3osx ├── Mf-i3qnx ├── Mf-i3s2 ├── Mf-ta6le ├── Mf-ta6osx ├── Mf-ta6s2 ├── Mf-ti3le ├── Mf-ti3osx ├── Mf-ti3s2 ├── Mf-ppc32le ├── Mf-tppc32le ├── 5_8.ms ├── cat_flush.c ├── ftype.h ├── Mf-a6nt ├── Mf-i3nt ├── Mf-ta6nt ├── Mf-ti3nt └── foreign1.c ├── csug ├── canned │ ├── csug.css │ ├── profview.png │ ├── cisco-logo.png │ ├── fatfibhtml.png │ ├── profilehtml.png │ ├── cisco-logo-large.png │ ├── cisco-logo-orig.png │ ├── fatfibhtml-orig.png │ ├── profilehtml-orig.png │ ├── copyright.html │ └── about.html ├── myfile.ss ├── setup.ss ├── gifs │ ├── ghostRightarrow.gif │ └── Rightarrow.tex ├── tspl4 │ ├── title.aux │ ├── contents.aux │ ├── copyright.aux │ ├── summary.aux │ ├── tspl.aux │ ├── answers.aux │ ├── preface.aux │ ├── bibliography.aux │ ├── libraries.aux │ └── grammar.aux ├── math │ ├── mathmacros │ └── Makefile ├── oop.stex ├── bibliography.stex ├── contents.stex ├── title.stex ├── scheme.hsty ├── csug.css ├── docond.ss ├── copyright.stex ├── summary.stex └── summary.ss ├── c ├── cs.ico ├── statics.c ├── gc-ocd.c ├── gc-oce.c ├── scheme.rc ├── i3le.c ├── symbol.c ├── Mf-i3nt ├── Mf-a6nt ├── Mf-ta6nt ├── Mf-ti3nt ├── system.h ├── Mf-arm32le ├── Mf-ppc32le ├── Mf-i3s2 ├── Mf-a6osx ├── Mf-i3osx ├── Mf-a6s2 ├── Mf-ta6osx ├── Mf-ti3osx ├── Mf-a6le ├── Mf-ti3s2 ├── Mf-i3le ├── Mf-ta6s2 ├── Mf-tppc32le ├── Mf-ti3le ├── Mf-ta6le ├── Mf-i3fb ├── Mf-a6fb ├── Mf-i3ob ├── Mf-a6ob ├── Mf-i3qnx ├── Mf-ti3fb ├── sort.h ├── Mf-ta6fb ├── Mf-ti3ob ├── Mf-ta6ob ├── Mf-i3nb ├── Mf-a6nb ├── Mf-ta6nb ├── Mf-ti3nb ├── arm32le.c └── Mf-base ├── boot ├── a6le │ ├── petite.boot │ └── scheme.boot ├── a6nt │ ├── petite.boot │ └── scheme.boot ├── a6osx │ ├── petite.boot │ └── scheme.boot ├── i3le │ ├── petite.boot │ └── scheme.boot ├── i3nt │ ├── petite.boot │ └── scheme.boot ├── i3osx │ ├── petite.boot │ └── scheme.boot ├── ta6le │ ├── petite.boot │ └── scheme.boot ├── ta6nt │ ├── petite.boot │ └── scheme.boot ├── ti3le │ ├── petite.boot │ └── scheme.boot ├── ti3nt │ ├── petite.boot │ └── scheme.boot ├── ta6osx │ ├── petite.boot │ └── scheme.boot └── ti3osx │ ├── petite.boot │ └── scheme.boot ├── release_notes ├── gifs │ ├── ghostRightarrow.gif │ ├── Rightarrow.tex │ └── Makefile ├── macros.stex ├── math │ ├── mathmacros │ └── Makefile ├── Makefile └── scheme.sty ├── .gitignore ├── examples ├── fib.ss ├── power.ss ├── fact.ss ├── fatfib.ss ├── Makefile ├── scons.ss └── queue.ss ├── .gitmodules ├── unicode ├── Makefile └── ReadMe ├── s ├── Mf-i3fb ├── Mf-i3le ├── Mf-i3nb ├── Mf-i3ob ├── Mf-i3s2 ├── Mf-a6fb ├── Mf-a6le ├── Mf-a6nb ├── Mf-a6ob ├── Mf-a6osx ├── Mf-a6s2 ├── Mf-i3osx ├── Mf-i3qnx ├── Mf-ta6fb ├── Mf-ta6le ├── Mf-ta6nb ├── Mf-ta6ob ├── Mf-ta6s2 ├── Mf-ti3fb ├── Mf-ti3le ├── Mf-ti3nb ├── Mf-ti3ob ├── Mf-ti3osx ├── Mf-ti3s2 ├── Mf-arm32le ├── Mf-ppc32le ├── Mf-ta6osx ├── Mf-tppc32le ├── Mf-i3nt ├── env.ss ├── Mf-a6nt ├── Mf-ta6nt ├── Mf-ti3nt ├── cback.ss ├── primref.ss ├── setup.ss ├── patch.ss ├── Mf-cross ├── ubify.ss ├── hashtable-types.ss ├── bldnt.bat ├── i3fb.def ├── i3le.def ├── i3nb.def ├── i3ob.def ├── i3s2.def ├── a6fb.def ├── a6le.def ├── a6nb.def ├── a6ob.def └── a6s2.def ├── NOTICE └── makefiles ├── Mf-boot.in ├── Makefile-workarea.in └── Makefile.in /mats/patch-compile-3-f-f-t: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /mats/patch-compile-3-f-t-f: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /mats/patch-compile-3-t-f-f: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /mats/patch-compile-3-t-f-t: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /mats/patch-compile-3-t-t-f: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /csug/canned/csug.css: -------------------------------------------------------------------------------- 1 | ../csug.css -------------------------------------------------------------------------------- /csug/myfile.ss: -------------------------------------------------------------------------------- 1 | (+ 3 4) 2 | "hello" 3 | -------------------------------------------------------------------------------- /csug/setup.ss: -------------------------------------------------------------------------------- 1 | (reset-handler abort) 2 | -------------------------------------------------------------------------------- /c/cs.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/c/cs.ico -------------------------------------------------------------------------------- /boot/a6le/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/a6le/petite.boot -------------------------------------------------------------------------------- /boot/a6le/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/a6le/scheme.boot -------------------------------------------------------------------------------- /boot/a6nt/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/a6nt/petite.boot -------------------------------------------------------------------------------- /boot/a6nt/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/a6nt/scheme.boot -------------------------------------------------------------------------------- /boot/a6osx/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/a6osx/petite.boot -------------------------------------------------------------------------------- /boot/a6osx/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/a6osx/scheme.boot -------------------------------------------------------------------------------- /boot/i3le/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/i3le/petite.boot -------------------------------------------------------------------------------- /boot/i3le/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/i3le/scheme.boot -------------------------------------------------------------------------------- /boot/i3nt/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/i3nt/petite.boot -------------------------------------------------------------------------------- /boot/i3nt/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/i3nt/scheme.boot -------------------------------------------------------------------------------- /boot/i3osx/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/i3osx/petite.boot -------------------------------------------------------------------------------- /boot/i3osx/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/i3osx/scheme.boot -------------------------------------------------------------------------------- /boot/ta6le/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ta6le/petite.boot -------------------------------------------------------------------------------- /boot/ta6le/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ta6le/scheme.boot -------------------------------------------------------------------------------- /boot/ta6nt/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ta6nt/petite.boot -------------------------------------------------------------------------------- /boot/ta6nt/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ta6nt/scheme.boot -------------------------------------------------------------------------------- /boot/ti3le/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ti3le/petite.boot -------------------------------------------------------------------------------- /boot/ti3le/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ti3le/scheme.boot -------------------------------------------------------------------------------- /boot/ti3nt/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ti3nt/petite.boot -------------------------------------------------------------------------------- /boot/ti3nt/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ti3nt/scheme.boot -------------------------------------------------------------------------------- /boot/ta6osx/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ta6osx/petite.boot -------------------------------------------------------------------------------- /boot/ta6osx/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ta6osx/scheme.boot -------------------------------------------------------------------------------- /boot/ti3osx/petite.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ti3osx/petite.boot -------------------------------------------------------------------------------- /boot/ti3osx/scheme.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/boot/ti3osx/scheme.boot -------------------------------------------------------------------------------- /csug/canned/profview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/csug/canned/profview.png -------------------------------------------------------------------------------- /csug/canned/cisco-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/csug/canned/cisco-logo.png -------------------------------------------------------------------------------- /csug/canned/fatfibhtml.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/csug/canned/fatfibhtml.png -------------------------------------------------------------------------------- /csug/canned/profilehtml.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/csug/canned/profilehtml.png -------------------------------------------------------------------------------- /csug/gifs/ghostRightarrow.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/csug/gifs/ghostRightarrow.gif -------------------------------------------------------------------------------- /csug/canned/cisco-logo-large.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/csug/canned/cisco-logo-large.png -------------------------------------------------------------------------------- /csug/canned/cisco-logo-orig.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/csug/canned/cisco-logo-orig.png -------------------------------------------------------------------------------- /csug/canned/fatfibhtml-orig.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/csug/canned/fatfibhtml-orig.png -------------------------------------------------------------------------------- /csug/canned/profilehtml-orig.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/csug/canned/profilehtml-orig.png -------------------------------------------------------------------------------- /csug/gifs/Rightarrow.tex: -------------------------------------------------------------------------------- 1 | \documentclass[12pt]{article} 2 | \begin{document} 3 | \pagestyle{empty} 4 | $\Rightarrow$ 5 | \end{document} 6 | -------------------------------------------------------------------------------- /release_notes/gifs/ghostRightarrow.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/evilbinary/ChezScheme/master/release_notes/gifs/ghostRightarrow.gif -------------------------------------------------------------------------------- /release_notes/gifs/Rightarrow.tex: -------------------------------------------------------------------------------- 1 | \documentclass[12pt]{article} 2 | \begin{document} 3 | \pagestyle{empty} 4 | $\Rightarrow$ 5 | \end{document} 6 | -------------------------------------------------------------------------------- /mats/freq.out: -------------------------------------------------------------------------------- 1 | 1 A 2 | 1 If 3 | 4 Peter 4 | 4 Piper 5 | 1 Where 6 | 2 a 7 | 4 of 8 | 4 peck 9 | 4 peppers 10 | 4 picked 11 | 4 pickled 12 | 1 s 13 | 1 the 14 | -------------------------------------------------------------------------------- /mats/m4test.out: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | moveml &0x3f3e,DEC(SP) 21 | 22 | moveml INC(SP),&0x7cfc 23 | -------------------------------------------------------------------------------- /mats/freq.in: -------------------------------------------------------------------------------- 1 | Peter Piper picked a peck of pickled peppers; 2 | A peck of pickled peppers Peter Piper picked. 3 | If Peter Piper picked a peck of pickled peppers, 4 | Where's the peck of pickled peppers Peter Piper picked? 5 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *~ 2 | .*.sw? 3 | .sw? 4 | /Makefile 5 | /a6le/ 6 | /a6nt/ 7 | /a6osx/ 8 | /bin/ 9 | /i3le/ 10 | /i3nt/ 11 | /i3osx/ 12 | /TAGS 13 | /ta6le/ 14 | /ta6nt/ 15 | /ta6osx/ 16 | /ti3le/ 17 | /ti3nt/ 18 | /ti3osx/ 19 | -------------------------------------------------------------------------------- /examples/fib.ss: -------------------------------------------------------------------------------- 1 | ;;; simple fibonacci function 2 | 3 | ;;; uses trace-lambda to show the nesting 4 | 5 | (define fib 6 | (trace-lambda fib (x) 7 | (if (<= x 1) 8 | 1 9 | (+ (fib (- x 1)) (fib (- x 2)))))) 10 | -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "zlib"] 2 | path = zlib 3 | url = https://github.com/madler/zlib.git 4 | [submodule "nanopass"] 5 | path = nanopass 6 | url = https://github.com/nanopass/nanopass-framework-scheme.git 7 | [submodule "stex"] 8 | path = stex 9 | url = https://github.com/dybvig/stex 10 | -------------------------------------------------------------------------------- /release_notes/macros.stex: -------------------------------------------------------------------------------- 1 | \def\ChezScheme{\textsl{Chez Scheme}} 2 | \def\PetiteChezScheme{\textsl{Petite Chez Scheme}} 3 | \def\CSUG#1{\hyperlink{http://www.scheme.com/csug#1/}{\emph{Chez Scheme Version #1 User's Guide}}} 4 | \def\TSPL#1#2{\hyperlink{http://www.scheme.com/tspl#1/}{\emph{The Scheme Programming Language, #1#2 edition}}} 5 | -------------------------------------------------------------------------------- /examples/power.ss: -------------------------------------------------------------------------------- 1 | ;;; doubly recursive power (expt) function 2 | 3 | ;;; try using trace-lambda to see the nesting. 4 | 5 | (define power 6 | (lambda (x n) 7 | (cond 8 | [(= n 0) 1] 9 | [(= n 1) x] 10 | [else 11 | (let ([q (quotient n 2)]) 12 | (* (power x q) (power x (- n q))))]))) 13 | -------------------------------------------------------------------------------- /examples/fact.ss: -------------------------------------------------------------------------------- 1 | ;;; simple factorial function 2 | 3 | ;;; it is interesting to change the 'lambda' into 'trace-lambda' 4 | ;;; or simply type (trace fact) before running fact to observe 5 | ;;; the nesting of recursive calls. 6 | 7 | (define fact 8 | (lambda (x) 9 | (if (zero? x) 10 | 1 11 | (* x (fact (1- x)))))) 12 | -------------------------------------------------------------------------------- /csug/tspl4/title.aux: -------------------------------------------------------------------------------- 1 | \relax 2 | \@setckpt{title}{ 3 | \setcounter{page}{4} 4 | \setcounter{equation}{0} 5 | \setcounter{enumi}{0} 6 | \setcounter{enumii}{0} 7 | \setcounter{enumiii}{0} 8 | \setcounter{enumiv}{0} 9 | \setcounter{footnote}{0} 10 | \setcounter{mpfootnote}{0} 11 | \setcounter{chapter}{0} 12 | \setcounter{section}{0} 13 | \setcounter{exercise}{0} 14 | \setcounter{alphacount}{0} 15 | } 16 | -------------------------------------------------------------------------------- /csug/tspl4/contents.aux: -------------------------------------------------------------------------------- 1 | \relax 2 | \@setckpt{contents}{ 3 | \setcounter{page}{9} 4 | \setcounter{equation}{0} 5 | \setcounter{enumi}{0} 6 | \setcounter{enumii}{0} 7 | \setcounter{enumiii}{0} 8 | \setcounter{enumiv}{0} 9 | \setcounter{footnote}{0} 10 | \setcounter{mpfootnote}{0} 11 | \setcounter{chapter}{0} 12 | \setcounter{section}{0} 13 | \setcounter{exercise}{0} 14 | \setcounter{alphacount}{0} 15 | } 16 | -------------------------------------------------------------------------------- /csug/tspl4/copyright.aux: -------------------------------------------------------------------------------- 1 | \relax 2 | \@setckpt{copyright}{ 3 | \setcounter{page}{5} 4 | \setcounter{equation}{0} 5 | \setcounter{enumi}{0} 6 | \setcounter{enumii}{0} 7 | \setcounter{enumiii}{0} 8 | \setcounter{enumiv}{0} 9 | \setcounter{footnote}{0} 10 | \setcounter{mpfootnote}{0} 11 | \setcounter{chapter}{0} 12 | \setcounter{section}{0} 13 | \setcounter{exercise}{0} 14 | \setcounter{alphacount}{0} 15 | } 16 | -------------------------------------------------------------------------------- /mats/bldnt.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | set m=%1 3 | set o=%2 4 | if "%o%"=="" set o=0 5 | echo (time (compile-file "mat")) | ..\bin\%m%\scheme -q 6 | cl /I../boot/%m% /nologo -c -DWIN32 foreign1.c 7 | cl /I../boot/%m% /nologo -c -DWIN32 foreign2.c 8 | cl /I../boot/%m% /nologo -c -DWIN32 foreign3.c 9 | cl /nologo /DWIN32 cat_flush.c 10 | link -dll -out:foreign1.so foreign1.obj foreign2.obj foreign3.obj ..\bin\%m%\csv941.lib 11 | ..\bin\%m%\scheme -q mat.so < script.all%o% 12 | -------------------------------------------------------------------------------- /examples/fatfib.ss: -------------------------------------------------------------------------------- 1 | ;;; fat fibonacci function 2 | 3 | ;;; this is "fat" because it uses only increments and decrements 4 | ;;; for addition and subtraction (i.e., peano arithmetic). 5 | 6 | ;;; note that fat+ is tail-recursive; this is how all looping is 7 | ;;; performed in Scheme. 8 | 9 | (define fat+ 10 | (lambda (x y) 11 | (if (zero? y) 12 | x 13 | (fat+ (1+ x) (1- y))))) 14 | 15 | (define fatfib 16 | (lambda (x) 17 | (if (< x 2) 18 | 1 19 | (fat+ (fatfib (1- x)) (fatfib (1- (1- x))))))) 20 | -------------------------------------------------------------------------------- /csug/tspl4/summary.aux: -------------------------------------------------------------------------------- 1 | \relax 2 | \@writefile{toc}{\contentsline {chapter}{Summary of Forms}{463}} 3 | \@writefile{lof}{\addvspace {10\p@ }} 4 | \@writefile{lot}{\addvspace {10\p@ }} 5 | \@setckpt{summary}{ 6 | \setcounter{page}{481} 7 | \setcounter{equation}{0} 8 | \setcounter{enumi}{8} 9 | \setcounter{enumii}{0} 10 | \setcounter{enumiii}{0} 11 | \setcounter{enumiv}{32} 12 | \setcounter{footnote}{0} 13 | \setcounter{mpfootnote}{0} 14 | \setcounter{chapter}{12} 15 | \setcounter{section}{11} 16 | \setcounter{exercise}{7} 17 | \setcounter{alphacount}{6} 18 | } 19 | -------------------------------------------------------------------------------- /csug/tspl4/tspl.aux: -------------------------------------------------------------------------------- 1 | \relax 2 | \@input{title.aux} 3 | \@input{copyright.aux} 4 | \@input{contents.aux} 5 | \@input{preface.aux} 6 | \@input{intro.aux} 7 | \@input{start.aux} 8 | \@input{further.aux} 9 | \@input{binding.aux} 10 | \@input{control.aux} 11 | \@input{objects.aux} 12 | \@input{io.aux} 13 | \@input{syntax.aux} 14 | \@input{records.aux} 15 | \@input{libraries.aux} 16 | \@input{exceptions.aux} 17 | \@input{examples.aux} 18 | \@input{bibliography.aux} 19 | \@input{answers.aux} 20 | \@input{grammar.aux} 21 | \@input{summary.aux} 22 | \@writefile{toc}{\contentsline {chapter}{Index}{481}} 23 | -------------------------------------------------------------------------------- /unicode/Makefile: -------------------------------------------------------------------------------- 1 | Scheme=../bin/scheme 2 | 3 | doit: unicode-char-cases.ss unicode-charinfo.ss 4 | 5 | unicode-char-cases.ss: extract-char-cases.ss unicode-data.ss 6 | echo | $(Scheme) -q extract-char-cases.ss 7 | 8 | unicode-charinfo.ss: extract-info.ss unicode-data.ss 9 | echo | $(Scheme) -q extract-info.ss 10 | 11 | unicode-char-cases.ss: \ 12 | UNIDATA/CompositionExclusions.txt\ 13 | UNIDATA/UnicodeData.txt\ 14 | UNIDATA/CaseFolding.txt\ 15 | UNIDATA/SpecialCasing.txt 16 | 17 | unicode-charinfo.ss: \ 18 | UNIDATA/UnicodeData.txt\ 19 | UNIDATA/WordBreakProperty.txt\ 20 | UNIDATA/PropList.txt 21 | 22 | -------------------------------------------------------------------------------- /unicode/ReadMe: -------------------------------------------------------------------------------- 1 | To rebuild unicode-char-cases.ss and unicode-charinfo.ss, download into 2 | ./UNIDATA the following files: 3 | 4 | http://www.unicode.org/Public/UCD/latest/ucd/CompositionExclusions.txt 5 | http://www.unicode.org/Public/UCD/latest/ucd/UnicodeData.txt 6 | http://www.unicode.org/Public/UCD/latest/ucd/CaseFolding.txt 7 | http://www.unicode.org/Public/UCD/latest/ucd/SpecialCasing.txt 8 | http://www.unicode.org/Public/UCD/latest/ucd/auxiliary/WordBreakProperty.txt 9 | http://www.unicode.org/Public/UCD/latest/ucd/PropList.txt 10 | http://www.unicode.org/Public/UCD/latest/ucd/NormalizationTest.txt 11 | 12 | Then run 'make'. 13 | -------------------------------------------------------------------------------- /csug/tspl4/answers.aux: -------------------------------------------------------------------------------- 1 | \relax 2 | \@writefile{toc}{\contentsline {chapter}{Answers to Selected Exercises}{435}} 3 | \@writefile{lof}{\addvspace {10\p@ }} 4 | \@writefile{lot}{\addvspace {10\p@ }} 5 | \newlabel{listapply}{{2}{437}} 6 | \newlabel{cdrapply}{{4}{437}} 7 | \@setckpt{answers}{ 8 | \setcounter{page}{454} 9 | \setcounter{equation}{0} 10 | \setcounter{enumi}{8} 11 | \setcounter{enumii}{0} 12 | \setcounter{enumiii}{0} 13 | \setcounter{enumiv}{32} 14 | \setcounter{footnote}{0} 15 | \setcounter{mpfootnote}{0} 16 | \setcounter{chapter}{12} 17 | \setcounter{section}{11} 18 | \setcounter{exercise}{7} 19 | \setcounter{alphacount}{6} 20 | } 21 | -------------------------------------------------------------------------------- /csug/math/mathmacros: -------------------------------------------------------------------------------- 1 | \catcode`@=11 % borrow the private macros of PLAIN (with care) 2 | \def\W#1{W_{\!\!#1}} 3 | \def\fftcases#1{\left\{\,\vcenter{\m@th\baselineskip=18pt 4 | \ialign{$##\hfil$&\quad##\hfil\crcr#1\crcr}}\right.} 5 | \input epsf 6 | 7 | \setlength\fboxrule{.4\p@} 8 | \newlength{\chpicsize} 9 | \setlength{\chpicsize}{30pc} 10 | \addtolength{\chpicsize}{-\fboxrule} 11 | \addtolength{\chpicsize}{-\fboxrule} 12 | \def\chpic#1{\begingroup% 13 | \def\epsfsize##1##2{##1} 14 | \fboxsep=0pt 15 | \vbox{\noindent% 16 | \fbox{\vbox{\hbox to \chpicsize{\hfil\vbox to \chpicsize{\vfil% 17 | \epsfbox{#1}\vfil}\hfil}}}}\endgroup} 18 | -------------------------------------------------------------------------------- /csug/math/Makefile: -------------------------------------------------------------------------------- 1 | include mathfiles 2 | 3 | density=-r90x90 4 | 5 | .SUFFIXES: 6 | .SUFFIXES: .tex .gif 7 | 8 | # translate ps file to ppm, crop to minimum background, and translate ppm 9 | # to gif with white (background) transparent 10 | # 11 | .tex.gif: 12 | echo | latex $* &&\ 13 | dvips -f < $*.dvi |\ 14 | gs -q -dNOPAUSE -dSAFER -sDEVICE=ppmraw -sOutputFile=-\ 15 | ${density} - |\ 16 | pnmcrop |\ 17 | ppmtogif -transparent white > $*.gif 18 | /bin/rm -f $*.dvi $*.log $*.aux 19 | test -f $*.gif && chmod 644 $*.gif 20 | 21 | all: ${gifs} 22 | 23 | ${gifs}: mathmacros 24 | 25 | clean: ; /bin/rm -f *.gif Make.out 26 | -------------------------------------------------------------------------------- /release_notes/math/mathmacros: -------------------------------------------------------------------------------- 1 | \catcode`@=11 % borrow the private macros of PLAIN (with care) 2 | \def\W#1{W_{\!\!#1}} 3 | \def\fftcases#1{\left\{\,\vcenter{\m@th\baselineskip=18pt 4 | \ialign{$##\hfil$&\quad##\hfil\crcr#1\crcr}}\right.} 5 | \input epsf 6 | 7 | \usepackage{graphicx} 8 | 9 | \setlength\fboxrule{.4\p@} 10 | \newlength{\chpicsize} 11 | \setlength{\chpicsize}{30pc} 12 | \addtolength{\chpicsize}{-\fboxrule} 13 | \addtolength{\chpicsize}{-\fboxrule} 14 | \def\chpic#1{\begingroup% 15 | \def\epsfsize##1##2{##1} 16 | \fboxsep=0pt 17 | \vbox{\noindent% 18 | \fbox{\vbox{\hbox to \chpicsize{\hfil\vbox to \chpicsize{\vfil% 19 | \epsfbox{#1}\vfil}\hfil}}}}\endgroup} 20 | -------------------------------------------------------------------------------- /csug/oop.stex: -------------------------------------------------------------------------------- 1 | % Copyright 2005-2016 Cisco Systems, Inc. 2 | % 3 | % Licensed under the Apache License, Version 2.0 (the "License"); 4 | % you may not use this file except in compliance with the License. 5 | % You may obtain a copy of the License at 6 | % 7 | % http://www.apache.org/licenses/LICENSE-2.0 8 | % 9 | % Unless required by applicable law or agreed to in writing, software 10 | % distributed under the License is distributed on an "AS IS" BASIS, 11 | % WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | % See the License for the specific language governing permissions and 13 | % limitations under the License. 14 | % uncomment Thread System Oop Interface section in threads.stex 15 | -------------------------------------------------------------------------------- /release_notes/math/Makefile: -------------------------------------------------------------------------------- 1 | include mathfiles 2 | 3 | density=-r90x90 4 | 5 | .SUFFIXES: 6 | .SUFFIXES: .tex .gif 7 | 8 | # translate ps file to ppm, crop to minimum background, and translate ppm 9 | # to gif with white (background) transparent 10 | # 11 | .tex.gif: 12 | TEXINPUTS=.:../..:$(TEXINPUTS);\ 13 | echo | latex $* &&\ 14 | dvips -f < $*.dvi |\ 15 | gs -q -dNOPAUSE -dSAFER -sDEVICE=ppmraw -sOutputFile=-\ 16 | ${density} - |\ 17 | pnmcrop |\ 18 | ppmtogif -transparent white > $*.gif 19 | /bin/rm -f $*.dvi $*.log $*.aux 20 | test -f $*.gif && chmod 644 $*.gif 21 | 22 | all: ${gifs} 23 | 24 | ${gifs}: mathmacros 25 | 26 | clean: ; /bin/rm -f *.gif Make.out 27 | -------------------------------------------------------------------------------- /s/Mf-i3fb: -------------------------------------------------------------------------------- 1 | # Mf-i3fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3fb 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-i3le: -------------------------------------------------------------------------------- 1 | # Mf-i3le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3le 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-i3nb: -------------------------------------------------------------------------------- 1 | # Mf-i3nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3nb 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-i3ob: -------------------------------------------------------------------------------- 1 | # Mf-i3ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3ob 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-i3s2: -------------------------------------------------------------------------------- 1 | # Mf-i3s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3s2 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /c/statics.c: -------------------------------------------------------------------------------- 1 | /* statics.c 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #define EXTERN 18 | #include "system.h" 19 | -------------------------------------------------------------------------------- /s/Mf-a6fb: -------------------------------------------------------------------------------- 1 | # Mf-a6fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6fb 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-a6le: -------------------------------------------------------------------------------- 1 | # Mf-a6le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6le 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-a6nb: -------------------------------------------------------------------------------- 1 | # Mf-a6nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6nb 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-a6ob: -------------------------------------------------------------------------------- 1 | # Mf-a6ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6ob 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-a6osx: -------------------------------------------------------------------------------- 1 | # Mf-a6osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6osx 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-a6s2: -------------------------------------------------------------------------------- 1 | # Mf-a6s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6s2 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-i3osx: -------------------------------------------------------------------------------- 1 | # Mf-i3osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3osx 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-i3qnx: -------------------------------------------------------------------------------- 1 | # Mf-i3qnx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3qnx 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ta6fb: -------------------------------------------------------------------------------- 1 | # Mf-ta6fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6fb 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ta6le: -------------------------------------------------------------------------------- 1 | # Mf-ta6le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6le 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ta6nb: -------------------------------------------------------------------------------- 1 | # Mf-ta6nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6nb 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ta6ob: -------------------------------------------------------------------------------- 1 | # Mf-ta6ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6ob 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ta6s2: -------------------------------------------------------------------------------- 1 | # Mf-ta6s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6s2 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ti3fb: -------------------------------------------------------------------------------- 1 | # Mf-ti3fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3fb 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ti3le: -------------------------------------------------------------------------------- 1 | # Mf-ti3le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3le 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ti3nb: -------------------------------------------------------------------------------- 1 | # Mf-ti3nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3nb 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ti3ob: -------------------------------------------------------------------------------- 1 | # Mf-ti3ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3ob 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ti3osx: -------------------------------------------------------------------------------- 1 | # Mf-ti3osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3osx 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ti3s2: -------------------------------------------------------------------------------- 1 | # Mf-ti3s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3s2 17 | archincludes = x86.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /c/gc-ocd.c: -------------------------------------------------------------------------------- 1 | /* gc-ocd.c 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #define GCENTRY S_gc_ocd 18 | #include "gc.c" 19 | -------------------------------------------------------------------------------- /s/Mf-arm32le: -------------------------------------------------------------------------------- 1 | # Mf-arm32le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = arm32le 17 | archincludes = arm32.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ppc32le: -------------------------------------------------------------------------------- 1 | # Mf-ppc32le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ppc32le 17 | archincludes = ppc32.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-ta6osx: -------------------------------------------------------------------------------- 1 | # Mf-ta6osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6osx 17 | archincludes = x86_64.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-tppc32le: -------------------------------------------------------------------------------- 1 | # Mf-tppc32le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = tppc32le 17 | archincludes = ppc32.ss 18 | 19 | include Mf-base 20 | -------------------------------------------------------------------------------- /s/Mf-i3nt: -------------------------------------------------------------------------------- 1 | # Mf-i3nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3nt 17 | archincludes = x86.ss 18 | buildsrc = bldnt.bat 19 | 20 | include Mf-base 21 | -------------------------------------------------------------------------------- /s/env.ss: -------------------------------------------------------------------------------- 1 | "env.ss" 2 | ;;; env.ss 3 | ;;; Copyright 1984-2016 Cisco Systems, Inc. 4 | ;;; 5 | ;;; Licensed under the Apache License, Version 2.0 (the "License"); 6 | ;;; you may not use this file except in compliance with the License. 7 | ;;; You may obtain a copy of the License at 8 | ;;; 9 | ;;; http://www.apache.org/licenses/LICENSE-2.0 10 | ;;; 11 | ;;; Unless required by applicable law or agreed to in writing, software 12 | ;;; distributed under the License is distributed on an "AS IS" BASIS, 13 | ;;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | ;;; See the License for the specific language governing permissions and 15 | ;;; limitations under the License. 16 | 17 | ($make-base-modules) 18 | ($make-rnrs-libraries) 19 | -------------------------------------------------------------------------------- /s/Mf-a6nt: -------------------------------------------------------------------------------- 1 | # Mf-a6nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6nt 17 | archincludes = x86_64.ss 18 | buildsrc = bldnt.bat 19 | 20 | include Mf-base 21 | -------------------------------------------------------------------------------- /s/Mf-ta6nt: -------------------------------------------------------------------------------- 1 | # Mf-ta6nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6nt 17 | archincludes = x86_64.ss 18 | buildsrc = bldnt.bat 19 | 20 | include Mf-base 21 | -------------------------------------------------------------------------------- /s/Mf-ti3nt: -------------------------------------------------------------------------------- 1 | # Mf-ti3nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3nt 17 | archincludes = x86.ss 18 | buildsrc = bldnt.bat 19 | 20 | include Mf-base 21 | -------------------------------------------------------------------------------- /c/gc-oce.c: -------------------------------------------------------------------------------- 1 | /* gc-oce.c 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #define GCENTRY S_gc_oce 18 | #define ENABLE_OBJECT_COUNTS 19 | #include "gc.c" 20 | -------------------------------------------------------------------------------- /s/cback.ss: -------------------------------------------------------------------------------- 1 | "cback.ss" 2 | ;;; cback.ss 3 | ;;; Copyright 1984-2016 Cisco Systems, Inc. 4 | ;;; 5 | ;;; Licensed under the Apache License, Version 2.0 (the "License"); 6 | ;;; you may not use this file except in compliance with the License. 7 | ;;; You may obtain a copy of the License at 8 | ;;; 9 | ;;; http://www.apache.org/licenses/LICENSE-2.0 10 | ;;; 11 | ;;; Unless required by applicable law or agreed to in writing, software 12 | ;;; distributed under the License is distributed on an "AS IS" BASIS, 13 | ;;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | ;;; See the License for the specific language governing permissions and 15 | ;;; limitations under the License. 16 | 17 | (current-eval compile) 18 | (define $compiler-is-loaded? #t) 19 | -------------------------------------------------------------------------------- /csug/bibliography.stex: -------------------------------------------------------------------------------- 1 | % Copyright 2005-2016 Cisco Systems, Inc. 2 | % 3 | % Licensed under the Apache License, Version 2.0 (the "License"); 4 | % you may not use this file except in compliance with the License. 5 | % You may obtain a copy of the License at 6 | % 7 | % http://www.apache.org/licenses/LICENSE-2.0 8 | % 9 | % Unless required by applicable law or agreed to in writing, software 10 | % distributed under the License is distributed on an "AS IS" BASIS, 11 | % WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | % See the License for the specific language governing permissions and 13 | % limitations under the License. 14 | \ifhtml 15 | \chapter{Bibliography} 16 | \input{csug.bbl} 17 | \else 18 | \bibliographystyle{tspl} 19 | \bibliography{csug} 20 | \fi 21 | -------------------------------------------------------------------------------- /c/scheme.rc: -------------------------------------------------------------------------------- 1 | #include "winver.h" 2 | 3 | VS_VERSION_INFO VERSIONINFO 4 | FILEVERSION 9,4,1,0 5 | PRODUCTVERSION 9,4,1,0 6 | FILEFLAGSMASK 0x3fL 7 | FILEFLAGS 0x0L 8 | FILEOS VOS__WINDOWS32 9 | FILETYPE VFT_APP 10 | FILESUBTYPE VFT2_UNKNOWN 11 | { 12 | BLOCK "StringFileInfo" { 13 | BLOCK "04090000" { 14 | VALUE "CompanyName", "Cisco Systems, Inc." 15 | VALUE "FileDescription", "Chez Scheme Version 9.4.1" 16 | VALUE "FileVersion", "9.4.1" 17 | VALUE "InternalName", "scheme.exe" 18 | VALUE "LegalCopyright", "Copyright 1984-2016 Cisco Systems, Inc. Licensed under the Apache License, Version 2.0." 19 | VALUE "OriginalFilename", "scheme.exe" 20 | VALUE "ProductName", "Chez Scheme" 21 | VALUE "ProductVersion", "9.4.1" 22 | } 23 | } 24 | BLOCK "VarFileInfo" { 25 | VALUE "Translation", 0x409, 0 26 | } 27 | } 28 | 29 | scheme ICON "cs.ico" 30 | -------------------------------------------------------------------------------- /csug/contents.stex: -------------------------------------------------------------------------------- 1 | % Copyright 2005-2016 Cisco Systems, Inc. 2 | % 3 | % Licensed under the Apache License, Version 2.0 (the "License"); 4 | % you may not use this file except in compliance with the License. 5 | % You may obtain a copy of the License at 6 | % 7 | % http://www.apache.org/licenses/LICENSE-2.0 8 | % 9 | % Unless required by applicable law or agreed to in writing, software 10 | % distributed under the License is distributed on an "AS IS" BASIS, 11 | % WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | % See the License for the specific language governing permissions and 13 | % limitations under the License. 14 | \iflatex 15 | \begingroup 16 | \baselineskip=15pt plus 1pt 17 | \normalbaselineskip=\baselineskip 18 | \renewcommand{\baselinestretch}{1.5} 19 | \tableofcontents 20 | \endgroup 21 | \fi 22 | 23 | \ifhtml 24 | \begin{contents} 25 | \fi 26 | -------------------------------------------------------------------------------- /mats/killme.c: -------------------------------------------------------------------------------- 1 | /* killme.c 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #include 18 | #include 19 | #include 20 | 21 | int main(argc, argv) int argc; char *argv[]; { 22 | kill(getppid(), atoi(argv[1])); 23 | exit(0); 24 | } 25 | -------------------------------------------------------------------------------- /csug/canned/copyright.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | Copyright Notice 4 | 5 | 6 | 7 | 8 |

9 | © 2005-2015 Cisco Systems, Inc.
10 | Licensed under the Apache License Version 2.0.
11 | Revised April 2016 for Chez Scheme Version 9.3.4. 12 |

13 | 14 |

15 | Cisco and the Cisco logo are trademarks or registered trademarks 16 | of Cisco and/or its affiliates in the U.S. and other countries. To 17 | view a list of Cisco trademarks, go to this URL: 18 | http://www.cisco.com/go/trademarks. Third-party trademarks mentioned 19 | are the property of their respective owners. The use of the word 20 | partner does not imply a partnership relationship between Cisco and 21 | any other company. (1110R) 22 |

23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /csug/tspl4/preface.aux: -------------------------------------------------------------------------------- 1 | \relax 2 | \citation{Steele:scheme} 3 | \citation{Sussman-Steele:HOSC98} 4 | \citation{Friedman:lisper} 5 | \citation{IEEE:1178} 6 | \citation{r6rs} 7 | \citation{Dybvig:csug8} 8 | \@writefile{toc}{\contentsline {chapter}{Preface}{ix}} 9 | \@writefile{lof}{\addvspace {10\p@ }} 10 | \@writefile{lot}{\addvspace {10\p@ }} 11 | \newlabel{./preface:s0}{{}{ix}} 12 | \newlabel{./preface:s1}{{}{ix}} 13 | \newlabel{./preface:s2}{{}{ix}} 14 | \newlabel{./preface:s3}{{}{ix}} 15 | \newlabel{./preface:s4}{{}{ix}} 16 | \@setckpt{preface}{ 17 | \setcounter{page}{13} 18 | \setcounter{equation}{0} 19 | \setcounter{enumi}{0} 20 | \setcounter{enumii}{0} 21 | \setcounter{enumiii}{0} 22 | \setcounter{enumiv}{0} 23 | \setcounter{footnote}{0} 24 | \setcounter{mpfootnote}{0} 25 | \setcounter{chapter}{0} 26 | \setcounter{section}{0} 27 | \setcounter{exercise}{0} 28 | \setcounter{alphacount}{0} 29 | } 30 | -------------------------------------------------------------------------------- /c/i3le.c: -------------------------------------------------------------------------------- 1 | /* i3le.c 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #include "system.h" 18 | 19 | #include 20 | #include 21 | 22 | #ifdef FLUSHCACHE 23 | oops, no S_flushcache_max_gap or S_doflush 24 | #endif /* FLUSHCACHE */ 25 | 26 | void S_machine_init() {} 27 | -------------------------------------------------------------------------------- /s/primref.ss: -------------------------------------------------------------------------------- 1 | ;;; primref.ss 2 | ;;; Copyright 1984-2016 Cisco Systems, Inc. 3 | ;;; 4 | ;;; Licensed under the Apache License, Version 2.0 (the "License"); 5 | ;;; you may not use this file except in compliance with the License. 6 | ;;; You may obtain a copy of the License at 7 | ;;; 8 | ;;; http://www.apache.org/licenses/LICENSE-2.0 9 | ;;; 10 | ;;; Unless required by applicable law or agreed to in writing, software 11 | ;;; distributed under the License is distributed on an "AS IS" BASIS, 12 | ;;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | ;;; See the License for the specific language governing permissions and 14 | ;;; limitations under the License. 15 | 16 | (define-record-type primref 17 | (nongenerative #{primref a0xltlrcpeygsahopkplcn-2}) 18 | (sealed #t) 19 | (fields name flags arity)) 20 | 21 | (define primref-level 22 | (lambda (pr) 23 | (if (all-set? (prim-mask unsafe) (primref-flags pr)) 3 2))) 24 | -------------------------------------------------------------------------------- /s/setup.ss: -------------------------------------------------------------------------------- 1 | ;;; setup.ss 2 | ;;; Copyright 1984-2016 Cisco Systems, Inc. 3 | ;;; 4 | ;;; Licensed under the Apache License, Version 2.0 (the "License"); 5 | ;;; you may not use this file except in compliance with the License. 6 | ;;; You may obtain a copy of the License at 7 | ;;; 8 | ;;; http://www.apache.org/licenses/LICENSE-2.0 9 | ;;; 10 | ;;; Unless required by applicable law or agreed to in writing, software 11 | ;;; distributed under the License is distributed on an "AS IS" BASIS, 12 | ;;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | ;;; See the License for the specific language governing permissions and 14 | ;;; limitations under the License. 15 | 16 | (include "debug.ss") 17 | 18 | (base-exception-handler 19 | (lambda (c) 20 | (fresh-line) 21 | (display-condition c) 22 | (newline) 23 | (reset))) 24 | 25 | (keyboard-interrupt-handler 26 | (lambda () 27 | (display "interrupted---aborting\n") 28 | (reset))) 29 | -------------------------------------------------------------------------------- /mats/Mf-a6fb: -------------------------------------------------------------------------------- 1 | # Mf-a6fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6fb 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-a6nb: -------------------------------------------------------------------------------- 1 | # Mf-a6nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6nb 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-a6ob: -------------------------------------------------------------------------------- 1 | # Mf-a6ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6ob 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-i3fb: -------------------------------------------------------------------------------- 1 | # Mf-i3fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3fb 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-i3nb: -------------------------------------------------------------------------------- 1 | # Mf-i3nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3nb 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-i3ob: -------------------------------------------------------------------------------- 1 | # Mf-i3ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3ob 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-a6le: -------------------------------------------------------------------------------- 1 | # Mf-a6le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6le 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m64 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-i3le: -------------------------------------------------------------------------------- 1 | # Mf-i3le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3le 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m32 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ta6fb: -------------------------------------------------------------------------------- 1 | # Mf-ta6fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6fb 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ta6nb: -------------------------------------------------------------------------------- 1 | # Mf-ta6nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6nb 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ta6ob: -------------------------------------------------------------------------------- 1 | # Mf-ta6ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6ob 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ti3fb: -------------------------------------------------------------------------------- 1 | # Mf-ti3fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3fb 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ti3nb: -------------------------------------------------------------------------------- 1 | # Mf-ti3nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3nb 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ti3ob: -------------------------------------------------------------------------------- 1 | # Mf-ti3ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3ob 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /c/symbol.c: -------------------------------------------------------------------------------- 1 | /* symbol.c 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #include "system.h" 18 | 19 | ptr S_symbol_value(sym) ptr sym; { 20 | if (SYMVAL(sym) == sunbound) 21 | S_error1("","~s is not bound", sym); 22 | return SYMVAL(sym); 23 | } 24 | 25 | void S_set_symbol_value(sym, val) ptr sym, val; { 26 | SETSYMVAL(sym, val); 27 | SETSYMCODE(sym, Sprocedurep(val) ? CLOSCODE(val) : S_G.nonprocedure_code); 28 | } 29 | -------------------------------------------------------------------------------- /mats/Mf-a6osx: -------------------------------------------------------------------------------- 1 | # Mf-a6osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6osx 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m64 -dynamiclib -undefined dynamic_lookup -I${Include} -o foreign1.so ${fsrc} 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-a6s2: -------------------------------------------------------------------------------- 1 | # Mf-a6s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6s2 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | gcc -m64 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | gcc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | gcc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-arm32le: -------------------------------------------------------------------------------- 1 | # Mf-arm32le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = arm32le 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-i3osx: -------------------------------------------------------------------------------- 1 | # Mf-i3osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3osx 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m32 -dynamiclib -undefined dynamic_lookup -I${Include} -o foreign1.so ${fsrc} 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-i3qnx: -------------------------------------------------------------------------------- 1 | # Mf-i3qnx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3qnx 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m32 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-i3s2: -------------------------------------------------------------------------------- 1 | # Mf-i3s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3s2 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | gcc -m32 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | gcc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | gcc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ta6le: -------------------------------------------------------------------------------- 1 | # Mf-ta6le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6le 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m64 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ta6osx: -------------------------------------------------------------------------------- 1 | # Mf-ta6osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6osx 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m64 -dynamiclib -undefined dynamic_lookup -I${Include} -o foreign1.so ${fsrc} 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ta6s2: -------------------------------------------------------------------------------- 1 | # Mf-ta6s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6s2 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | gcc -m64 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | gcc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | gcc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ti3le: -------------------------------------------------------------------------------- 1 | # Mf-ti3le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3le 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m32 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ti3osx: -------------------------------------------------------------------------------- 1 | # Mf-ti3osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3osx 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m32 -dynamiclib -undefined dynamic_lookup -I${Include} -o foreign1.so ${fsrc} 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ti3s2: -------------------------------------------------------------------------------- 1 | # Mf-ti3s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3s2 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | gcc -m32 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | gcc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | gcc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-ppc32le: -------------------------------------------------------------------------------- 1 | # Mf-ppc32le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ppc32le 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m32 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /mats/Mf-tppc32le: -------------------------------------------------------------------------------- 1 | # Mf-tppc32le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = tppc32le 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | fobj = foreign1.so 20 | 21 | include Mf-base 22 | 23 | foreign1.so: ${fsrc} ../boot/$m/scheme.h 24 | cc -m32 -fPIC -shared -I${Include} -o foreign1.so foreign1.c foreign2.c foreign3.c 25 | 26 | cat_flush: cat_flush.c 27 | cc -o cat_flush cat_flush.c 28 | 29 | killme: killme.c 30 | cc -o killme killme.c 31 | -------------------------------------------------------------------------------- /c/Mf-i3nt: -------------------------------------------------------------------------------- 1 | # Mf-i3nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3nt 17 | Cpu = I386 18 | 19 | clib= 20 | o = obj 21 | mdobj=windows.$o 22 | mdsrc=windows.c Makefile.$m cs.ico scheme.rc make.bat 23 | mdclean=make.bat scheme.res ../bin/$m/*.exp mtscheme.exe* mdscheme.exe* 24 | 25 | include Mf-base 26 | 27 | # currently creating datestamp at 'make source' time 28 | datestamp.c: 29 | 30 | make.bat: 31 | echo "@nmake /nologo -f Makefile.$m %*" > make.bat 32 | -------------------------------------------------------------------------------- /NOTICE: -------------------------------------------------------------------------------- 1 | Chez Scheme Version 9.4.1 2 | Copyright 1984-2016 Cisco Systems, Inc. 3 | 4 | This product includes code developed by Cisco Systems, Inc. 5 | 6 | This product also includes separately copyrighted: 7 | 8 | * Unicode data files from the Unicode Consortium 9 | 10 | * Unicode data-file processing code developed by Abdulaziz Ghuloum and 11 | R. Kent Dybvig 12 | 13 | * sorting code developed by Olin Shivers 14 | 15 | * example programs, an html formatting module, and documentation 16 | support files developed by R. Kent Dybvig 17 | 18 | * test code and other code used for testing developed by 19 | William D Clinger, by Dirk Lutzebaeck, and by Oscar Waddell and 20 | R. Kent Dybvig. 21 | 22 | * code derived from C. David Boyer's command-line editor 23 | 24 | Builds of this product incorporate separately copyrighted code from: 25 | 26 | * the Nanopass Infrastructure, developed by Dipanwita Sarkar, 27 | Andrew W. Keep, R. Kent Dybvig, and Oscar Waddell 28 | 29 | * the Zlib compression library, developed by Jean-loup Gailly and 30 | Mark Adler 31 | -------------------------------------------------------------------------------- /c/Mf-a6nt: -------------------------------------------------------------------------------- 1 | # Mf-a6nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6nt 17 | Cpu = X86_64 18 | 19 | clib= 20 | o = obj 21 | mdobj=windows.$o 22 | mdsrc=windows.c Makefile.$m cs.ico scheme.rc make.bat 23 | mdclean=make.bat scheme.res ../bin/$m/*.exp mtscheme.exe* mdscheme.exe* 24 | 25 | include Mf-base 26 | 27 | # currently creating datestamp at 'make source' time 28 | datestamp.c: 29 | 30 | make.bat: 31 | echo "@nmake /nologo -f Makefile.$m %*" > make.bat 32 | -------------------------------------------------------------------------------- /c/Mf-ta6nt: -------------------------------------------------------------------------------- 1 | # Mf-ta6nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6nt 17 | Cpu = X86_64 18 | 19 | clib= 20 | o = obj 21 | mdobj=windows.$o 22 | mdsrc=windows.c Makefile.$m cs.ico scheme.rc make.bat 23 | mdclean=make.bat scheme.res ../bin/$m/*.exp mtscheme.exe* mdscheme.exe* 24 | 25 | include Mf-base 26 | 27 | # currently creating datestamp at 'make source' time 28 | datestamp.c: 29 | 30 | make.bat: 31 | echo "@nmake /nologo -f Makefile.$m %*" > make.bat 32 | -------------------------------------------------------------------------------- /c/Mf-ti3nt: -------------------------------------------------------------------------------- 1 | # Mf-ti3nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3nt 17 | Cpu = I386 18 | 19 | clib= 20 | o = obj 21 | mdobj=windows.$o 22 | mdsrc=windows.c Makefile.$m cs.ico scheme.rc make.bat 23 | mdclean=make.bat scheme.res ../bin/$m/*.exp mtscheme.exe* mdscheme.exe* 24 | 25 | include Mf-base 26 | 27 | # currently creating datestamp at 'make source' time 28 | datestamp.c: 29 | 30 | make.bat: 31 | echo "@nmake /nologo -f Makefile.$m %*" > make.bat 32 | -------------------------------------------------------------------------------- /mats/5_8.ms: -------------------------------------------------------------------------------- 1 | ;;; 5-7.ms 2 | ;;; Copyright 1984-2016 Cisco Systems, Inc. 3 | ;;; 4 | ;;; Licensed under the Apache License, Version 2.0 (the "License"); 5 | ;;; you may not use this file except in compliance with the License. 6 | ;;; You may obtain a copy of the License at 7 | ;;; 8 | ;;; http://www.apache.org/licenses/LICENSE-2.0 9 | ;;; 10 | ;;; Unless required by applicable law or agreed to in writing, software 11 | ;;; distributed under the License is distributed on an "AS IS" BASIS, 12 | ;;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | ;;; See the License for the specific language governing permissions and 14 | ;;; limitations under the License. 15 | 16 | (mat box 17 | (box? (box 3)) 18 | (equal? (box 'a) '#&a) 19 | (equal? (box '(a b c)) '#&(a b c)) 20 | (not (eq? (box '()) (box '()))) 21 | ) 22 | 23 | (mat unbox 24 | (equal? (unbox '#&3) 3) 25 | (equal? (unbox (box 3)) 3) 26 | ) 27 | 28 | (mat set-box! 29 | (let ((x (box 3))) 30 | (set-box! x 4) 31 | (and (equal? x '#&4) (equal? (unbox x) 4))) 32 | ) 33 | -------------------------------------------------------------------------------- /mats/cat_flush.c: -------------------------------------------------------------------------------- 1 | /* cat_flush.c 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #include 18 | #include 19 | #ifdef WIN32 20 | #include 21 | #include 22 | #endif 23 | 24 | int main() { 25 | int c; 26 | 27 | #ifdef WIN32 28 | _setmode(_fileno(stdin), O_BINARY); 29 | _setmode(_fileno(stdout), O_BINARY); 30 | #endif 31 | 32 | while ((c = getchar()) != EOF) { 33 | putchar(c); 34 | fflush(stdout); 35 | } 36 | 37 | exit(0); 38 | } 39 | -------------------------------------------------------------------------------- /c/system.h: -------------------------------------------------------------------------------- 1 | /* system.h 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #include "scheme.h" 18 | #include "equates.h" 19 | #ifdef FEATURE_WINDOWS 20 | #include 21 | #endif 22 | 23 | #include "version.h" 24 | #include 25 | #include "zlib.h" 26 | #include 27 | 28 | #include "thread.h" 29 | 30 | #include "types.h" 31 | 32 | #ifndef EXTERN 33 | #define EXTERN extern 34 | #endif 35 | #include "globals.h" 36 | 37 | #include "externs.h" 38 | 39 | #include "segment.h" 40 | 41 | -------------------------------------------------------------------------------- /csug/title.stex: -------------------------------------------------------------------------------- 1 | % Copyright 2005-2016 Cisco Systems, Inc. 2 | % 3 | % Licensed under the Apache License, Version 2.0 (the "License"); 4 | % you may not use this file except in compliance with the License. 5 | % You may obtain a copy of the License at 6 | % 7 | % http://www.apache.org/licenses/LICENSE-2.0 8 | % 9 | % Unless required by applicable law or agreed to in writing, software 10 | % distributed under the License is distributed on an "AS IS" BASIS, 11 | % WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | % See the License for the specific language governing permissions and 13 | % limitations under the License. 14 | \iflatex 15 | \thispagestyle{empty} 16 | 17 | \leftline{} 18 | \vskip 6pc 19 | 20 | {\titlefont\hbox to \textwidth{Chez Scheme Version 9\hfil}} 21 | \vskip 10pt 22 | {\titlefont\hbox to \textwidth{User's Guide\hfil}} 23 | 24 | % \vskip 9pc 25 | 26 | \vfill\vfill 27 | 28 | \begingroup\large 29 | \begin{flushright} 30 | \includegraphics[width=1.25in]{canned/cisco-logo-large}\\[10pt] 31 | Cisco Systems, Inc.\\ 32 | www.cisco.com 33 | \end{flushright} 34 | \endgroup 35 | 36 | \pagebreak 37 | \fi 38 | -------------------------------------------------------------------------------- /makefiles/Mf-boot.in: -------------------------------------------------------------------------------- 1 | # Mf-boot.in 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | bootfiles=$(addsuffix .boot, $(shell cd ../boot ; echo *)) 17 | 18 | doit: $(bootfiles) 19 | 20 | %.boot: 21 | ( cd .. ; ./workarea $* xc-$* ) 22 | ( cd ../xc-$*/s ; make -f Mf-cross base=../../$(workarea) --jobs=2 m=$(m) xm=$* ) 23 | for x in `echo scheme.boot petite.boot scheme.h equates.h` ; do\ 24 | if [ ! -h ../xc-$*/boot/$*/$$x ] ; then \ 25 | mv -f ../xc-$*/boot/$*/$$x ../boot/$*/$$x ;\ 26 | fi ;\ 27 | done 28 | rm -rf ../xc-$* 29 | -------------------------------------------------------------------------------- /mats/ftype.h: -------------------------------------------------------------------------------- 1 | /* ftype.h 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #ifdef SPARC 18 | 19 | typedef signed char int8_t; 20 | typedef unsigned char uint8_t; 21 | typedef signed short int16_t; 22 | typedef unsigned short uint16_t; 23 | typedef signed int int32_t; 24 | typedef unsigned int uint32_t; 25 | typedef signed long long int64_t; 26 | typedef unsigned long long uint64_t; 27 | 28 | #else 29 | 30 | #include 31 | 32 | #endif 33 | 34 | #ifdef WIN32 35 | #define EXPORT extern __declspec (dllexport) 36 | #else 37 | #define EXPORT extern 38 | #endif 39 | -------------------------------------------------------------------------------- /examples/Makefile: -------------------------------------------------------------------------------- 1 | # Unix make file to compile the examples. 2 | # Compilation is not necessary since the examples may be loaded from 3 | # source, but this gives an example of how to use make for Scheme. 4 | # * To compile files not already compiled, type "make". Only those 5 | # files in the object list below and not yet compiled will be compiled. 6 | # * To compile all files, type "make all". Only those files in the object 7 | # list below will be compiled. 8 | # * To compile one file, say "fumble.ss", type "make fumble.so". The 9 | # file need not be in the object list below. 10 | # * To remove the object files, type "make clean". 11 | # * To print the examples, type "make print". 12 | 13 | src = def.ss edit.ss fact.ss fatfib.ss fft.ss fib.ss freq.ss interpret.ss\ 14 | m4.ss macro.ss matrix.ss object.ss power.ss queue.ss rabbit.ss rsa.ss\ 15 | scons.ss setof.ss socket.ss unify.ss compat.ss 16 | obj = ${src:%.ss=%.so} 17 | 18 | Scheme = scheme -q 19 | 20 | .SUFFIXES: 21 | .SUFFIXES: .ss .so 22 | .ss.so: ; echo '(time (compile-file "$*"))' | ${Scheme} 23 | 24 | needed: ${obj} 25 | 26 | all: ; echo "(time (for-each compile-file (map symbol->string '(${src}))))" | ${Scheme} 27 | 28 | clean: ; /bin/rm -f $(obj) 29 | -------------------------------------------------------------------------------- /makefiles/Makefile-workarea.in: -------------------------------------------------------------------------------- 1 | # Makefile-workarea.in 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | MAKEFLAGS += --no-print-directory 17 | PREFIX= 18 | 19 | build: 20 | (cd c ; $(MAKE)) 21 | (cd s ; $(MAKE) bootstrap) 22 | 23 | install: build 24 | $(MAKE) -f Mf-install 25 | 26 | test: build 27 | (cd mats ; $(MAKE) allx) 28 | @echo "test run complete. check $(PREFIX)mats/summary for errors." 29 | 30 | bootfiles: build 31 | $(MAKE) -f Mf-boot 32 | 33 | clean: 34 | rm -f petite.1 scheme.1 35 | (cd s ; $(MAKE) clean) 36 | (cd c ; $(MAKE) clean) 37 | (cd mats ; $(MAKE) clean) 38 | (cd examples ; $(MAKE) clean) 39 | rm -f Make.out 40 | -------------------------------------------------------------------------------- /csug/scheme.hsty: -------------------------------------------------------------------------------- 1 | \def\transerr#1{\raw{}} 2 | \def\transin#1{\raw{}} 3 | \def\transout#1{\raw{}} 4 | \def\endtranserr#1{\raw{}} 5 | \def\endtransin#1{\raw{}} 6 | \def\endtransout#1{\raw{}} 7 | 8 | \def\schemeblankline{{\\\\}} 9 | \def\schemelinestart{} 10 | %%% handle numbered lines in scheme.sty and scheme.hsty 11 | %%% ---have scheme-prep produce only \schemelinestart 12 | % following is probably broken until we have tables, I suspect. 13 | % Actually, the right way to fix this may be to use CSS 14 | \def\schemelinestartnumbered#1{\raw{
}#1\raw{
}} 15 | 16 | \def\scheme#1{{\tt #1}} 17 | \def\longcode\schemedisplay{\schemedisplay} 18 | \def\noskip\schemedisplay{\schemedisplay} 19 | \def\schemedisplay{\par\begingroup\tt\hardspaces} 20 | \def\endschemedisplay{\endgroup\par} 21 | \def\schemeindent{} 22 | \def\schatsign{\raw{@}} 23 | \def\schbackslash{\raw{\}} 24 | \def\schcarat{\raw{^}} 25 | \def\schdot{\raw{.}} 26 | \def\schlbrace{\raw{&##123;}} 27 | \def\schrbrace{\raw{&##125;}} 28 | \def\schtilde{\raw{~}} 29 | \def\schunderscore{\raw{_}} 30 | \def\becomes{$\rightarrow$} 31 | \def\is{$\Rightarrow$} 32 | \def\si{\raw{}} 33 | \def\var#1{\emph{#1}} 34 | -------------------------------------------------------------------------------- /makefiles/Makefile.in: -------------------------------------------------------------------------------- 1 | # Makefile.in 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | MAKEFLAGS += --no-print-directory 17 | 18 | build: 19 | (cd $(workarea) && $(MAKE) build) 20 | 21 | install: 22 | (cd $(workarea) && $(MAKE) install) 23 | 24 | test: 25 | (cd $(workarea) && $(MAKE) test PREFIX=$(workarea)/) 26 | 27 | bootfiles: 28 | (cd $(workarea) && $(MAKE) bootfiles) 29 | 30 | docs: build 31 | (cd csug && $(MAKE) m=$(m)) 32 | (cd release_notes && $(MAKE) m=$(m)) 33 | 34 | clean: 35 | (cd $(workarea) && $(MAKE) clean) 36 | 37 | distclean: 38 | (cd csug ; make reallyreallyclean) 39 | (cd release_notes ; make reallyreallyclean) 40 | rm -rf $(workarea) 41 | rm -f Makefile 42 | rm -f Make.out 43 | -------------------------------------------------------------------------------- /examples/scons.ss: -------------------------------------------------------------------------------- 1 | ;;; scons.ss 2 | ;;; a stream-construction facility 3 | 4 | ;;; The scons special form performs a cons, suspending the cdr field 5 | ;;; by enclosing it in a procedure of no arguments. scdr tests to see 6 | ;;; if the cdr is a procedure, and if so, invokes it. scar is provided 7 | ;;; for symmetry; it is just car. 8 | 9 | ;;; The function stream-ref is simply list-ref defined in terms of 10 | ;;; scdr and scar. 11 | 12 | ;;; factlist and fiblist are two infinite streams. 13 | ;;; Try (stream-ref factlist 10) or (stream-ref fiblist 20). 14 | 15 | ;;; scons could easily suspend the car field as well. This would 16 | ;;; implement the lazy cons of Friedman & Wise. 17 | 18 | (define-syntax scons 19 | (syntax-rules () 20 | ((_ car cdr) (cons car (lambda () cdr))))) 21 | 22 | (define scar car) 23 | 24 | (define scdr 25 | (lambda (x) 26 | (when (procedure? (cdr x)) (set-cdr! x ((cdr x)))) 27 | (cdr x))) 28 | 29 | (define stream-ref 30 | (lambda (x n) 31 | (if (zero? n) 32 | (scar x) 33 | (stream-ref (scdr x) (1- n))))) 34 | 35 | (define factlist 36 | (let fact ([a 1] [n 1]) 37 | (scons a (fact (* a n) (1+ n))))) 38 | 39 | (define fiblist 40 | (let fib ([fib-2 0] [fib-1 1]) 41 | (scons fib-1 (fib fib-1 (+ fib-2 fib-1))))) 42 | -------------------------------------------------------------------------------- /c/Mf-arm32le: -------------------------------------------------------------------------------- 1 | # Mf-arm32le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = arm32le 17 | Cpu = ARMV6 18 | 19 | mdclib = -lm -ldl -lncurses -lrt 20 | C = gcc ${CPPFLAGS} -Wpointer-arith -Wextra -Werror -O2 ${CFLAGS} 21 | o = o 22 | mdsrc = arm32le.c 23 | mdobj = arm32le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; ./configure) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /c/Mf-ppc32le: -------------------------------------------------------------------------------- 1 | # Mf-ppc32le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ppc32le 17 | Cpu = PPC32 18 | 19 | mdclib = -lm -ldl -lncurses -lrt 20 | C = gcc ${CPPFLAGS} -m32 -Wpointer-arith -Wextra -Werror -O2 ${CFLAGS} 21 | o = o 22 | mdsrc = ppc32.c 23 | mdobj = ppc32.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m32 ./configure) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /csug/csug.css: -------------------------------------------------------------------------------- 1 | BODY {background-color: #FFFFFF} 2 | 3 | a:link, a:active, a:visited { color:#005568; text-decoration:underline } 4 | a:hover { color:white; text-decoration:underline; background:#005568 } 5 | 6 | a.plain:link, a.plain:active, a.plain:visited { color:#005568; text-decoration:none } 7 | a.plain:hover { color:white; text-decoration:none; background:#005568 } 8 | 9 | a.toc:link, a.toc:active, a.toc:visited {font-family: sans-serif; color:#005568; text-decoration:none} 10 | a.toc:hover {font-family: sans-serif; color:white; text-decoration:none; background:#005568} 11 | 12 | a.image:link, a.image:active, a.image:visited, a.image:hover { 13 | color: #005568; 14 | background: #FFFFFF; 15 | } 16 | 17 | ul.tocchapter { list-style: none; } 18 | ul.tocsection { list-style: circle; color: #C41230 } 19 | 20 | hr.copyright { width: 50% } 21 | 22 | input.default { background: #ffffff; color: #000000; vertical-align: middle} 23 | 24 | h1, h2, h3, h4 {font-family: sans-serif; color: #005568} 25 | h1 {font-size: 2em} 26 | h2 {margin-top: 30px; font-size: 1.5em} 27 | h3 {margin-top: 30px; font-size: 1.17em} 28 | h1, h2, h3, h4 {font-weight: bold} 29 | 30 | .title { font-family: sans-serif; font-weight: bold; font-size: 2.5em; color: #005568; white-space: nowrap} 31 | 32 | .formdef { color: #005568 } 33 | 34 | table.indent {margin-left: 20px} 35 | 36 | -------------------------------------------------------------------------------- /c/Mf-i3s2: -------------------------------------------------------------------------------- 1 | # Mf-i3s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3s2 17 | Cpu = I386 18 | 19 | mdclib = -lnsl -ldl -lm -lcurses -lrt 20 | C = gcc ${CFLAGS} -m32 -Wpointer-arith -Wextra -Werror -O ${CPPFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -DSOLARIS -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -melf_i386 -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m32 ./configure) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /c/Mf-a6osx: -------------------------------------------------------------------------------- 1 | # Mf-a6osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6osx 17 | Cpu = X86_64 18 | 19 | mdclib = -liconv -lm -lncurses 20 | C = gcc ${CPPFLAGS} -m64 -Wpointer-arith -Wall -Wextra -Werror -O2 -I/opt/X11/include/ ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -r -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /c/Mf-i3osx: -------------------------------------------------------------------------------- 1 | # Mf-i3osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3osx 17 | Cpu = I386 18 | 19 | mdclib = -liconv -lm -lncurses 20 | C = gcc ${CPPFLAGS} -m32 -Wpointer-arith -Wall -Wextra -Werror -O2 -msse2 -I/opt/X11/include/ ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -r -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m32 ./configure) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /c/Mf-a6s2: -------------------------------------------------------------------------------- 1 | # Mf-a6s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6s2 17 | Cpu = X86_64 18 | 19 | mdclib = -lnsl -ldl -lm -lcurses -lrt 20 | C = gcc ${CPPFLAGS} -m64 -Wpointer-arith -Wextra -Werror -O ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -DSOLARIS -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -melf_x86_64 -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /c/Mf-ta6osx: -------------------------------------------------------------------------------- 1 | # Mf-ta6osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6osx 17 | Cpu = X86_64 18 | 19 | mdclib = -liconv -lm -lncurses 20 | C = gcc ${CPPFLAGS} -m64 -Wpointer-arith -Wall -Wextra -Werror -O2 -I/opt/X11/include/ ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -r -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /c/Mf-ti3osx: -------------------------------------------------------------------------------- 1 | # Mf-ti3osx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3osx 17 | Cpu = I386 18 | 19 | mdclib = -liconv -lm -lncurses 20 | C = gcc ${CPPFLAGS} -m32 -Wpointer-arith -Wall -Wextra -Werror -O2 -msse2 -I/opt/X11/include/ ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -r -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m32 ./configure) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /mats/Mf-a6nt: -------------------------------------------------------------------------------- 1 | # Mf-a6nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6nt 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | ftmp = foreign1.obj foreign2.obj foreign3.obj 20 | fobj = foreign1.so 21 | mdclean = ${ftmp} foreign1.exp foreign1.lib make.bat cat_flush.obj cat_flush.exe libiconv-2.dll 22 | mdsrc = bldnt.bat 23 | 24 | MSDOS = 1 25 | 26 | include Mf-base 27 | 28 | .SUFFIXES: .c .obj 29 | 30 | .c.obj: ; cl -c -DWIN32 -I${Include} $*.c 31 | 32 | foreign1.so: $(ftmp) 33 | link -dll -out:foreign1.so foreign1.obj foreign2.obj foreign3.obj 34 | 35 | make.bat: 36 | echo "@echo off" > make.bat 37 | echo "call blda6nt" >> make.bat 38 | echo "call blda6nt 2" >> make.bat 39 | echo "blda6nt 3" >> make.bat 40 | 41 | libiconv-2.dll: 42 | ln -s ../bin/libiconv-2.dll . 43 | -------------------------------------------------------------------------------- /mats/Mf-i3nt: -------------------------------------------------------------------------------- 1 | # Mf-i3nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3nt 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | ftmp = foreign1.obj foreign2.obj foreign3.obj 20 | fobj = foreign1.so 21 | mdclean = ${ftmp} foreign1.exp foreign1.lib make.bat cat_flush.obj cat_flush.exe libiconv-2.dll 22 | mdsrc = bldnt.bat 23 | 24 | MSDOS = 1 25 | 26 | include Mf-base 27 | 28 | .SUFFIXES: .c .obj 29 | 30 | .c.obj: ; cl -c -DWIN32 -I${Include} $*.c 31 | 32 | foreign1.so: $(ftmp) 33 | link -dll -out:foreign1.so foreign1.obj foreign2.obj foreign3.obj 34 | 35 | make.bat: 36 | echo "@echo off" > make.bat 37 | echo "call bldi3nt" >> make.bat 38 | echo "call bldi3nt 2" >> make.bat 39 | echo "bldi3nt 3" >> make.bat 40 | 41 | libiconv-2.dll: 42 | ln -s ../bin/libiconv-2.dll . 43 | -------------------------------------------------------------------------------- /c/Mf-a6le: -------------------------------------------------------------------------------- 1 | # Mf-a6le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6le 17 | Cpu = X86_64 18 | 19 | mdclib = -lm -ldl -lncurses -lrt 20 | C = gcc ${CPPFLAGS} -m64 -msse2 -Wpointer-arith -Wall -Wextra -Werror -O2 ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -melf_x86_64 -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /mats/Mf-ta6nt: -------------------------------------------------------------------------------- 1 | # Mf-ta6nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6nt 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | ftmp = foreign1.obj foreign2.obj foreign3.obj 20 | fobj = foreign1.so 21 | mdclean = ${ftmp} foreign1.exp foreign1.lib make.bat cat_flush.obj cat_flush.exe libiconv-2.dll 22 | mdsrc = bldnt.bat 23 | 24 | MSDOS = 1 25 | 26 | include Mf-base 27 | 28 | .SUFFIXES: .c .obj 29 | 30 | .c.obj: ; cl -c -DWIN32 -I${Include} $*.c 31 | 32 | foreign1.so: $(ftmp) 33 | link -dll -out:foreign1.so foreign1.obj foreign2.obj foreign3.obj 34 | 35 | make.bat: 36 | echo "@echo off" > make.bat 37 | echo "call bldta6nt" >> make.bat 38 | echo "call bldta6nt 2" >> make.bat 39 | echo "bldta6nt 3" >> make.bat 40 | 41 | libiconv-2.dll: 42 | ln -s ../bin/libiconv-2.dll . 43 | -------------------------------------------------------------------------------- /mats/Mf-ti3nt: -------------------------------------------------------------------------------- 1 | # Mf-ti3nt 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3nt 17 | 18 | fsrc = foreign1.c foreign2.c foreign3.c 19 | ftmp = foreign1.obj foreign2.obj foreign3.obj 20 | fobj = foreign1.so 21 | mdclean = ${ftmp} foreign1.exp foreign1.lib make.bat cat_flush.obj cat_flush.exe libiconv-2.dll 22 | mdsrc = bldnt.bat 23 | 24 | MSDOS = 1 25 | 26 | include Mf-base 27 | 28 | .SUFFIXES: .c .obj 29 | 30 | .c.obj: ; cl -c -DWIN32 -I${Include} $*.c 31 | 32 | foreign1.so: $(ftmp) 33 | link -dll -out:foreign1.so foreign1.obj foreign2.obj foreign3.obj 34 | 35 | make.bat: 36 | echo "@echo off" > make.bat 37 | echo "call bldti3nt" >> make.bat 38 | echo "call bldti3nt 2" >> make.bat 39 | echo "bldti3nt 3" >> make.bat 40 | 41 | libiconv-2.dll: 42 | ln -s ../bin/libiconv-2.dll . 43 | -------------------------------------------------------------------------------- /c/Mf-ti3s2: -------------------------------------------------------------------------------- 1 | # Mf-ti3s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3s2 17 | Cpu = I386 18 | 19 | mdclib = -lnsl -ldl -lm -lpthread -lcurses -lrt 20 | C = gcc ${CPPFLAGS} -m32 -Wpointer-arith -Wextra -Werror -O2 -D_REENTRANT ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -DSOLARIS -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -melf_i386 -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m32 ./configure) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /c/Mf-i3le: -------------------------------------------------------------------------------- 1 | # Mf-i3le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3le 17 | Cpu = I386 18 | 19 | mdclib = -lm -ldl -lncurses -lrt 20 | C = gcc ${CPPFLAGS} -m32 -msse2 -Wpointer-arith -Wall -Wextra -Werror -O2 -fno-stack-protector ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -melf_i386 -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m32 ./configure) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /s/patch.ss: -------------------------------------------------------------------------------- 1 | ;;; patch.ss 2 | ;;; Copyright 1984-2016 Cisco Systems, Inc. 3 | ;;; 4 | ;;; Licensed under the Apache License, Version 2.0 (the "License"); 5 | ;;; you may not use this file except in compliance with the License. 6 | ;;; You may obtain a copy of the License at 7 | ;;; 8 | ;;; http://www.apache.org/licenses/LICENSE-2.0 9 | ;;; 10 | ;;; Unless required by applicable law or agreed to in writing, software 11 | ;;; distributed under the License is distributed on an "AS IS" BASIS, 12 | ;;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | ;;; See the License for the specific language governing permissions and 14 | ;;; limitations under the License. 15 | 16 | (printf "loading ~s cross compiler~%" (constant machine-type-name)) 17 | 18 | ; (current-expand (lambda args (apply sc-expand args))) 19 | ; (current-eval (lambda args (apply interpret args))) 20 | 21 | (when-feature pthreads 22 | (meta-cond 23 | [(not (threaded?)) 24 | ; we must be cross-compiling from nonthreaded to threaded version 25 | ; handle thread parameter creation 26 | (define-syntax with-mutex 27 | (syntax-rules () 28 | [(_ mexp e0 e1 ...) (begin e0 e1 ...)])) 29 | (set! make-thread-parameter make-parameter) 30 | (set! mutex-acquire (lambda (m) (void))) 31 | (set! mutex-release (lambda (m) (void))) 32 | (set! $tc-mutex (void))])) 33 | 34 | -------------------------------------------------------------------------------- /c/Mf-ta6s2: -------------------------------------------------------------------------------- 1 | # Mf-ta6s2 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6s2 17 | Cpu = X86_64 18 | 19 | mdclib = -lnsl -ldl -lm -lpthread -lcurses -lrt 20 | C = gcc ${CPPFLAGS} -m64 -Wpointer-arith -Wextra -Werror -O2 -D_REENTRANT ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -DSOLARIS -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -melf_x86_64 -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /c/Mf-tppc32le: -------------------------------------------------------------------------------- 1 | # Mf-tppc32le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = tppc32le 17 | Cpu = PPC32 18 | 19 | mdclib = -lm -ldl -lncurses -lpthread -lrt 20 | C = gcc ${CPPFLAGS} -m32 -Wpointer-arith -Wextra -Werror -O2 -D_REENTRANT -pthread ${CFLAGS} 21 | o = o 22 | mdsrc = ppc32le.c 23 | mdobj = ppc32le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m32 ./configure) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /s/Mf-cross: -------------------------------------------------------------------------------- 1 | # Mf-cross 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | # Usage: make -f Mf-cross m=host xm=target, e.g.: 17 | # make -f Mf-cross m=i3le xm=i3osx 18 | # to cross-compile to i3osx from i3le 19 | 20 | what = all examples 21 | base = ../.. 22 | 23 | doitformebaby: xboot 24 | 25 | include Mf-${xm} 26 | 27 | Scheme=$(base)/bin/${m}/scheme 28 | export SCHEMEHEAPDIRS=$(base)/boot/${m} 29 | o = 2 30 | i = t 31 | d = 3 32 | 33 | xpatch = xpatch 34 | xpatchobj = ${patchobj} 35 | 36 | xboot: ${xpatch} 37 | $(MAKE) -f Mf-${xm} ${what} m=${xm} patchfile=${xpatch} Scheme="${Scheme}" SCHEMEHEAPDIRS=${SCHEMEHEAPDIRS} 38 | 39 | ${xpatch}: ${xpatchobj} 40 | cat ${xpatchobj} > ${xpatch} 41 | 42 | x$(xm).$(m): 43 | $(MAKE) -f Mf-cross m=$(m) xm=$(xm) i=f o=3 d=0 xpatch 44 | mv xpatch x$(xm).$(m) 45 | -------------------------------------------------------------------------------- /csug/canned/about.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | About CSUG9 4 | 5 | 6 | 7 | 8 |

9 | The printed version of this book was created with LaTeX from extended 10 | LaTeX sources with the help of a preprocessor written in Scheme. 11 | The preprocessor handles extensions for incorporating arbitrary 12 | verbatim Scheme code and various other features not directly supported 13 | by LaTeX. 14 |

15 | 16 |

17 | The HTML version was created from the preprocessed sources for the 18 | printed version by a separate Scheme program that performs a LaTeX to 19 | HTML conversion. 20 | In addition to the extended LaTeX source files, this program takes as 21 | input the .aux and .bbl files produced by a complete LaTeX/BibTeX run 22 | of the document in order to support labels and page references in the 23 | text, summary of forms, and index. 24 | As it runs, the program produces a .haux file containing urls for the 25 | labels, bibliographic entries, and index entries; as with LaTeX, a 26 | second run of the program is needed to achieve proper 27 | cross-referencing. 28 |

29 | 30 |

31 | Most of the images and certain mathematical formulas included in the 32 | HTML version were produced with the help of LaTeX, dvips, ghostscript, 33 | and various programs from the netpbm library. 34 |

35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /c/Mf-ti3le: -------------------------------------------------------------------------------- 1 | # Mf-ti3le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3le 17 | Cpu = I386 18 | 19 | mdclib = -lm -ldl -lncurses -lpthread -lrt 20 | C = gcc ${CPPFLAGS} -m32 -msse2 -Wpointer-arith -Wall -Wextra -Werror -O2 -D_REENTRANT -pthread ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -melf_i386 -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m32 ./configure) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /c/Mf-ta6le: -------------------------------------------------------------------------------- 1 | # Mf-ta6le 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6le 17 | Cpu = X86_64 18 | 19 | mdclib = -lm -ldl -lncurses -lpthread -lrt 20 | C = gcc ${CPPFLAGS} -m64 -msse2 -Wpointer-arith -Wall -Wextra -Werror -O2 -D_REENTRANT -pthread ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | 25 | .SUFFIXES: 26 | .SUFFIXES: .c .o 27 | 28 | .c.o: 29 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} $*.c 30 | 31 | include Mf-base 32 | 33 | ${Kernel}: ${kernelobj} ../zlib/libz.a 34 | ld -melf_x86_64 -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 35 | 36 | ${Scheme}: ${Kernel} ${Main} 37 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 38 | 39 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 40 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 41 | (cd ../zlib; make) 42 | -------------------------------------------------------------------------------- /csug/docond.ss: -------------------------------------------------------------------------------- 1 | (define docond-ht (make-eq-hashtable)) 2 | (hashtable-set! docond-ht '&condition '()) 3 | (define (docond expr) 4 | (syntax-case expr (define-condition-type) 5 | [(define-condition-type &name &parent make-name name? 6 | (field-name field-accessor) ...) 7 | (let ([pfields (hashtable-ref docond-ht #'&parent #f)]) 8 | (unless pfields (error 'docond "unrecognized parent ~s" #'&parent)) 9 | (printf "\\formdef{~s}{\\categorysyntax}{~s}\n" #'&name #'&name) 10 | (let ([fields (append pfields #'(field-name ...))]) 11 | (printf "\\formdef{~s}{\\categoryprocedure}{(~s~{ \\var{~s}~})}\n" 12 | #'make-name #'make-name fields) 13 | (hashtable-set! docond-ht #'&name fields)) 14 | (printf "\\returns a condition of type \\scheme{~s}\n" #'&name) 15 | (printf "\\formdef{~s}{\\categoryprocedure}{(~s \\var{obj})}\n" #'name? #'name?) 16 | (printf "\\returns \\scheme{#t} if \\var{obj} is a condition of type \\scheme{~s}, \\scheme{#f} otherwise\n" 17 | #'&name) 18 | (for-each 19 | (lambda (field get-field) 20 | (printf "\\formdef{~s}{\\categoryprocedure}{(~s \\var{condition})}\n" get-field get-field) 21 | (printf "\\returns the contents of \\var{condition}'s \\scheme{~s} field\n" field)) 22 | #'(field-name ...) 23 | #'(field-accessor ...)) 24 | (printf "\\listlibraries\n"))])) 25 | -------------------------------------------------------------------------------- /c/Mf-i3fb: -------------------------------------------------------------------------------- 1 | # Mf-i3fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3fb 17 | Cpu = I386 18 | 19 | mdinclude = -I/usr/local/include -I/usr/X11R6/include 20 | mdclib = -L/usr/local/lib -liconv -lm -lncurses 21 | C = gcc ${CPPFLAGS} -Wpointer-arith -Wextra -Werror -O ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m32 ./configure) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /c/Mf-a6fb: -------------------------------------------------------------------------------- 1 | # Mf-a6fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6fb 17 | Cpu = X86_64 18 | 19 | mdinclude = -I/usr/local/include -I/usr/X11R6/include 20 | mdclib = -L/usr/local/lib -liconv -lm -lncurses 21 | C = gcc ${CPPFLAGS} -Wpointer-arith -Wextra -Werror -O ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /c/Mf-i3ob: -------------------------------------------------------------------------------- 1 | # Mf-i3ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3ob 17 | Cpu = I386 18 | 19 | mdinclude = -I/usr/local/include -I/usr/X11R6/include 20 | mdclib = -L/usr/local/lib -liconv -lm -lncurses 21 | C = gcc ${CPPFLAGS} -Wpointer-arith -Werror -O ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -Wl,--export-dynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m32 ./configure) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /c/Mf-a6ob: -------------------------------------------------------------------------------- 1 | # Mf-a6ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6ob 17 | Cpu = X86_64 18 | 19 | mdinclude = -I/usr/local/include -I/usr/X11R6/include 20 | mdclib = -L/usr/local/lib -liconv -lm -lncurses 21 | C = gcc ${CPPFLAGS} -Wpointer-arith -Werror -O ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -Wl,--export-dynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /c/Mf-i3qnx: -------------------------------------------------------------------------------- 1 | # Mf-i3qnx 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3qnx 17 | Cpu = I386 18 | 19 | mdclib = -lm /usr/local/lib/libiconv.so -lsocket -lncurses 20 | C = qcc ${CPPFLAGS} -m32 -Wpointer-arith -Wextra -Werror -O2 -N2048K ${CFLAGS} 21 | o = o 22 | mdsrc = i3le.c 23 | mdobj = i3le.o 24 | LocalInclude = /usr/local/include 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} -I${LocalInclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -mi386nto -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -Wl,--export-dynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m32 ./configure) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /c/Mf-ti3fb: -------------------------------------------------------------------------------- 1 | # Mf-ti3fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3fb 17 | Cpu = I386 18 | 19 | mdinclude = -I/usr/local/include -I/usr/X11R6/include 20 | mdclib = -L/usr/local/lib -liconv -lm -lncurses -lpthread 21 | C = gcc ${CPPFLAGS} -Wpointer-arith -Wextra -Werror -O2 -D_REENTRANT -pthread ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m32 ./configure) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /c/sort.h: -------------------------------------------------------------------------------- 1 | /* sort.h 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #define mkmergesort(sort, merge, type, nil, lt, cdr)\ 18 | type sort(type ls, uptr len) {\ 19 | if (len == 1) {\ 20 | cdr(ls) = nil;\ 21 | return ls;\ 22 | } else {\ 23 | uptr head_len, i; type tail;\ 24 | head_len = len >> 1;\ 25 | for (tail = ls, i = head_len; i != 0; i -= 1) tail = cdr(tail);\ 26 | return merge(sort(ls, head_len), sort(tail, len - head_len));\ 27 | }\ 28 | }\ 29 | type merge(type ls1, type ls2) {\ 30 | type p; type *pp = &p;\ 31 | for (;;) {\ 32 | if (ls1 == nil) { *pp = ls2; break; }\ 33 | if (ls2 == nil) { *pp = ls1; break; }\ 34 | if (lt(ls2, ls1))\ 35 | { *pp = ls2; pp = &cdr(ls2); ls2 = cdr(ls2); }\ 36 | else\ 37 | { *pp = ls1; pp = &cdr(ls1); ls1 = cdr(ls1); }\ 38 | }\ 39 | return p;\ 40 | } 41 | -------------------------------------------------------------------------------- /c/Mf-ta6fb: -------------------------------------------------------------------------------- 1 | # Mf-ta6fb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6fb 17 | Cpu = X86_64 18 | 19 | mdinclude = -I/usr/local/include -I/usr/X11R6/include 20 | mdclib = -L/usr/local/lib -liconv -lm -lncurses -lpthread 21 | C = gcc ${CPPFLAGS} -Wpointer-arith -Wextra -Werror -O2 -D_REENTRANT -pthread ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /c/Mf-ti3ob: -------------------------------------------------------------------------------- 1 | # Mf-ti3ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3ob 17 | Cpu = I386 18 | 19 | mdinclude = -I/usr/local/include -I/usr/X11R6/include 20 | mdclib = -L/usr/local/lib -liconv -lm -lncurses -lpthread 21 | C = gcc ${CPPFLAGS} -Wpointer-arith -Werror -O2 -D_REENTRANT -pthread ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -Wl,--export-dynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m32 ./configure) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /c/Mf-ta6ob: -------------------------------------------------------------------------------- 1 | # Mf-ta6ob 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6ob 17 | Cpu = X86_64 18 | 19 | mdinclude = -I/usr/local/include -I/usr/X11R6/include 20 | mdclib = -L/usr/local/lib -liconv -lm -lncurses -lpthread 21 | C = gcc ${CPPFLAGS} -Wpointer-arith -Werror -O2 -D_REENTRANT -pthread ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -Wl,--export-dynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /s/ubify.ss: -------------------------------------------------------------------------------- 1 | ;;; ubify.ss 2 | ;;; Copyright 1984-2016 Cisco Systems, Inc. 3 | ;;; 4 | ;;; Licensed under the Apache License, Version 2.0 (the "License"); 5 | ;;; you may not use this file except in compliance with the License. 6 | ;;; You may obtain a copy of the License at 7 | ;;; 8 | ;;; http://www.apache.org/licenses/LICENSE-2.0 9 | ;;; 10 | ;;; Unless required by applicable law or agreed to in writing, software 11 | ;;; distributed under the License is distributed on an "AS IS" BASIS, 12 | ;;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | ;;; See the License for the specific language governing permissions and 14 | ;;; limitations under the License. 15 | 16 | (for-each 17 | (let () 18 | (define-record-type ub 19 | (fields (immutable x)) 20 | (nongenerative) 21 | (sealed #t)) 22 | (record-writer (type-descriptor ub) 23 | (lambda (x p wr) 24 | (display "#" p))) 27 | (lambda (x) 28 | (unless ($top-level-bound? x) 29 | ($set-top-level-value! x (make-ub x))))) 30 | (oblist)) 31 | 32 | (set-who! compile (lambda args ($oops who "disabled when cross compiling"))) 33 | (set-who! $compile-backend 34 | (lambda (x) 35 | (lambda () 36 | (lambda (fp-entry) 37 | (lambda fp-args 38 | (pretty-print ($uncprep x)) 39 | ($oops who "attempt to call foreign-procedure created while cross compiling")))))) 40 | -------------------------------------------------------------------------------- /c/Mf-i3nb: -------------------------------------------------------------------------------- 1 | # Mf-i3nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = i3nb 17 | Cpu = I386 18 | 19 | mdinclude = -I/usr/X11R7/include -I/usr/pkg/include -I/usr/pkg/include/ncurses -I/usr/X11R6/include 20 | mdclib = /usr/lib/i18n/libiconv_std.a -lm /usr/pkg/lib/libncurses.a 21 | C = gcc ${CPPFLAGS} -Wpointer-arith -Wextra -Werror -O ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m32 ./configure) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /csug/copyright.stex: -------------------------------------------------------------------------------- 1 | % Copyright 2005-2016 Cisco Systems, Inc. 2 | % 3 | % Licensed under the Apache License, Version 2.0 (the "License"); 4 | % you may not use this file except in compliance with the License. 5 | % You may obtain a copy of the License at 6 | % 7 | % http://www.apache.org/licenses/LICENSE-2.0 8 | % 9 | % Unless required by applicable law or agreed to in writing, software 10 | % distributed under the License is distributed on an "AS IS" BASIS, 11 | % WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | % See the License for the specific language governing permissions and 13 | % limitations under the License. 14 | \iflatex 15 | \thispagestyle{empty} 16 | 17 | \centerline{}\vfill 18 | 19 | \textbf{\copyright~2005--2016 Cisco Systems, Inc.} 20 | 21 | Licensed under the Apache License Version 2.0\\ 22 | http://www.apache.org/licenses/LICENSE-2.0 23 | 24 | % NB: also update corresponding notice in csug.stex 25 | Revised \INSERTREVISIONMONTHSPACEYEAR for Chez Scheme Version 9.4.1. 26 | 27 | \medskip\noindent 28 | Cisco and the Cisco logo are trademarks or registered trademarks 29 | of Cisco and/or its affiliates in the U.S. and other countries. To 30 | view a list of Cisco trademarks, go to this URL: 31 | http://www.cisco.com/go/trademarks. Third-party trademarks mentioned 32 | are the property of their respective owners. The use of the word 33 | partner does not imply a partnership relationship between Cisco and 34 | any other company. (1110R) 35 | 36 | \vspace{1in}\break 37 | \fi 38 | -------------------------------------------------------------------------------- /c/Mf-a6nb: -------------------------------------------------------------------------------- 1 | # Mf-a6nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = a6nb 17 | Cpu = X86_64 18 | 19 | mdinclude = -I/usr/X11R7/include -I/usr/pkg/include -I/usr/pkg/include/ncurses -I/usr/local/include -I/usr/X11R6/include 20 | mdclib = /usr/lib/i18n/libiconv_std.a -lm /usr/pkg/lib/libncurses.a 21 | C = gcc ${CPPFLAGS} -m64 -Wpointer-arith -Wextra -Werror -O ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /c/Mf-ta6nb: -------------------------------------------------------------------------------- 1 | # Mf-ta6nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ta6nb 17 | Cpu = X86_64 18 | 19 | mdinclude = -I/usr/X11R7/include -I/usr/pkg/include -I/usr/pkg/include/ncurses -I/usr/X11R6/include 20 | mdclib = /usr/lib/i18n/libiconv_std.a -lm /usr/pkg/lib/libncurses.a -lpthread 21 | C = gcc ${CPPFLAGS} -m64 -Wpointer-arith -Wextra -Werror -O2 -D_REENTRANT -pthread ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m64 ./configure --64) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /c/Mf-ti3nb: -------------------------------------------------------------------------------- 1 | # Mf-ti3nb 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | m = ti3nb 17 | Cpu = I386 18 | 19 | mdinclude = -I/usr/X11R7/include -I/usr/pkg/include -I/usr/pkg/include/ncurses -I/usr/X11R6/include 20 | mdclib = /usr/lib/i18n/libiconv_std.a -lm /usr/pkg/lib/libncurses.a -lpthread 21 | C = gcc ${CPPFLAGS} -m32 -Wpointer-arith -Wextra -Werror -O2 -D_REENTRANT -pthread ${CFLAGS} 22 | o = o 23 | mdsrc = i3le.c 24 | mdobj = i3le.o 25 | 26 | .SUFFIXES: 27 | .SUFFIXES: .c .o 28 | 29 | .c.o: 30 | $C -c -D${Cpu} -I${Include} -I${ZlibInclude} ${mdinclude} $*.c 31 | 32 | include Mf-base 33 | 34 | ${Kernel}: ${kernelobj} ../zlib/libz.a 35 | ld -m elf_i386 -r -X -o ${Kernel} ${kernelobj} ../zlib/libz.a 36 | 37 | ${Scheme}: ${Kernel} ${Main} 38 | $C -rdynamic -o ${Scheme} ${Kernel} ${Main} ${mdclib} ${LDFLAGS} 39 | 40 | ${ZlibInclude}/zlib.h ${ZlibInclude}/zconf.h ../zlib/libz.a: 41 | (cd ../zlib; CFLAGS=-m32 ./configure) 42 | (cd ../zlib; make) 43 | -------------------------------------------------------------------------------- /csug/summary.stex: -------------------------------------------------------------------------------- 1 | % Copyright 2005-2016 Cisco Systems, Inc. 2 | % 3 | % Licensed under the Apache License, Version 2.0 (the "License"); 4 | % you may not use this file except in compliance with the License. 5 | % You may obtain a copy of the License at 6 | % 7 | % http://www.apache.org/licenses/LICENSE-2.0 8 | % 9 | % Unless required by applicable law or agreed to in writing, software 10 | % distributed under the License is distributed on an "AS IS" BASIS, 11 | % WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | % See the License for the specific language governing permissions and 13 | % limitations under the License. 14 | \chapter{Summary of Forms\label{CHPTFORMSUMMARY}} 15 | 16 | 17 | The table that follows summarizes the syntactic forms and procedures 18 | described in this book along with standard Scheme syntactic forms and 19 | procedures. 20 | It shows each item's category and the page number where it is defined. 21 | Page numbers prefixed by ``t'' refer to 22 | \index{The Scheme Programming Language, 4th Edition@\emph{The Scheme Programming Language, 4th Edition}}\emph{The 23 | Scheme Programming Language, 4th Edition} (TSPL4). 24 | 25 | \ifhtml 26 | All page numbers appearing here refer to the printed version of these 27 | books and also serve as hypertext links to the corresponding locations 28 | in the electronic versions of these books. 29 | \fi 30 | 31 | % abbreviate to fit 32 | \def\categorythreadparameter{thread param} 33 | \def\categoryglobalparameter{global param} 34 | 35 | \begingroup 36 | \input{csug.sfm} 37 | \endgroup 38 | 39 | -------------------------------------------------------------------------------- /csug/tspl4/bibliography.aux: -------------------------------------------------------------------------------- 1 | \relax 2 | \bibstyle{tspl} 3 | \bibdata{tspl} 4 | \bibcite{adams:equal}{1} 5 | \bibcite{ashley:mvalues}{2} 6 | \bibcite{bawden:pepm99}{3} 7 | \bibcite{Briggs:dft}{4} 8 | \bibcite{Burger:floatprinting}{5} 9 | \bibcite{Clocksin:prolog}{6} 10 | \bibcite{Daniel:prolog-fft}{7} 11 | \bibcite{UnicodeUAX29}{8} 12 | \bibcite{Dybvig:csug8}{9} 13 | \bibcite{Dybvig:engines}{10} 14 | \bibcite{Dybvig:lambdastar}{11} 15 | \bibcite{Dybvig:syntactic}{12} 16 | \bibcite{Friedman:lisper}{13} 17 | \@writefile{toc}{\contentsline {chapter}{References}{431}} 18 | \@writefile{lof}{\addvspace {10\p@ }} 19 | \@writefile{lot}{\addvspace {10\p@ }} 20 | \bibcite{Friedman:devils}{14} 21 | \bibcite{Haynes:abstracting}{15} 22 | \bibcite{Haynes:obtaining}{16} 23 | \bibcite{Hieb:representing}{17} 24 | \bibcite{IEEE:1178}{18} 25 | \bibcite{Kernighan:C}{19} 26 | \bibcite{RFC4122}{20} 27 | \bibcite{Naur:algol}{21} 28 | \bibcite{Plaisted:sets}{22} 29 | \bibcite{Robinson:unification}{23} 30 | \bibcite{r6rs}{24} 31 | \bibcite{r6rsapps}{25} 32 | \bibcite{r6rslibs}{26} 33 | \bibcite{Steele:common}{27} 34 | \bibcite{Steele:scheme}{28} 35 | \bibcite{Sussman-Steele:HOSC98}{29} 36 | \bibcite{Unicode}{30} 37 | \bibcite{waddell:fixing-letrec}{31} 38 | \bibcite{Wand:HOSC99}{32} 39 | \@setckpt{bibliography}{ 40 | \setcounter{page}{434} 41 | \setcounter{equation}{0} 42 | \setcounter{enumi}{3} 43 | \setcounter{enumii}{0} 44 | \setcounter{enumiii}{0} 45 | \setcounter{enumiv}{32} 46 | \setcounter{footnote}{0} 47 | \setcounter{mpfootnote}{0} 48 | \setcounter{chapter}{12} 49 | \setcounter{section}{11} 50 | \setcounter{exercise}{7} 51 | \setcounter{alphacount}{3} 52 | } 53 | -------------------------------------------------------------------------------- /release_notes/Makefile: -------------------------------------------------------------------------------- 1 | m = a6le 2 | Scheme=../$m/bin/$m/scheme -b ../$m/boot/$m/petite.boot -b ../$m/boot/$m/scheme.boot 3 | STEXLIB=../stex 4 | 5 | # define default document pathname here 6 | # override on command line with 'make x=newdoc' 7 | x = release_notes 8 | 9 | distdir=../release/dist$(x) 10 | commondir=$(distdir)/common 11 | 12 | # define latex processor: latex or pdflatex 13 | latex = pdflatex 14 | 15 | # define stex macro files here 16 | stexmacrofiles = 17 | 18 | # list bibliography files here 19 | bib = 20 | 21 | # define index if an index is to be generated 22 | # index=yes 23 | 24 | include $(STEXLIB)/Mf-stex 25 | 26 | # define or override suffixes here 27 | 28 | # define any additional targets here 29 | 30 | install: $x.pdf $x.html 31 | installsh -m 2755 -d $(distdir) 32 | installsh -m 2755 -d $(commondir) 33 | installsh -m 0644 --ifdiff $x.html $x.pdf $(commondir) 34 | installsh -m 0644 --ifdiff releasenotes.css $(commondir) 35 | (X=`echo canned/*` ;\ 36 | if [ "$$X" != "canned/*" ] ; then\ 37 | installsh -m 2755 -d $(commondir)/canned ;\ 38 | installsh -m 0644 --ifdiff canned/* $(commondir)/canned ;\ 39 | fi) 40 | installsh -m 2755 -d $(commondir)/gifs 41 | installsh -m 0644 --ifdiff gifs/*.gif $(commondir)/gifs 42 | installsh -m 2755 -d $(commondir)/math 43 | -/bin/rm -rf $(commondir)/$(mathdir) 44 | installsh -m 2755 -d $(commondir)/$(mathdir) 45 | if [ -e $(mathdir)/0.gif ] ; then installsh -m 0644 $(mathdir)/*.gif $(commondir)/$(mathdir) ; fi 46 | 47 | # define any dependencies here 48 | 49 | $(x).firstrun: macros.tex 50 | 51 | # define cleanup targets here: 52 | 53 | $(x).clean: 54 | 55 | $(x).reallyclean: 56 | 57 | $(x).reallyreallyclean: 58 | -------------------------------------------------------------------------------- /s/hashtable-types.ss: -------------------------------------------------------------------------------- 1 | ;;; hashtable-types.ss 2 | ;;; Copyright 1984-2016 Cisco Systems, Inc. 3 | ;;; 4 | ;;; Licensed under the Apache License, Version 2.0 (the "License"); 5 | ;;; you may not use this file except in compliance with the License. 6 | ;;; You may obtain a copy of the License at 7 | ;;; 8 | ;;; http://www.apache.org/licenses/LICENSE-2.0 9 | ;;; 10 | ;;; Unless required by applicable law or agreed to in writing, software 11 | ;;; distributed under the License is distributed on an "AS IS" BASIS, 12 | ;;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | ;;; See the License for the specific language governing permissions and 14 | ;;; limitations under the License. 15 | 16 | (define-record-type (hashtable make-xht xht?) 17 | (fields (immutable type xht-type) (immutable mutable? xht-mutable?)) 18 | (nongenerative #{hashtable bu811z2onf9o6tfc-0})) 19 | 20 | (define-record-type ht 21 | (parent hashtable) 22 | (fields (mutable vec) (mutable minlen) (mutable size)) 23 | (nongenerative #{ht bu811z2onf9o6tfc-6})) 24 | 25 | (define-record-type eq-ht 26 | (parent ht) 27 | (fields (immutable weak?)) 28 | (nongenerative #{eq-ht bu811z2onf9o6tfc-5}) 29 | (sealed #t)) 30 | 31 | (define-record-type symbol-ht 32 | (parent ht) 33 | (fields (immutable equiv?)) 34 | (nongenerative #{symbol-ht bu811z2onf9o6tfc-8}) 35 | (sealed #t)) 36 | 37 | (define-record-type gen-ht 38 | (parent ht) 39 | (fields (immutable hash) (immutable equiv?)) 40 | (nongenerative #{gen-ht bu811z2onf9o6tfc-7}) 41 | (sealed #t)) 42 | 43 | (define-record-type eqv-ht 44 | (parent hashtable) 45 | (fields (immutable eqht) (immutable genht)) 46 | (nongenerative #{eqv-ht bu811z2onf9o6tfc-4}) 47 | (sealed #t)) 48 | -------------------------------------------------------------------------------- /mats/foreign1.c: -------------------------------------------------------------------------------- 1 | /* foreign1.c 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #ifdef _WIN32 18 | # define SCHEME_IMPORT 19 | # include "scheme.h" 20 | # undef EXPORT 21 | # define EXPORT extern __declspec (dllexport) 22 | #else 23 | #include "scheme.h" 24 | #endif 25 | 26 | EXPORT int id(int x) { 27 | return x; 28 | } 29 | 30 | EXPORT int idid(int x) { 31 | return id(id(x)); 32 | } 33 | 34 | EXPORT int ididid(x) int x; { 35 | return idid(id(x)); 36 | } 37 | 38 | EXPORT unsigned int iduns(unsigned int x) { 39 | return x; 40 | } 41 | 42 | EXPORT iptr idiptr(iptr x) { 43 | return x; 44 | } 45 | 46 | EXPORT iptr idiptr_addr(void) { 47 | return (iptr)&idiptr; 48 | } 49 | 50 | EXPORT double float_id(double x) { 51 | return x; 52 | } 53 | 54 | #ifdef _WIN32 55 | #include 56 | 57 | EXPORT int windows_strcpy(char *dst, char *src) { 58 | return strcpy(dst, src); 59 | } 60 | 61 | EXPORT int windows_strcmp(char *dst, char *src) { 62 | return strcmp(dst, src); 63 | } 64 | 65 | EXPORT void *windows_malloc(long n) { 66 | return malloc(n); 67 | } 68 | 69 | EXPORT void windows_free(void *x) { 70 | free(x); 71 | } 72 | #endif 73 | -------------------------------------------------------------------------------- /release_notes/gifs/Makefile: -------------------------------------------------------------------------------- 1 | gifs = ghostRightarrow.gif 2 | 3 | density=-r90x90 4 | 5 | .SUFFIXES: 6 | .SUFFIXES: .tex .gif 7 | 8 | # translate ps file to ppm, crop to minimum background, and translate ppm 9 | # to gif with white (background) transparent 10 | # 11 | .tex.gif: 12 | echo | latex $* &&\ 13 | dvips -f < $*.dvi |\ 14 | gs -q -dNOPAUSE -dSAFER -sDEVICE=ppmraw -sOutputFile=-\ 15 | ${density} - |\ 16 | pnmcrop |\ 17 | ppmtogif -transparent white > $*.gif 18 | /bin/rm -f $*.dvi $*.log *.aux 19 | test -f $*.gif && chmod 644 $*.gif 20 | 21 | all: ${gifs} 22 | 23 | # make ghostRightarrow.gif a completely transparent version of Rightarrow.ps 24 | # 25 | # translate ps to gif as above but w/o making white transparent, map black 26 | # to white, convert to ppm, and convert back to gif with white transparent 27 | # 28 | # could skip intermediate conversion to gif if we could map black to white 29 | # with some ppm tool 30 | # 31 | # it seems like should be able to replace last three steps with 32 | # giftrans -g '#000000=#ffffff' -t '#ffffff' 33 | # or at least 34 | # giftrans -g '#000000=#ffffff' | giftrans -t '#ffffff' 35 | # but giftrans changes only the first white color it sees, not all 36 | # 37 | ghostRightarrow.gif: Rightarrow.tex 38 | echo | latex Rightarrow &&\ 39 | dvips -f < Rightarrow.dvi |\ 40 | gs -q -dNOPAUSE -dSAFER -sDEVICE=ppmraw -sOutputFile=-\ 41 | ${density} - |\ 42 | pnmcrop |\ 43 | ppmtogif |\ 44 | giftrans -g '#000000=#ffffff' |\ 45 | giftopnm |\ 46 | ppmtogif -transparent white > $*.gif 47 | /bin/rm -f Rightarrow.dvi Rightarrow.log Rightarrow.aux 48 | test -f $*.gif && chmod 644 $*.gif 49 | 50 | clean: ; /bin/rm -f *.gif Make.out 51 | -------------------------------------------------------------------------------- /s/bldnt.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | REM bldnt machine-name 3 | echo (reset-handler abort) (base-exception-handler (lambda (c) (fresh-line) (display-condition c) (newline) (abort))) (case-sensitive #t) (optimize-level 2) (current-expand sc-expand) (generate-inspector-information #f) (subset-mode 'system) (compile-file "cmacros.ss" "cmacros.so") | ..\bin\%1\scheme -q --libdirs ..;. 4 | echo (reset-handler abort) (base-exception-handler (lambda (c) (fresh-line) (display-condition c) (newline) (abort))) (case-sensitive #t) (optimize-level 2) (current-expand sc-expand) (generate-inspector-information #f) (subset-mode 'system) (compile-file "priminfo.ss" "priminfo.so") | ..\bin\%1\scheme -q --libdirs ..;. cmacros.so 5 | echo (reset-handler abort) (base-exception-handler (lambda (c) (fresh-line) (display-condition c) (newline) (abort))) (case-sensitive #t) (optimize-level 2) (current-expand sc-expand) (subset-mode 'system) (compile-file "primvars.ss" "primvars.so") | ..\bin\%1\scheme -q --libdirs ..;. cmacros.so priminfo.so 6 | echo (reset-handler abort) (base-exception-handler (lambda (c) (fresh-line) (display-condition c) (newline) (abort))) (case-sensitive #t) (optimize-level 2) (current-expand sc-expand) (subset-mode 'system) (compile-file "setup.ss" "setup.so") | ..\bin\%1\scheme -q --libdirs ..;. cmacros.so priminfo.so 7 | echo (reset-handler abort) (base-exception-handler (lambda (c) (fresh-line) (display-condition c) (newline) (abort))) (case-sensitive #t) (optimize-level 2) (current-expand sc-expand) (generate-inspector-information #f) (collect-trip-bytes (expt 2 24)) (collect-request-handler (lambda () (collect 0 1))) (collect 1 2) (compile-library "../nanopass/nanopass.ss" "nanopass.so") | ..\bin\%1\scheme -q --libdirs "..\nanopass;;." --compile-imported-libraries 8 | ..\bin\%1\scheme -q --libdirs ..;. cmacros.so priminfo.so primvars.so setup.so --script script.all 9 | -------------------------------------------------------------------------------- /c/arm32le.c: -------------------------------------------------------------------------------- 1 | /* arm32le.c 2 | * Copyright 1984-2016 Cisco Systems, Inc. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #include "system.h" 18 | 19 | #include 20 | #include 21 | 22 | /* we don't count on having the right value for correctness, 23 | * but the right value will give maximum efficiency */ 24 | #define DEFAULT_L1_MAX_CACHE_LINE_SIZE 32 25 | 26 | static int l1_max_cache_line_size; 27 | 28 | /* flushcache_max_gap is the maximum gap between unmerged chunks of memory to be flushed */ 29 | INT S_flushcache_max_gap(void) { 30 | return l1_max_cache_line_size; 31 | } 32 | 33 | void S_doflush(uptr start, uptr end) { 34 | #ifdef DEBUG 35 | printf(" doflush(%x, %x)\n", start, end); fflush(stdout); 36 | #endif 37 | 38 | __clear_cache((char *)start, (char *)end); 39 | } 40 | 41 | void S_machine_init() { 42 | int l1_dcache_line_size, l1_icache_line_size; 43 | 44 | if ((l1_dcache_line_size = sysconf(_SC_LEVEL1_DCACHE_LINESIZE)) <= 0) { 45 | l1_dcache_line_size = DEFAULT_L1_MAX_CACHE_LINE_SIZE; 46 | } 47 | if ((l1_icache_line_size = sysconf(_SC_LEVEL1_ICACHE_LINESIZE)) <= 0) { 48 | l1_icache_line_size = DEFAULT_L1_MAX_CACHE_LINE_SIZE; 49 | } 50 | l1_max_cache_line_size = l1_dcache_line_size > l1_icache_line_size ? l1_dcache_line_size : l1_icache_line_size; 51 | } 52 | -------------------------------------------------------------------------------- /c/Mf-base: -------------------------------------------------------------------------------- 1 | # Mf-base 2 | # Copyright 1984-2016 Cisco Systems, Inc. 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | include Mf-config 17 | 18 | Include=../boot/$m 19 | ZlibInclude=../zlib 20 | PetiteBoot=../boot/$m/petite.boot 21 | SchemeBoot=../boot/$m/scheme.boot 22 | Kernel=../boot/$m/kernel.$o 23 | Main=../boot/$m/main.$o 24 | Scheme=../bin/$m/scheme 25 | 26 | kernelsrc=statics.c segment.c alloc.c symbol.c intern.c gcwrapper.c gc-ocd.c gc-oce.c\ 27 | number.c schsig.c io.c new-io.c print.c fasl.c stats.c foreign.c prim.c prim5.c flushcache.c\ 28 | schlib.c thread.c expeditor.c scheme.c 29 | 30 | kernelobj=${kernelsrc:%.c=%.$o} ${mdobj} 31 | 32 | kernelhdr=system.h types.h version.h globals.h externs.h segment.h gc.c sort.h thread.h config.h itest.c 33 | 34 | mainsrc=main.c 35 | 36 | mainobj:=${mainsrc:%.c=%.$o} 37 | 38 | doit: ${Scheme} 39 | 40 | source: ${kernelsrc} ${kernelhdr} ${mdsrc} ${mainsrc} 41 | 42 | ${Main}: ${mainobj} 43 | cp -p ${mainobj} ${Main} 44 | 45 | rootsrc=$(shell cd ../../c; echo *) 46 | ${rootsrc}: ; ln -s ../../c/$@ $@ 47 | 48 | scheme.o: itest.c 49 | scheme.o main.o: config.h 50 | ${kernelobj}: system.h types.h version.h externs.h globals.h segment.h thread.h sort.h 51 | ${kernelobj}: ${Include}/equates.h ${Include}/scheme.h 52 | ${mainobj}: ${Include}/scheme.h 53 | scheme.o io.o new-io.o: ${ZlibInclude}/zconf.h ${ZlibInclude}/zlib.h 54 | gc-ocd.o gc-oce.o: gc.c 55 | 56 | clean: 57 | rm -f *.$o ${mdclean} 58 | rm -f Make.out 59 | -------------------------------------------------------------------------------- /csug/tspl4/libraries.aux: -------------------------------------------------------------------------------- 1 | \relax 2 | \@writefile{toc}{\contentsline {chapter}{\numberline {10}Libraries and Top-Level Programs}{341}} 3 | \@writefile{lof}{\addvspace {10\p@ }} 4 | \@writefile{lot}{\addvspace {10\p@ }} 5 | \newlabel{CHPTLIBRARIES}{{10}{341}} 6 | \citation{r6rs} 7 | \citation{r6rs} 8 | \citation{r6rslibs} 9 | \newlabel{./libraries:s0}{{10}{343}} 10 | \newlabel{./libraries:s1}{{10}{343}} 11 | \@writefile{toc}{\contentsline {section}{\numberline {10.1}Standard Libraries}{343}} 12 | \@writefile{toc}{\contentsline {section}{\numberline {10.2}Defining New Libraries}{344}} 13 | \newlabel{./libraries:s2}{{10.2}{344}} 14 | \newlabel{./libraries:s3}{{10.2}{345}} 15 | \newlabel{./libraries:s4}{{10.2}{345}} 16 | \newlabel{./libraries:s5}{{10.2}{345}} 17 | \newlabel{desc:import}{{10.2}{345}} 18 | \newlabel{./libraries:s6}{{10.2}{345}} 19 | \newlabel{./libraries:s7}{{10.2}{345}} 20 | \newlabel{export-level}{{10.2}{345}} 21 | \newlabel{./libraries:s8}{{10.2}{346}} 22 | \newlabel{./libraries:s9}{{10.2}{346}} 23 | \newlabel{./libraries:s10}{{10.2}{346}} 24 | \newlabel{./libraries:s11}{{10.2}{346}} 25 | \newlabel{./libraries:s12}{{10.2}{346}} 26 | \newlabel{./libraries:s13}{{10.2}{347}} 27 | \newlabel{./libraries:s14}{{10.2}{348}} 28 | \newlabel{./libraries:s15}{{10.2}{349}} 29 | \newlabel{./libraries:s16}{{10.2}{349}} 30 | \newlabel{SECTLIBPROGRAMS}{{10.3}{350}} 31 | \@writefile{toc}{\contentsline {section}{\numberline {10.3}Top-Level Programs}{350}} 32 | \newlabel{./libraries:s17}{{10.3}{350}} 33 | \newlabel{./libraries:s18}{{10.3}{350}} 34 | \newlabel{SECTLIBEXAMPLES}{{10.4}{350}} 35 | \@writefile{toc}{\contentsline {section}{\numberline {10.4}Examples}{350}} 36 | \@setckpt{libraries}{ 37 | \setcounter{page}{355} 38 | \setcounter{equation}{0} 39 | \setcounter{enumi}{6} 40 | \setcounter{enumii}{0} 41 | \setcounter{enumiii}{0} 42 | \setcounter{enumiv}{0} 43 | \setcounter{footnote}{0} 44 | \setcounter{mpfootnote}{0} 45 | \setcounter{chapter}{10} 46 | \setcounter{section}{4} 47 | \setcounter{exercise}{0} 48 | \setcounter{alphacount}{6} 49 | } 50 | -------------------------------------------------------------------------------- /release_notes/scheme.sty: -------------------------------------------------------------------------------- 1 | \usepackage{color} 2 | \def\transerr#1{\begingroup\slshape} 3 | \def\transin#1{\begingroup\color{red}} 4 | \def\transout#1{\begingroup\color{blue}} 5 | \def\endtranserr#1{\endgroup} 6 | \def\endtransin#1{\endgroup} 7 | \def\endtransout#1{\endgroup} 8 | 9 | \newskip\ttglue 10 | \let\ninefivett=\tt % \font\ninefivett=cmtt9 at 9.5pt 11 | \ttglue=.5em plus .25em minus .15em 12 | \newskip\schemeindent 13 | \schemeindent=0pt 14 | {\obeyspaces\global\let =\ } 15 | \def\schtilde{\raisebox{-.5ex}{\hbox to .5em{\hss\large\rm\char`\~\hss}}} 16 | \def\schdot{\hbox to .5em{\hfil\large\bf.\hfil}} 17 | \def\schcarat{\char`\^} 18 | \def\schbackslash{\char`\\} 19 | \def\schatsign{\hbox to .5em{\hss\footnotesize\rm\char`\@\hss}} 20 | \def\schunderscore{\hbox to .5em{\hss\large\_\hss}} 21 | \def\schlbrace{$\{$} 22 | \def\schrbrace{$\}$} 23 | \def\scheme#1{\mbox{\ttfamily\ninefivett\frenchspacing\spaceskip=\ttglue#1}} 24 | 25 | \def\schemeblankline{\par\beforeschemedisplay} 26 | \def\schemelinestart{{\leavevmode\hbox{\hskip \schemeindent\relax}}} 27 | %%% handle numbered lines in scheme.sty and scheme.hsty 28 | %%% ---have scheme-prep produce only \schemelinestart 29 | \def\schemelinestartnumbered#1{{\leavevmode\hbox{\hbox to 1em {\hfil{\rm #1}} \hskip .5\schemeindent\relax}}} 30 | 31 | \def\noskip\schemedisplay{\begingroup% 32 | \parindent=0pt% 33 | \parskip=0pt% 34 | \def\becomes{\hbox to 2em{\hfil$\rightarrow$\hfil}}% 35 | \def\is{\hbox to 2em{\hfil$\Rightarrow$\hfil}}% 36 | \def\si{\hbox to 2em{\hfil}}% 37 | \interlinepenalty=2000% 38 | \baselineskip=11pt plus 1pt\ninefivett\obeyspaces\frenchspacing} 39 | \def\schemedisplay{\beforeschemedisplay\noskip\schemedisplay} 40 | \def\longcode\schemedisplay{\penalty-200\vskip 8pt plus 4pt% 41 | \kern3pt\hrule\kern5pt\nobreak\noskip\schemedisplay} 42 | \def\endschemedisplay{\par\endgroup\afterschemedisplay} 43 | \def\var#1{{\normalsize\textrm{\textit{#1}}}} 44 | \def\raw#1{#1} 45 | \def\beforeschemedisplay{\penalty-100\vskip\parskip\vskip5pt} 46 | \def\afterschemedisplay{\penalty-200\vskip5pt} 47 | 48 | -------------------------------------------------------------------------------- /examples/queue.ss: -------------------------------------------------------------------------------- 1 | ;;; queue 2 | ;;; an abstract datatype 3 | 4 | ;;; operations: 5 | ;;; (queue) ;create a queue object 6 | 7 | ;;; if 'q' is a queue object: 8 | 9 | ;;; (q 'type?) ;return the type (queue), useful if there are other 10 | ;;; ;abstract datatypes floating around. 11 | ;;; (q 'empty?) ;returns true iff q is empty 12 | ;;; (q 'put val) ;adds val to end of q; returns val 13 | ;;; (q 'get) ;removes first element of q and returns it 14 | 15 | ;;; Examples 16 | 17 | ;;; (define! q (queue)) 18 | ;;; (q 'type?) => queue 19 | ;;; (q 'empty?) => #!true 20 | ;;; (q 'put 3) 21 | ;;; (q 'put 4) 22 | ;;; (q 'put 5) 23 | ;;; (q 'empty?) => () 24 | ;;; (q 'get) => 3 25 | ;;; (q 'get) => 4 26 | ;;; (q 'put 7) 27 | ;;; (q 'get) => 5 28 | ;;; (q 'get) => 7 29 | ;;; (q 'empty?) => #!true 30 | 31 | (define queue 32 | (lambda () 33 | (let ([head '()] [tail '()]) 34 | (lambda (request . args) 35 | (case request 36 | [type? 'queue] 37 | [empty? (null? head)] 38 | [put 39 | (let ([v (car args)]) 40 | (if (null? head) 41 | (let ([p (cons v '())]) 42 | (set! tail p) 43 | (set! head p)) 44 | (let ([quebit (cons v '())]) 45 | (set-cdr! tail quebit) 46 | (set! tail quebit))) 47 | v)] 48 | [get 49 | (if (null? head) 50 | (error 'queue "queue is empty") 51 | (let ([v (car head)]) 52 | (set! head (cdr head)) 53 | (when (null? head) (set! tail '())) 54 | v))] 55 | [else 56 | (error 'queue "~s is not a valid request" request)]))))) 57 | -------------------------------------------------------------------------------- /csug/summary.ss: -------------------------------------------------------------------------------- 1 | (define read-string 2 | (lambda (ip) 3 | (unless (eqv? (read-char ip) #\") 4 | (error 'read-string "no starting double-quote")) 5 | (list->string 6 | (let f () 7 | (let ([c (read-char ip)]) 8 | (cond 9 | [(eqv? c #\") '()] 10 | [(or (eqv? c #\newline) (eof-object? c)) 11 | (error 'read-string "no ending double-quote")] 12 | [else (cons c (f))])))))) 13 | 14 | (define readrol 15 | (lambda (ip) 16 | (let ([c (read-char ip)]) 17 | (if (eq? c #\newline) 18 | '() 19 | (cons c (readrol ip)))))) 20 | 21 | (define read-line 22 | (lambda (ip) 23 | (if (eof-object? (peek-char ip)) 24 | (peek-char ip) 25 | (let ([x (read-string ip)]) 26 | (cons x (readrol ip)))))) 27 | 28 | (define summary-read 29 | (lambda (ip) 30 | (do ([ls '() (cons line ls)] 31 | [line (read-line ip) (read-line ip)]) 32 | ((eof-object? line) (reverse! ls))))) 33 | 34 | (define summary-sort 35 | (lambda (x) 36 | (sort! (lambda (x y) (string