From: paul <paul@inktvis.org>
To: guile-user@gnu.org
Subject: Re: Difficulty integrating with Swift/Objective-C
Date: Thu, 09 Sep 2021 09:59:03 +1000 [thread overview]
Message-ID: <m28s06mxfc.fsf@inktvis.org> (raw)
In-Reply-To: <m2sfyjmudv.fsf@inktvis.org>
I wanted to follow up about another thing:
On 2021-09-05 at 16:03 AEST, quoth paul <paul@inktvis.org>:
> I had some difficulty getting my app to compile against Guile,
> but i eventually managed to link against a version of Guile
> installed with Homebrew (guile: stable 3.0.7 (bottled)), however
> when trying to boot it up i seemed to run into the same issue
> described by Jeffrey Walton [1]. My app would boot, and as soon
> as it hit the Guile initialisation calls, it would error out as
> follows:
>
> allocating JIT code buffer failed: Permission denied
> jit.c:5873: fatal: assertion failed
>
> While the other person seems to imply the problem is with
> Apple's M1 silicon, i'm actually running an older machine (2.9
> GHz Dual-Core Intel Core i5, macOS 11.5.2). I then managed to
> get further by downloading the Guile release tarball version
> 3.0.7 and and building with `./configure --enable-jit=no`;>
>
> [...]
>
> 1. https://mail.gnu.org/archive/html/bug-guile/2021-03/msg00012.html
It turned out that the JIT issue was _also_ PEBKAC i am glad to
report. Completely by accident i happened upon some settings in
the Xcode project of my app, under the Target > Signing &
Capabilities > Hardened Runtime options. One has to enable the
following two items:
* Allow execution of JIT-compiled code
* Allow unsigned executable memory
Those two settings correspond to entries in the
<myapp>.entitlements file as follows:
<dict>
<key>com.apple.security.cs.allow-jit</key>
<true/>
<key>com.apple.security.cs.allow-unsigned-executable-memory</key>
<true/>
</dict>
Now, the app is able to build and run successfully against the
Homebrew-packaged version of Guile - super convenient!
I thought i'd post my findings in case someone else hits these
issues in the future. Or should i contribute a section to a
README somewhere, so that folks don't have to laboriously work
this out for themselves every time?
Cheers,
p.
next prev parent reply other threads:[~2021-09-08 23:59 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-05 6:03 Difficulty integrating with Swift/Objective-C paul
2021-09-05 8:26 ` Taylan Kammer
2021-09-05 9:35 ` paul
2021-09-06 10:21 ` paul
2021-09-06 13:11 ` Taylan Kammer
2021-09-05 10:56 ` Chris Vine
2021-09-06 10:26 ` paul
2021-09-06 16:28 ` Chris Vine
2021-09-08 23:59 ` paul [this message]
2021-09-28 20:22 ` Aleix Conchillo Flaqué
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m28s06mxfc.fsf@inktvis.org \
--to=paul@inktvis.org \
--cc=guile-user@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).