Big Sur and M1 build, *nix compiling

115 views
Skip to first unread message

Tom Sturgeon

unread,
Dec 1, 2020, 7:11:19 PM12/1/20
to Racket Users

Racket 7.9 seg faults when starting DrRacket for the built versions.

The operating system is macos Big Sur on the Apple M1.

I tried downloading the source and rebuilding, but I get an error during the make phase.

Library/Developer/CommandLineTools/usr/bin/make cstartup_./racketcgc -cu ./src/startup-select.rkt echo "Bad startup choice, probably an error running startup-select.rkt" Bad startup choice, probably an error running startup-select.rkt exit 1



Matthew Flatt

unread,
Dec 1, 2020, 10:51:52 PM12/1/20
to Tom Sturgeon, Racket Users
There is some information here:

https://github.com/racket/racket/issues/3513

Mostly, though, it's "stay tuned" for at least a few more days.

Matthew Flatt

unread,
Dec 5, 2020, 2:46:49 PM12/5/20
to Racket Users, Tom Sturgeon
Racket now builds and runs on M1 Macs using a Git repo checkout. If all
goes well, snapshots will appear tomorrow at the Utah snapshot site
linked at

https://snapshot.racket-lang.org/

Meanwhile, I've uploaded an image here (link will last a few days):

https://www.cs.utah.edu/plt/snapshots/20201205-10ea287/installers/racket-7.9.0.10-aarch64-macosx-cs.dmg


Yes, the M1 MacBook Pro is pretty fast --- about x1.5 as fast as a 2018
i7 MacBook Pro for tasks that aren't primarily about loading files:

i7 M1
racket -n 0.08s 0.07s
racket -l racket 0.27s 0.25s
racket -cl racket/base 2.50s 1.60s
shootout mandelbrot.rkt 1.40s 0.94s
racket -l drracket ... -e '(exit)' 4.42s 2.79s
make base in fresh Git clone[1] 7m02s 5m02s
raco setup[2] 21m08s 14m48s

[1] After `make pb-fetch` to avoid network time
[2] After `make`, `raco setup --clean`, and `rm -r racket/docs`

Since we had an AArch64 backend for Chez Scheme, porting Racket CS was
mostly straightforward. Racket BS also works, but there's no AArch64
JIT in BC, so it can be slow. Some work was needed to conform to W^X
requirements (i.e., can't make memory both executable and writable at
the same time), but unlike other W^X environments that I've tried to
use, the OS provides good support for code-generating programs.
Building third-party libraries like Cairo went better than expected. I
spent most of my porting time and effort being confused about aspects
of code signing, but it seems reasonable enough in the end.

Matthew
> --
> You received this message because you are subscribed to the Google Groups
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email
> to racket-users...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/racket-users/20201201205146.2f5%40sirmail.smtp
> s.cs.utah.edu.
Reply all
Reply to author
Forward
0 new messages