[Ur] Error doing 'make smlnj' (trying to access UrWeb compiler interactively, within SML/NJ)

Stefan Scott Alexander stefanscottalexx at gmail.com
Wed Dec 24 10:55:12 EST 2014


As a method of learning UrWeb, I am interested in accessing modules of some
of the demos interactively.

The UrWeb manual (http://www.impredicative.com/ur/manual.pdf - page 4)
seems to be saying that this can be done, as follows:

===

It is also possible to access the modules of the Ur/Web compiler
interactively, within Standard ML of New Jersey. To install the
prerequisites in Debian testing:

  apt-get install smlnj libsmlnj-smlnj ml-yacc ml-lpt

To begin an interactive session with the Ur compiler modules, run:

  make smlnj

and then, from within an sml session, run:

  CM.make "src/urweb.cm";

The Compiler module is the main entry point, and you can find its signature
in src/compiler.sig.

===

After downloading the UrWeb repository from mercurial and attempting to
perform these instructions on Debian Wheezy, the following errors occur:

(1) When doing 'make smlnj':
    make: *** No rule to make target 'smlnj'.  Stop.

(2) Arbitrarily skipping (1) and trying to do 'CM.make "src/urweb.cm";' in
sml:
    uncaught exception Io [Io: openIn failed on "src/urweb.cm", No such
file or directory]

Transcript below:

===

admin:~/urweb001/urweb$ sudo apt-get install smlnj libsmlnj-smlnj ml-yacc
ml-lpt
Reading package lists... Done
Building dependency tree
Reading state information... Done
libsmlnj-smlnj is already the newest version.
ml-lpt is already the newest version.
ml-yacc is already the newest version.
smlnj is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.

admin:~/urweb001/urweb$ ls -l
total 104
-rwxr-xr-x 1 admin admin    26 Dec 24 01:44 autogen.sh
drwxr-xr-x 2 admin admin  4096 Dec 24 01:44 bin
-rw-r--r-- 1 admin admin 18458 Dec 24 01:44 CHANGELOG
-rw-r--r-- 1 admin admin  3559 Dec 24 01:44 configure.ac
drwxr-xr-x 3 admin admin  4096 Dec 24 01:44 demo
drwxr-xr-x 2 admin admin  4096 Dec 24 01:44 doc
drwxr-xr-x 3 admin admin  4096 Dec 24 01:44 include
drwxr-xr-x 4 admin admin  4096 Dec 24 01:44 lib
-rw-r--r-- 1 admin admin  1447 Dec 24 01:44 LICENSE
drwxr-xr-x 2 admin admin  4096 Dec 24 01:44 m4
-rw-r--r-- 1 admin admin  3679 Dec 24 01:44 Makefile.am
drwxr-xr-x 5 admin admin  4096 Dec 24 01:44 src
drwxr-xr-x 3 admin admin 32768 Dec 24 01:44 tests
-rw-r--r-- 1 admin admin   693 Dec 24 01:44 urweb.ebuild
drwxr-xr-x 2 admin admin  4096 Dec 24 01:44 xml

admin:~/urweb001/urweb$ make smlnj
make: *** No rule to make target `smlnj'.  Stop.

admin:~/urweb001/urweb$ sml
Standard ML of New Jersey v110.74 [built: Sat Oct  6 00:59:36 2012]
- CM.make "src/urweb.cm";
[autoloading]
[library $smlnj/cm/cm.cm is stable]
[library $smlnj/internal/cm-sig-lib.cm is stable]
[library $/pgraph.cm is stable]
[library $smlnj/internal/srcpath-lib.cm is stable]
[library $SMLNJ-BASIS/basis.cm is stable]
[autoloading done]
[scanning src/urweb.cm]

uncaught exception Io [Io: openIn failed on "src/urweb.cm", No such file or
directory]
  raised at: Basis/Implementation/IO/text-io-fn.sml:783.25-783.71
             ../cm/util/safeio.sml:30.11
             ../cm/parse/parse.sml:502.47
-
admin:~/urweb001/urweb$

===

The makefile being used is here:

   http://hg.impredicative.com/urweb/file/d9f918b79b5a/Makefile.am

Line 20 of this file says:

   smlnj: src/urweb.cm xml/entities.sml

Questions:

(1) Is the line 20 a correct "rule to make target 'smlnj'"?

(2) The files src/urweb.cm and xml/entities.sml do not exist anywhere. Does
the above link mean that they will be *created* during the make? Or do they
need to exist *before* doing the make?

(3) What needs to be done in order to begin an interactive session with the
Ur compiler modules?

Thanks for any help!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.impredicative.com/pipermail/ur/attachments/20141224/db88d6f9/attachment.html>


More information about the Ur mailing list