This is unofficial repository for SMLFormat distribution.
This repository is salvaged from the official SMLFormat distribution (included in SML# 0.90 compiler distribution). The SMLFormat consists of two components:
smlformat-lib
is a pretty printer library for SML.smlformat
is a pretty printer generator for SML.
- This is not official repository.
- mllex (mllex-polyml for Poly/ML)
- mlyacc and mlyacc-lib (mlyacc-polyml for Poly/ML)
- smlnj-lib (smlnj-lib-polyml for Poly/ML)
- smlunit-lib (unit test)
- smldoc (documentations)
-
SML#
Tested 1.0.0
-
SML/NJ
Tested 110.97, 110.98.1
-
MLton
Tested 20130715
-
Poly/ML
Tested 5.8.1
Firstly, execute ./configure
script and then make
.
$ ./configure
$ make
smlformat
and formatlib
are installed with install
target:
$ make install
doc
target generates api documents to doc/api.
This target requires SMLDoc.
$ make doc
To build SMLFormat
, run the default target of Makefile.smlnj
.
$ make -f Makefile.smlnj
The default target generates smlformat
, smlformat-lib
, smlformatlib
for backword compatibility, ppg-ext
and smlformat-tool
and documentations of the SMLFormat
api.
If you do not need the documentations, run the smlformat-nodoc
target.
$ make -f Makefile.smlnj smlformat-nodoc
To install smlformat
, run the install
target.
$ make -f Makefile.smlnj install
To change the installation directory, specify PREFIX
:
$ make -f Makefile.smlnj install PREFIX=~/.sml/smlnj/110.99
If you do not need the documentations, run the install-nodoc
target.
$ make -f Makefile.smlnj install-nodoc
To generate the documentations of SMLFormat
, run the doc
target.
$ make -f Makefile.smlnj doc
To run the unit tests, run the test
target.
$ make -f Makefile.smlnj test
To build examples, run the example
target.
$ make -f Makefile.smlnj example
To build smlformat
, run the default target of Makefile.mlton
.
$ make -f Makefile.mlton
The default target generates smlformat
and documentations of the SMLFormat
api, and type checks smlformat-lib
and smlformatlib
for backword compatibility.
If you do not need the documentations, run the smlformat-nodoc
target.
$ make -f Makefile.mlton smlformat-nodoc
To install smlformat
, run the install
target.
$ make -f Makefile.mlton install
To change the installation directory, specify PREFIX
:
$ make -f Makefile.mlton install PREFIX=~/.sml/mlton
If you do not need the documentations, run the install-nodoc
target.
$ make -f Makefile.mlton install-nodoc
After installation, you need to add an entry to a mlb path mapping file:
$ echo 'SMLFORMAT_LIB $PREFIX/lib/SMLFormat' >> /path/to/mlb-path-map
To generate the documentations of SMLFormat
, run the doc
target.
$ make -f Makefile.mlton doc
To run the unit tests, run the test
target.
The unit tests require SMLUnit.
Makefile.mlton searches mlb-path-map
file on PREFIX
directory automatically.
$ make -f Makefile.mlton test
If your path map file could not been found, you need to specify the path to your path map file.
$ grep SMLUNIT_LIB /path/to/mlb-path-map
SMLUNIT_LIB /path/to/SMLUnit
$ make -f Makefile.mlton MLB_PATH_MAP=/path/to/mlb-path-map test
To build examples, run the example
target.
$ make -f Makefile.mlton example
To build smlformat
and smlformat-lib
, run the default target of Makefile.polyml
.
$ make -f Makefile.polyml
When some dependencies are not found, specify PREFIX
or LIBDIR
:
$ make -f Makefile.polyml install PREFIX=~/.sml/polyml/5.8.1
The default target generates smlformat
, smlformat-lib
and it's documentations.
If you do not need the documentations, run the smlformat-nodoc
and the smlformat-lib-nodoc
targets.
$ make -f Makefile.polyml smlformat-nodoc
To install smlformat
and smlformat-lib
, run the install
target.
$ make -f Makefile.polyml install
If you do not need the documentations, run the install-nodoc
target.
$ make -f Makefile.polyml install-nodoc
To generate the documentations of smlformat-lib
, run the doc
target.
$ make -f Makefile.polyml doc
To run the unit tests, run the test
target.
$ make -f Makefile.polyml test
To build examples, run the example
target.
$ make -f Makefile.polyml example
This software has been developed as a part of the SML# project. It is distributed under the BSD-style SMLSharp license, which is included in the file LICENSE in this directory.
For the details of SML# project, consult the web page at: http://www.pllab.riec.tohoku.ac.jp/smlsharp/
YAMATODANI Kiyoshi @2010, Tohoku University.