-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: ./scripts/build_als.sh fails on Mac Sequoia #1236
Comments
Hello there, This looks like a mismatch in the version of Python. Which Python version does your system have? You need Python 3.11 or newer to build langkit which is a dependency of ALS. |
This computer did have some old versions of Python which I have now deleted. However I still get:
|
It's likely that the lingering virtual env So it must be deleted, and then |
./scripts/build_als.sh doesn't seem to recreate ada_language_server/.venv:
|
Do you have a |
In PATH:
|
|
I cleaned up python aliases quite a lot and created symbolic links python an python3 to python3.13 in /usr/local/bin Roger@Rogers-MacBook-Air-2 ada_language_server % which python3 ./scripts/build_als.sh now fails with:
|
I don't understand some of the comments above. Perhaps it would help if @rogermc2 could say what ada_language_server source version he's using? I'm using the source archive from the 26.0.202412191 release, and in that archive |
I don't know which version of ada_language_server. I cloned it on 31 January 2025. Maybe 26.0.202412190 which is stated i the Changelog. I'll try 26.0.202412191 |
I tried source archive from the 26.0.202412191 release, but ./scripts/build_als.sh failed. Can't find Ada compiler? /opt/gcc-14.2.0-3-aarch64/bin/gnat |
Perhaps it’s because of using 26.0.202412190 is the pre-release, 26.0.202412191 is the release. The build script runs I’m using Homebrew’s python 3.11. I’ve been scratching around trying to get a build with a private build of GCC 15.0.1 (for reasons) and I don’t remember why I stopped using the source release and built from the repo (as documented). There was (at least!) one problem that’d need to be fixed (I privately reverted that commit, it took some doing to find the actual parent!) |
I probably used sudo out of desperation! I decided to try on another computer but didn't get very far:
|
I hope this won’t be annoying, but ...
You could look for an alternative to Finder, but the simplest way is to only use Terminal (or Emacs :-) to examine source code. You could get rid of all the check that you’re looking at the right files
remove them
check they’re gone
Or we could write a tool (in Ada) to do just this job. |
Never annoying! In conclusion, since I submitted this report, /System/Volumes/Data/ seems to have changed to /System/Volumes/Macintosh HD. At least in the Finder file directory systems of both my computers. Further addendum |
I thought I'd have another go but ./scripts/build_als.sh
|
Hello folks, I suspect that the
Then regarding indexes, up to about a month ago, the script was using a local Alire index to set up dependencies in a custom way. It no longer does that on master, so I would recommend switching to the But you will have to remove previously registered indexes. You should be able to do that like this:
Then to go back to the initial problem: the build script can't find The fact that Also I just realized that you used Homebrew to install Python. Looking at the documentation of the Python package we see this:
The last part about |
OK! Another attempt. As recommended, I cleaned up the alr indices then deleted the als directory, restarted the computer, cloned als from master, carefully followed the doc/build.md instructions. compilation of iconv_support.c failed gprbuild: *** compilation phase failed |
@rogermc2 - re: the C error messages - these happen because Xcode 16’s header files aren’t compatible with those expected by a compiler built against Xcode 15; see my note here. You say you’re using my gcc-14.2.0-3-aarch64, which has a fix for this issue, so why the errors? I think you’ve probably set up I’d recommend using |
Yes, alr toolchain did show gnat_native 14.2.1 as default.
Then:
I'm now on: |
I'm not sure this is really appropriate in @rogermc2's issue, but it doesn't seem right to open a new one just for this report. Someone suggested running with the
The decode isn't helpful (no line numbers, I suspect because no Building with GCC 15.0.1 20250126 I got GCC PR 118731. |
I think the issue with symbols is that |
@rogermc2 I am sorry that we cannot be of more help. It seems that you are running into environment issues. In my case, I am able to build locally on macOS 14.6.1, XCode 16.2 with a simplified version of
(You can skip the third step about |
It was surprisingly easy.
Before I spotted the reason why my builds finished with references to objcopy (2 above), I was getting |
Thanks eliericha. I git pulled ada_language_server and otherwise followed your steps but still get error: Command ["bash", "-x", "./scripts/build_als.sh", "build_langkit_raw"] exited with code 127. |
Environment
Bug Summary and Reproducer
Bug Summary: ./scripts/build_als.sh failed after Successfully installed Langkit-0.1.0:
Traceback (most recent call last):
File "/System/Volumes/Data/Ada_Source/ada_language_server/subprojects/langkit_support/manage.py", line 14, in
from langkit.packaging import NativeLibPackager
File "/System/Volumes/Data/Ada_Source/ada_language_server/subprojects/langkit_support/langkit/packaging.py", line 12, in
from langkit.utils import LibraryType
File "/System/Volumes/Data/Ada_Source/ada_language_server/subprojects/langkit_support/langkit/utils/init.py", line 341, in
from langkit.utils.text import *
File "/System/Volumes/Data/Ada_Source/ada_language_server/subprojects/langkit_support/langkit/utils/text.py", line 50, in
class Language(enum.StrEnum):
AttributeError: module 'enum' has no attribute 'StrEnum'
error: Command ["bash", "-x", "./scripts/build_als.sh", "build_langkit_raw"] exited with code 1
Steps to reproduce:In ada_language_server run ./scripts/build_als.s
Expected behavior:./scripts/build_als.sh runs to completion without errors
Configuration and Logs
Other VS Code Extensions
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: