|
Name |
|
Date |
Size |
#Lines |
LOC |
| .. | | 03-May-2022 | - |
| .githooks/ | H | 10-May-2021 | - | 31 | 25 |
| .github/workflows/ | H | 10-May-2021 | - | 24 | 20 |
| benchmarks/ | H | 10-May-2021 | - | 21,179 | 18,966 |
| build-lib/chibi/char-set/ | H | 10-May-2021 | - | 59 | 45 |
| contrib/ | H | 10-May-2021 | - | 541 | 492 |
| data/ | H | 10-May-2021 | - | 3 | 2 |
| doc/ | H | 10-May-2021 | - | 1,969 | 1,592 |
| examples/ | H | 10-May-2021 | - | 107 | 77 |
| include/chibi/ | H | 10-May-2021 | - | 4,320 | 3,383 |
| js/ | H | 03-May-2022 | - | 5 | 4 |
| lib/ | H | 10-May-2021 | - | 81,304 | 66,106 |
| opt/ | H | 10-May-2021 | - | 83 | 75 |
| tests/ | H | 03-May-2022 | - | 5,978 | 4,722 |
| tools/ | H | 10-May-2021 | - | 3,892 | 3,500 |
| .gitignore | H A D | 10-May-2021 | 1,017 | 85 | 74 |
| .travis.yml | H A D | 10-May-2021 | 40 | 5 | 4 |
| AUTHORS | H A D | 10-May-2021 | 2.2 KiB | 73 | 61 |
| COPYING | H A D | 10-May-2021 | 1.4 KiB | 25 | 22 |
| Makefile | H A D | 03-May-2022 | 28.5 KiB | 535 | 427 |
| Makefile.detect | H A D | 03-May-2022 | 4.8 KiB | 214 | 178 |
| Makefile.libs | H A D | 10-May-2021 | 3.2 KiB | 116 | 82 |
| README-win32.md | H A D | 10-May-2021 | 2.1 KiB | 82 | 53 |
| README.libs | H A D | 10-May-2021 | 3.5 KiB | 111 | 83 |
| README.md | H A D | 10-May-2021 | 2.2 KiB | 59 | 41 |
| RELEASE | H A D | 10-May-2021 | 5 | 2 | 1 |
| TODO | H A D | 10-May-2021 | 7.1 KiB | 196 | 183 |
| VERSION | H A D | 10-May-2021 | 7 | 2 | 1 |
| appveyor.yml | H A D | 10-May-2021 | 1.9 KiB | 54 | 47 |
| bignum.c | H A D | 10-May-2021 | 60.4 KiB | 1,955 | 1,796 |
| chibi-scheme.pc.in | H A D | 10-May-2021 | 234 | 8 | 7 |
| configure | H A D | 10-May-2021 | 195 | 6 | 3 |
| eval.c | H A D | 10-May-2021 | 93.2 KiB | 2,676 | 2,451 |
| fedora.spec | H A D | 10-May-2021 | 1.8 KiB | 60 | 44 |
| gc.c | H A D | 10-May-2021 | 22.7 KiB | 760 | 692 |
| gc_heap.c | H A D | 10-May-2021 | 24.8 KiB | 790 | 638 |
| main.c | H A D | 10-May-2021 | 23 KiB | 682 | 630 |
| mkfile | H A D | 10-May-2021 | 2.9 KiB | 110 | 81 |
| opcodes.c | H A D | 10-May-2021 | 24.1 KiB | 296 | 286 |
| plan9.c | H A D | 10-May-2021 | 12.3 KiB | 354 | 308 |
| sexp.c | H A D | 10-May-2021 | 137.5 KiB | 3,814 | 3,602 |
| simplify.c | H A D | 10-May-2021 | 6.7 KiB | 197 | 163 |
| vm.c | H A D | 10-May-2021 | 82.3 KiB | 2,352 | 2,212 |
README-win32.md
1Chibi-scheme for Windows
2========================
3
4Chibi-scheme provides limited support for native desktop Windows. To use
5fully-featured Chibi-scheme on Windows, consider using POSIX layer such as
6Windows Subsytem for Linux(WSL), Cygwin or MSYS.
7
8Currently, only R7RS Small libraries are available for the platform.
9
10Supported Environments
11----------------------
12
13Chibi-scheme can be compiled with following platforms:
14
15* Microsoft Visual Studio 2017
16* MinGW32
17* MinGW64
18* MSYS
19
20
21Known Issues
22------------
23
24Following libraries are not ported yet:
25
26* `(chibi net)`
27* `(chibi process)` : `exit` is available through `(scheme process-context)`
28* `(chibi stty)`
29* `(chibi system)`
30* `(chibi time)`
31
32Following library is not completely ported:
33
34* `(chibi filesystem)`
35
36Other issues:
37
38* SRFI-27: Due to C Runtime limitation, the library is not thread-safe
39* `make install` is not supported on Windows platforms
40* On MSVC, flonum precision is degraded when compared with other compilers
41* Cross compilation is not supported
42
43
44Build with MinGW(Makefile)
45--------------------------
46
47The top-level `Makefile` can be used with MinGW.
48
491. Open MinGW64 or MinGW32 command prompt
502. `make`
513. `make test`
52
53Currently, `make doc` is not supported on these platforms.
54
55
56Build with MSYS(Makefile)
57-------------------------
58
59By default, the Makefile will compile against native Windows API. To use
60MSYS's own POSIX emulation layer, specify `PLATFORM=msys`.
61
621. Open MSYS command prompt
632. `make PLATFORM=msys`
643. `make PLATFORM=msys test`
65
66
67Build with Visual Studio(CMake)
68-------------------------------
69
70Minimal `CMakeLists.txt` is provided as an example to build Chibi-scheme on
71Windows platforms. This is only intended to be used with Windows platforms;
72currently it does not provide features provided with standard `Makefile` nor
73it does not support UNIX/APPLE platforms either.
74
751. (Make sure CMake was selected with Visual Studio installer)
762. Open this directory with "Open with Visual Studio"
773. Choose "x86-" or "x64-" configuration
784. "CMake" => "Build all"
795. "CMake" => "Tests" => "Run chibi-scheme Tests"
80
81
82
README.libs
1Using the Makefile.libs File To Build and Install Libraries
2-----------------------------------------------------------
3
4The Makefile.libs file distributed with the Chibi Scheme sources
5can facilitate building and installing Chibi Scheme libraries written
6in C or Scheme. To use it, follow these instructions:
7
81. Copy the Makefile.libs and Makefile.detect files from the Chibi
9 Scheme source directory to the library source top-level directory.
10
112. Place the library source in the subdirectory "lib" of the library
12 source top-level directory. For example,
13
14 lib/foo/bar.c
15 lib/foo/bar.h
16 lib/foo/bar.sld
17 lib/foo/bar.scm
18
193. In the Makefile in the library source top-level directory, define
20 the following targets:
21
22 all
23 doc
24 install
25 uninstall
26 clean
27 dist-clean
28
29 These should depend on the corresponding "-libs" target, but
30 can include additional commands. For example:
31
32 all: all-libs
33 install: install-libs
34 cp -r doc $(PREFIX)/share/chibi/
35 uninstall: uninstall-libs
36 doc: doc-libs
37 clean: clean-libs
38 dist-clean: dist-clean-libs
39
40 The all target should be the first target in the Makefile.
41
42 The all-libs target makes the shared libraries in the library.
43 The doc-libs target generates HTML files for the library. The
44 install-libs and uninstall-libs targets install and uninstall
45 the library under the prefix. The clean-libs target removes the
46 shared libraries and generated HTML files. The dist-clean-libs
47 removes any .c files generated from .stub files and also performs
48 a clean-libs.
49
504. In the Makefile in the library source top-level directory, define
51 the following variables:
52
53 COMPILED_LIBS: Any shared libraries that should be built and
54 installed. The shared library is build from the corresponding
55 .c or .stub file. The $(SO) variable should be used for the
56 shared-library suffix; in order for this to work COMPILED_LIBS
57 should be defined as a recursively-expanded variable (with
58 =) rather than a simply-expanded variable (with :=).
59
60 INCLUDES: Any other files on which the shared libraries depend.
61
62 SCM_LIBS: Any Scheme source files that should be installed.
63
64 HTML_LIBS: Any HTML files that should be generated. The HTML
65 files are generated from the corresponding .sld files using
66 chibi-doc.
67
68 For example,
69
70 COMPILED_LIBS = lib/foo/bar$(SO)
71 INCLUDES = lib/foo/bar.h
72 SCM_LIBS = lib/foo/bar.sld lib/foo/bar.scm
73 HTML_LIBS = doc/lib/foo/bar.html
74
755. Add additional flags as necessary to XCPPFLAGS, XCFLAGS, and XLIBS.
76 These flags are passed to the compiler and linker when they
77 generate the shared library. These should probably be defined at
78 minimum as:
79
80 XCPPFLAGS += -I$(PREFIX)/include
81 XCFLAGS += -L$(PREFIX)/lib
82 XLIBS +=
83
84 These additions will ensure that the compiler and linker can
85 find the Chibi Scheme include and library files, even if they
86 are installed under a non-standard prefix.
87
886. Include the common Makefile using:
89
90 include Makefile.libs
91
92A complete example is:
93
94 all: all-libs
95 install: install-libs
96 uninstall: uninstall-libs
97 doc: doc-libs
98 clean: clean-libs
99 dist-clean: dist-clean-libs
100
101 COMPILED_LIBS = lib/foo/bar$(SO)
102 INCLUDES = lib/foo/bar.h
103 SCM_LIBS = lib/foo/bar.sld lib/foo/bar.scm
104 HTML_LIBS = doc/lib/foo/bar.html
105
106 XCPPFLAGS += -I$(PREFIX)/include
107 XCFLAGS += -L$(PREFIX)/lib
108 XLIBS += -lpthread
109
110 include Makefile.libs
111
README.md
1# ![Chibi-Scheme](https://goo.gl/ZDtn4q)
2
3**Minimal Scheme Implementation for use as an Extension Language**
4
5http://synthcode.com/wiki/chibi-scheme
6
7Chibi-Scheme is a very small library intended for use as an extension
8and scripting language in C programs. In addition to support for
9lightweight VM-based threads, each VM itself runs in an isolated heap
10allowing multiple VMs to run simultaneously in different OS threads.
11
12There are no external dependencies so is relatively easy to drop into
13any project.
14
15Despite the small size, Chibi-Scheme attempts to do The Right Thing.
16The default settings include:
17
18* a full numeric tower, with rational and complex numbers
19* full and seamless Unicode support
20* low-level and high-level hygienic macros
21* an extensible module system
22
23Specifically, the default repl language contains all bindings from
24[R7RS small](https://small.r7rs.org/), available explicitly as the
25`(scheme small)` library. The language is built in layers, however -
26see the manual for instructions on compiling with fewer features or
27requesting a smaller language on startup.
28
29Chibi-Scheme is known to work on **32** and **64-bit** Linux, FreeBSD,
30NetBSD, OpenBSD and OS X, Plan 9, Windows, iOS, Android,
31ARM and [Emscripten](https://kripken.github.io/emscripten-site). Basic
32support for native Windows desktop also exists. See README-win32.md
33for details and build instructions.
34
35To build on most platforms just run `make && make test`. This has a
36few conditionals assuming GNU make. If using another make, there are
37a few parameters in Makefile.detect you need to set by hand.
38
39This will provide a shared library *libchibi-scheme*, as well as a
40sample *chibi-scheme* command-line repl. You can then run
41
42 sudo make install
43
44to install the binaries and libraries. You can optionally specify a
45**PREFIX** for the installation directory:
46
47 make PREFIX=/path/to/install/
48 sudo make PREFIX=/path/to/install/ install
49
50By default files are installed in **/usr/local**.
51
52If you want to try out chibi-scheme without installing, be sure to set
53`LD_LIBRARY_PATH` so it can find the shared libraries.
54
55To make the emscripten build run `make js`.
56
57For more detailed documentation, run `make doc` and see the generated
58*doc/chibi.html*.
59