Package Details: smlnj 110.79-1

Git Clone URL: https://aur.archlinux.org/smlnj.git (read-only)
Package Base: smlnj
Description: Standard ML of New Jersey, a compiler for the Standard ML '97 programming language
Upstream URL: http://www.smlnj.org/
Licenses: BSD
Provides: sml
Submitter: None
Maintainer: t-8ch
Last Packager: t-8ch
Votes: 59
Popularity: 0.108929
First Submitted: 2005-04-15 09:46
Last Updated: 2015-10-24 09:46

Latest Comments

hanjiexi commented on 2016-07-30 00:28

This package did not work until I added the following to my ~/.bashrc:
export PATH="/usr/lib/smlnj/bin:$PATH"
export SMLNJ_HOME=/usr/lib/smlnj/

The first line is for making the `sml` command work in the terminal, the second command is to tell the SML/NJ compiler where the standard library is.

mdl commented on 2015-07-31 08:03

@t-8ch That's strange. Are you sure the PKGBUILD you currently have committed to the AUR is the same one you have on your machine? Could you paste it + your environment + your /etc/makepkg.conf somewhere?

t-8ch commented on 2015-07-26 19:19

@mdl I don't have an `install` in $srcdir.

mdl commented on 2015-07-22 16:49

I get the same error. I think line 87 of the PKGBUILD is supposed to be:

cp -R "$srcdir/install/"{bin,lib} "$pkgdir/usr/lib/smlnj"

cocreature commented on 2015-07-19 21:33

I am getting an error during the package phase:
==> Starting package()...
cp: cannot stat ‘/home/moritz/code/pkgbuilds/smlnj/src/bin’: No such file or directory
cp: cannot stat ‘/home/moritz/code/pkgbuilds/smlnj/src/lib’: No such file or directory

t-8ch commented on 2015-05-03 10:42

@Xwang: I can't get those references out of the package. But if I am correct it should not matter anyways:

The references in shell scripts are only used if SMLNJ_HOME is not set, which wie do in out profile script.
The references in the binary files are the build locations of the files themselves. I assume this is for debugging purposes.

Xwang commented on 2015-05-03 09:28

When I compile the package I obtain this warning:

This package contains references to $srcdir (I have traslated from the italian message)

And this is the output of
grep -R "$(pwd)/src" pkg/

