-
-
Notifications
You must be signed in to change notification settings - Fork 102
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
Resolution of crystal dependency is hard tied to crystal
executable
#406
Comments
The |
Using the |
I think this is not a too big issue, many tools will reference just |
The discussion here and in #415 got derailed from the main point. We need to focus on For Crystal version there is the environment variable I think the first couple commits from #415 are good and do all that we need. Postinstall scripts won't pick up that configuration if they have
|
The implicit crystal dependency introduced in #395 calls
crystal env
to determine the crystal version it should treat as a dependency.It assumes you're installing dependencies for use with
crystal
binary in current PATH. But that might not at all be what I intend to do.If I want to build with a compiler that's not
crystal
,shards
might install wrong dependency versions when it implicitly usescrystal
as reference. For example, I usually have a couple different compiler executables in my PATH. Currently, the versions are not very different, so it's probably not going to cause many problems. But as soon as we move on after 1.0, it would be quite common to have different compiler versions available, saycrystal-1.0
andcrystal-1.1
to test against the different releases.Using
--ignore-crystal-version
would completely disable the crystal dependency and thus doesn't reproduce the same behaviour as when using a proper version.Currently, you would have to change
PATH
to point to the appropriate executable in order for shards to pick the correct version as dependency. That requires much effort and can easily cause issues by itself. We need a better solution.Ideas that come to mind are to specify either the crystal version directly or the path to the compiler that should be used as configuration option to shards.
A very neat solution would use the
CRYSTAL
enviornment value. That's typically used to make the compiler executable configurable in Makefiles. So it would integrate very well with that.The text was updated successfully, but these errors were encountered: