Closed blackketter closed 10 months ago
Ugh, libffi! So annoying. I thought I fixed this, but I bet my env was dirty when I declared success.
Can you try brew install libffi
and try again for me?
Alas, I already had libffi installed, reinstalled it for good measure, but same behavior... (On a whim I also tried building under Rosetta and native, no help.)
Dang it, it was worth a shot. OK, I'll boot a fresh macOS VM and get this one for good (hopefully.)
Thanks! Let me know if I can help...
I just gave it a go and it worked on a fresh VM (by installing libffi with homebrew.) My process was:
git
) brew install pkg-config libffi
cd tulipcc/ports/macos
./build.sh
That made a working version of Tulip Desktop for me.
I notice that brew's libffi
is "keg-only" and installs (for me) into /opt/homebrew/opt/libffi
-- that's where ./build.sh
looks for it. Do you have libffi files in there, or did your homebrew put them somewhere else?
Apparently I had a half-arm/half-i386 version of brew running. Full upgrade to arm and it builds fine. Sorry for the false alarm. THANKS!
Hello, I'm having a libffi problem.
macOS Monterey 12.6.5
I installed via brew as instructed and I did the exports suggested to deal with the "keg only" install:
LDFLAGS=-L/usr/local/opt/libffi/lib CPPFLAGS=-I/usr/local/opt/libffi/include PKG_CONFIG_PATH=/usr/local/opt/libffi/lib/pkgconfig
But the build env can't find ffi.h:
douglas@FickleTight-BerraTyte macos % ./build.sh Use make V=1 or set BUILD_VERBOSE in your environment to increase build verbosity. GEN build-standard/genhdr/qstr.i.last modffi.c:32:10: fatal error: 'ffi.h' file not found
^~~~~~~
1 error generated.
Traceback (most recent call last):
File "/Users/douglas/Documents/tulipcc_git/tulipcc/ports/macos/../../py/makeqstrdefs.py", line 196, in
Going to reopen this to hopefully get Monterey build working for Desktop !
@drepetto - i created a Monterey VM and followed the instructions and had no issue compiling/running Tulip Desktop. I'm not sure why you did the "keg only" thing, I don't think you need to, I just did default brew install libffi
.
Here's what I did:
Maybe trash your homebrew install (or just libffi?) and try again if you can?
I didn't do the "keg only" on purpose, brew did that for me because it detected a native MacOS version. Then it gave the advice at the end to add exports.
Right, yeah --skip / remove the exports and try again.
Douglas was running Monterey on an intel (arch reports i386
, not x86_64
) and homebrew was in /usr/local
not /usr/local/homebrew
as it was on my iMac from 2020 running Monterey. I've updated that (and fixed a typo) in the Makefile for non-arm64 builds. I'll keep this open to see if others are still having this issue. Do let me know!
(Also, there's never a need to do the keg-only link command it suggests -- Tulip finds the libraries explicitly.)
Trying to build tulipcc for the first time on an M2 MacBook Air running latest Ventura with the following verbose error. Don't think I missed a step in the setup. Any suggestions?