Il file binario pkg/smlnj/usr/lib/smlnj/lib/mllex-tool.cm/.cm/x86-unix/mllex-tool.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/mlyacc-tool.cm/.cm/x86-unix/mlyacc-tool.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/inet-lib.cm/.cm/x86-unix/inet-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/hash-cons-lib.cm/.cm/x86-unix/hash-cons-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/burg-ext.cm/.cm/x86-unix/burg-ext.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/unix-lib.cm/.cm/x86-unix/unix-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/ml-lpt-lib.cm/.cm/x86-unix/ml-lpt-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/html4-lib.cm/.cm/x86-unix/html4-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/cml/.cm/x86-unix/cml-internal.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/cml/.cm/x86-unix/core-cml.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/ml-ulex-tool.cm/.cm/x86-unix/ml-ulex-tool.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/reactive-lib.cm/.cm/x86-unix/reactive-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/smlnj-tdp/.cm/x86-unix/coverage.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/smlnj-tdp/.cm/x86-unix/plugins.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/smlnj-tdp/.cm/x86-unix/back-trace.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/grm-ext.cm/.cm/x86-unix/grm-ext.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/mlburg-tool.cm/.cm/x86-unix/mlburg-tool.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/ml-antlr-tool.cm/.cm/x86-unix/ml-antlr-tool.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/SMLNJ-MLRISC/.cm/x86-unix/StagedAlloc.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/SMLNJ-MLRISC/.cm/x86-unix/IA32-Peephole.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/SMLNJ-MLRISC/.cm/x86-unix/CCall-x86-64.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/SMLNJ-MLRISC/.cm/x86-unix/RA.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/SMLNJ-MLRISC/.cm/x86-unix/CCall-x86.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/SMLNJ-MLRISC/.cm/x86-unix/CCall-Vararg.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/SMLNJ-MLRISC/.cm/x86-unix/CCall-sparc.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/SMLNJ-MLRISC/.cm/x86-unix/Peephole.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/SMLNJ-MLRISC/.cm/x86-unix/AMD64-Peephole.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/SMLNJ-MLRISC/.cm/x86-unix/CCall.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/json-lib.cm/.cm/x86-unix/json-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/cml-lib/.cm/x86-unix/trace-cml.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/cml-lib/.cm/x86-unix/smlnj-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/ckit-lib.cm/.cm/x86-unix/ckit-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/lex-ext.cm/.cm/x86-unix/lex-ext.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/sexp-lib.cm/.cm/x86-unix/sexp-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/xml-lib.cm/.cm/x86-unix/xml-lib.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/c/internals/.cm/x86-unix/c-int.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/c/memory/.cm/x86-unix/memory.cm corrisponde
Il file binario pkg/smlnj/usr/lib/smlnj/lib/regexp-lib.cm/.cm/x86-unix/regexp-lib.cm corrisponde
pkg/smlnj/usr/lib/smlnj/bin/sml: BIN_DIR="/home/andreak/tmp/yaourt-tmp-andreak/aur-smlnj/src/bin"
Il file binario pkg/smlnj/usr/lib/smlnj/bin/.heap/sml.x86-linux corrisponde
pkg/smlnj/usr/lib/smlnj/bin/ml-yacc: BIN_DIR="/home/andreak/tmp/yaourt-tmp-andreak/aur-smlnj/src/bin"
pkg/smlnj/usr/lib/smlnj/bin/.run-sml: BIN_DIR="/home/andreak/tmp/yaourt-tmp-andreak/aur-smlnj/src/bin"
pkg/smlnj/usr/lib/smlnj/bin/ml-ulex: BIN_DIR="/home/andreak/tmp/yaourt-tmp-andreak/aur-smlnj/src/bin"
pkg/smlnj/usr/lib/smlnj/bin/.link-sml: BIN_DIR="/home/andreak/tmp/yaourt-tmp-andreak/aur-smlnj/src/bin"
pkg/smlnj/usr/lib/smlnj/bin/ml-antlr: BIN_DIR="/home/andreak/tmp/yaourt-tmp-andreak/aur-smlnj/src/bin"
pkg/smlnj/usr/lib/smlnj/bin/ml-nlffigen: BIN_DIR="/home/andreak/tmp/yaourt-tmp-andreak/aur-smlnj/src/bin"
pkg/smlnj/usr/lib/smlnj/bin/ml-burg: BIN_DIR="/home/andreak/tmp/yaourt-tmp-andreak/aur-smlnj/src/bin"
pkg/smlnj/usr/lib/smlnj/bin/ml-lex: BIN_DIR="/home/andreak/tmp/yaourt-tmp-andreak/aur-smlnj/src/bin"

Is it all right or is there something wrong to resolve before installing?
If I install and then remove the $srcdir i fear it will misbehave.

eazar001 commented on 2015-05-02 08:35

errr i guess i meant to say @t-8ch, thanks.

eazar001 commented on 2015-05-02 08:02

@beroal: thanks, but for future reference what is the proper channel for submitting patches on AUR?

t-8ch commented on 2015-05-02 08:00

@eazar001, beroal: I have uploaded a new version fixing this

beroal commented on 2015-05-02 05:55

@eazar001: The correct way of dealing with such cases is adding a patch to a AUR package. You can send your "arch-n-opsys" to the package maintainer.

eazar001 commented on 2015-05-01 21:38

Okay, I got this working in a rather crude way for Linux 4.0:
1) Edit config/_arch-n-opsys and add a line that says "4.*) ;;" to line 67.
2) tar and gzip that entire directory into a replacement for the config.tgz file in the build package
and overwrite the original upstream version.
3) generate a new sha256 checksum for that file and make the appropriate changes in PKGBUILD
4) re-run with: makepkg --needed -i
5) build and install will succeed

eazar001 commented on 2015-05-01 21:11

@beroal, after inspecting .arch-n-opsys it appears that it's not supporting 4.X kernel (which I am running), so I suppose I need to change that. Not sure how I would get that working with makepkg though, am I just going to have to build this manually?

beroal commented on 2015-05-01 07:16

On my computer: {{{
config/install.sh: Script /var/abs/local/smlnj/src/bin/.arch-n-opsys reports ARCH=x86; OPSYS=linux; HEAP_SUFFIX=x86-linux.
}}}
Maybe, you are running it on some exotic system.

eazar001 commented on 2015-05-01 02:50

Hmm, maybe I forgot to mention i'm running 32-bit ... are build instructions different in this case?
Here are the steps i took to build:
1) makepkg -si
2) failed build

-------------------------------------------
What am I missing?

eazar001 commented on 2015-04-30 23:39

@t-8ch: I delete the directories in the path and it still didn't help.

t-8ch commented on 2015-04-30 22:31

@eazar001: Try deleting the $srcdir and $pkgdir

eazar001 commented on 2015-04-30 22:30

I'm getting this error:
config/install.sh: !!! Script /tmp/yaourt-tmp-ebrahim/aur-smlnj/src/bin/.arch-n-opsys fails on this machine.
config/install.sh: !!! You must patch this by hand and repeat the installation.

... patch what by hand?

jperry commented on 2015-04-30 21:27

Another request: to have the package install the man pages from the documentation archive "doc.tgz". Thanks.

xyproto commented on 2014-12-09 12:51

I think it would be handy to have a working "sml" in the path after installing the package, but you're the maintainer. :)

t-8ch commented on 2014-12-09 09:13

@xyproto: is the snippet in profile.d not enough?

xyproto commented on 2014-12-08 12:41

Please consider including this script in the package, as /usr/bin/sml:

#!/bin/sh
SMLNJ_HOME=/usr/lib/smlnj PATH=/usr/lib/smlnj/bin:$PATH sml "$@"

Shibumi commented on 2014-01-20 20:57

Thx for uploading this package :)

dwalz commented on 2013-02-02 13:46

Works now, thanks!
To sum up for other, SMLNJ_HOME="/usr/lib/smlnj" needs to be set and optionally /usr/bin/smlnj/bin added to PATH

t-8ch commented on 2013-02-02 13:14

makepkg --source -f is my friend! Sorry.
Please try again.

dwalz commented on 2013-02-02 13:00

Yes.

t-8ch commented on 2013-02-02 12:37

Did you redownload the PKGBUILD/src.tar.gz?
I changed it without bumping the version, not to force people with working installations to rebuild everything.

dwalz commented on 2013-02-02 11:41

Hi t-8ch,

I rebuilt and set SMLNJ_HOME to "/usr/lib/smlnj".
Now I get axil42's error.

/usr/bin/sml: line 60: /usr/lib/smlnj/bin/.arch-n-opsys: No such file or directory
sml: unable to determine architecture/operating system

t-8ch commented on 2013-02-02 08:52

Please try to rebuild.
All files should be somewhere beneath /usr/lib/smlnj/{bin,lib}.
$SMLNJ_HOME should be "/usr/lib/smlnj" and $CM_PATHCONFIG shouldn't be set.

t-8ch commented on 2013-01-31 18:38

So we are back to stuffing everything into /usr/lib/smlnj/ and adding /usr/lib/smlnj/bin to $PATH.
I also can't get rid of $SMLNJ_HOME, as it hardcodes it's build location.
(It needs this for bootstrap itself, I think)

g_damian commented on 2013-01-31 17:35

New build breaks something, SMLNJ_HOME or CM_PATHCONFIG are not set:

Standard ML of New Jersey v110.75 [built: Thu Jan 31 18:26:03 2013]
- Int.toString(3);
[autoloading]

unexpected exception (bug?) in SML/NJ: Io [Io: openIn failed on "/tmp/yaourt-tmp-root/aur-smlnj/src/sml.boot.x86-unix/smlnj/basis/.cm/x86-unix/basis.cm", No such file or directory]
raised at: Basis/Implementation/IO/bin-io-fn.sml:617.25-617.71
../cm/util/safeio.sml:30.11
../compiler/TopLevel/interact/evalloop.sml:44.55
-

t-8ch commented on 2013-01-29 08:10

Is this from a shell where SMLNJ_HOME or CM_PATHCONFIG are set?
Try unsetting those. The new profile doesn't ship the profile.d script anymore.

axil42 commented on 2013-01-29 07:40

Hi! I get

/usr/bin/sml: line 60: /usr/lib/smlnj/bin/.arch-n-opsys: No such file or directory
sml: unable to determine architecture/operating system

I tried to create /usr/lib/smlnj/bin and make a symlink of /usr/bin/.arch-n-opsys to /usr/lib/smlnj/bin/.arch-n-opsys, but then I get

sml: cannot find runtime system /usr/lib/smlnj/bin/.run/run.x86-linux

So, I think the previous version of the PKGBUILD worked better.

t-8ch commented on 2013-01-28 20:51

I updated it, feel free to test it.

reflectionalist commented on 2013-01-28 20:10

Hi, t-8ch,


Thanks for the answer. But what is the reason for doing that? I mean the Nix file hierarchy is already quite messy in my opinion.

t-8ch commented on 2013-01-28 17:02

Yes, it also installs the script /etc/profile.d/smlnj.sh which adds
/usr/lib/smlnj/bin to the $PATH. See the mailman package for another example.

(Note that the script name was wrong, I fixed this. But it did work)

reflectionalist commented on 2013-01-28 10:03

Are you sure you want to copy both the `bin` and the `lib` directory into `/usr/lib/smlnj` via the following command?

cp -R "$srcdir/"{bin,lib} "$pkgdir/usr/lib/smlnj"

This way, `sml` is not in standard path `/usr/bin/` and cannot be invoked unless one adds `/usr/lib/smlnj/bin/` into the system search paths.

t-8ch commented on 2013-01-14 19:23

Thanks, updated (without bumping pkgrel)

gnud commented on 2013-01-14 19:05

If you (like me) have trouble building a new version, try unsetting the env. variable SMLNJ_HOME.

This should probably be done in the PKGBUILD, when calling install.sh

Anonymous comment on 2013-01-14 14:54

Sorry, folks; thanks to hardware failures at home and changes in what I am doing at work, I have not had a proper Arch system, and was unable to do maintenance. I abandoned the project so that someone who can keep up with it can take it over.

I believe that in a few releases, SML/NJ should natively support x86_64 in their compiler, and they will reset the numbering too, so that may help make things a little more sane in making sure it works as well. Thanks!

favadi commented on 2013-01-14 05:00

PKGBUILD:
https://dl.dropbox.com/u/6863335/smlnj-110.75-1.src.tar.gz
Binary (64bit):
https://dl.dropbox.com/u/6863335/smlnj-110.75-1-x86_64.pkg.tar.xz

Anonymous comment on 2013-01-11 23:32

cjpembo's PKGBUILD from the forum works great. And it easily updates to 110.75.

Anonymous comment on 2012-02-27 15:57

I've created an up-to-date and easier to maintain PKGBUILD for smlnj. I submitted it for review here:

https://bbs.archlinux.org/viewtopic.php?pid=1062470#p1062470

Please test it out!

jschuster commented on 2012-02-04 15:28

One other thing: ml-ulex doesn't get installed with this package. It'd be nice to add that in, since Andrew Appel's compiler textbook uses it, and it's in the default install from the smlnj website.

jschuster commented on 2012-01-22 18:28

cybojanek's updates work great. bohanlon, would you mind updating the package to include these changes? That way users like me don't have to dig into all of this and figure out what actually works and what doesn't before installing.

The one thing for users to know is that they'll need to replace their old base-devel packages with the ones from multilib as part of the process. This is the recommended way to build 32-bit packages according to the Arch wiki (https://wiki.archlinux.org/index.php/Arch64_FAQ#Can_I_build_32-bit_packages_for_i686_inside_Arch64.3F), so it's nothing to worry about.

Also, it looks like the 3.* kernel issue has been fixed, but not put into an official release yet, so you might keep an eye out for that (see http://smlnj-gforge.cs.uchicago.edu/tracker/?group_id=33&atid=215&func=detail&aid=80).

Anonymous comment on 2011-09-24 08:49

The issues people have been having on 64 bit systems, is the lack of 32 bit emulation mode.
In .73 they have clarified the error, and in order to fix it you need multilib packages.
The 3.* kernel bug has already been submitted, but not yet fixed by the devs, so the patch is still needed.

Enclosed is an updated PKGBUILD and patch for dragonly/kernel (line numbers have changed due to extra proc/mac support)
They're based on the current PKGBUILD and not borman's :p, sorry!

This is my first time contributing to AUR so I'm kinda excited :D
http://pastebin.com/TUNi3LUw
http://pastebin.com/HFNKcLB0


Anonymous comment on 2011-09-22 17:29

That explains it.
From Linux it makes a branch to 64/32 bit and only checks the kernels for 32bit machines.
Here is the whole snippet:
http://pastebin.com/dbiqHRR8

Anonymous comment on 2011-09-22 17:20

Yep:
Linux garg 3.0-ARCH #1 SMP PREEMPT Tue Aug 30 08:53:25 CEST 2011 x86_64 Intel(R) Atom(TM) CPU N570 @ 1.66GHz GenuineIntel GNU/Linux

Are you on a 32-bit machine? I need to look at the machine detection script; I wonder if it makes assumptions in 64-bit mode that it does not in 32-bit.

Anonymous comment on 2011-09-22 17:13

Are you running at least kernel 3.0?
The error I get is:

http://pastebin.com/H97Uahkq

Anonymous comment on 2011-09-22 15:01

Actually, I was still able to build it without that patch. I wonder what crazy things I do to my system…

Anonymous comment on 2011-09-22 14:56

@cybojanek: Thanks! I will see about adding that. I should probably also upgrade to 110.73, which was released four months ago. For some reason, I do not remember having any problem building on my machine recently; it must have been right before the 2.6->3.0 transition, though.
-bohanlon

Anonymous comment on 2011-09-22 14:45

The build system breaks on kernels 3.0+ ...Included is a patch, which has the original Dragonly patch, and I just added the 3.0* and 3.1* checking....Its a lazy fix
http://pastebin.com/ySAPeSfj
@bohanlon Thanks for maintaining! I need this package for class :-)

Anonymous comment on 2011-06-07 06:45

Updated my PKGBUILD: http://pastebin.com/NnrXXGSC
@bohanlon: it's ok that you keep maintaining it.

Anonymous comment on 2011-06-07 01:02

I should also note that I have not been able to replicate the build issues that others have had (on either x86_32 or x86_64), but if @borman's changes fix those for folks, that is great!

Anonymous comment on 2011-06-07 00:58

@borman: I like your changes. I started maintaining it because the original maintainer abandoned it; I only made minimal changes to keep it up to date, but a good refactoring would certainly be acceptable. They just released 110.43 a few weeks ago, so updating to that would be good. Do you want me to keep maintaining it and pull in the new version, or would you like to take charge?

Anonymous comment on 2010-12-12 12:48

After started fixing this PKGBUILD to make it work, i've done a lot of refactoring to it. Here's what i have come to: http://pastebin.com/Y1FhDkyS

Anonymous comment on 2010-12-03 10:25

@bohanlon Thanks for maintaining this package and being so responsive :)

Is there any way to use the auto-downloading script in config.tgz from here: http://www.smlnj.org/dist/working/110.72/index.html ? It seems like it might be able to simplify the installation steps in the PKGBUILD

Anonymous comment on 2010-11-30 17:18

@habitue01: Thanks; I actually got an x86_64 VM, and got a different error than you, so I will see what I can do to fix that.

Anonymous comment on 2010-11-30 17:18

@roy_hu: There should be an smlnj.sh added to /etc/profile.d that will take care of setting that path. You would have to logout and back in for that to take affect, though, so I should add something telling people to source that if they do not wish to do that. Thanks!

roy_hu commented on 2010-11-27 06:44

I thought sml would work out of the box. It didn't. You probably should prompt users to set SMLNJ_HOME=/usr/lib/smlnj

Anonymous comment on 2010-10-19 15:20

I'm getting this error trying to compile on x86_64 with multilib:

In file included from ../kernel/ml-options.c:9:0:
../include/ml-base.h:34:22: fatal error: ml-sizes.h: No such file or directory
compilation terminated.

Anonymous comment on 2010-10-19 13:35

Upgrade to 110.72. Please test on x86_64 and see how it works; I reënabled it in the PKGBUILD, since it should work with the multilib toolchain, however, I have not tested it on a 64-bit machine.

Rothon commented on 2010-10-01 03:07

It compiled and installed fine for me by just changing arch=(i686) to arch=(x86_64) in the PKGBUILD and compiling with multilib gcc.

Anonymous comment on 2010-08-11 03:25

Would it be possible to modify the PKGBUILD to handle x86_64? Apparently the gentoo guys got this working in this ebuild: http://gentoo-portage.com/AJAX/Ebuild/97013/View