Skip to content
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

Support LLVM 4.0 postfixed versions #5013

Merged
merged 1 commit into from Sep 21, 2017
Merged

Support LLVM 4.0 postfixed versions #5013

merged 1 commit into from Sep 21, 2017

Conversation

luislavena
Copy link
Contributor

Debian-based distributions allow you to install multiple versions of LLVM in parallel, allowing you to access them individually using postfixed llvm-config versions (ie llvm-config-3.8 or llvm-config-3.9).

Ubuntu (Xenial) added packages for LLVM 4.0 with -4.0 postfix (under llvm-4.0 package).

Crystal supports and uses 3.9 or 3.8, but no option for 4.0.

This change makes sure LLVM 4.0 is also tried first.

Before this change (with LLVM 4.0 installed):

$ make crystal
Using /usr/bin/llvm-config-3.8 [version=3.8.0]
...

$ bin/crystal --version
Using compiled compiler at `.build/crystal'
Crystal 0.23.0+177 [12ed6df] (2017-09-20)

LLVM: 3.8.0
Default target: x86_64-pc-linux-gnu

After this change (with LLVM 4.0 installed)

$ make crystal
Using /usr/bin/llvm-config-4.0 [version=4.0.0]
...

$ bin/crystal --version
Using compiled compiler at `.build/crystal'
Crystal 0.23.0+177 [12ed6df] (2017-09-20)

LLVM: 4.0.0
Default target: x86_64-pc-linux-gnu

Thank you for the continuous support and work on Crystal and looking forward your comments!
❤️ ❤️ ❤️

Debian-based distributions allow you to install multiple versions of LLVM
in parallel, allowing you to access them individually using postfixed
`llvm-config` versions (ie `llvm-config-3.8` or `llvm-config-3.9`).

Ubuntu (Xenial) added packages for LLVM 4.0 with `-4.0` postfix (under
`llvm-4.0` package).

Crystal supports and uses 3.9 or 3.8, but no option for 4.0.

This change makes sure LLVM 4.0 is also tried first.

Before this change (with LLVM 4.0 installed):

    $ make crystal
    Using /usr/bin/llvm-config-3.8 [version=3.8.0]
    ...

    $ bin/crystal --version
    Using compiled compiler at `.build/crystal'
    Crystal 0.23.0+177 [12ed6df] (2017-09-20)

    LLVM: 3.8.0
    Default target: x86_64-pc-linux-gnu

After this change (with LLVM 4.0 installed)

    $ make crystal
    Using /usr/bin/llvm-config-4.0 [version=4.0.0]
    ...

    $ bin/crystal --version
    Using compiled compiler at `.build/crystal'
    Crystal 0.23.0+177 [12ed6df] (2017-09-20)

    LLVM: 4.0.0
    Default target: x86_64-pc-linux-gnu
Copy link
Contributor

@ysbaddaden ysbaddaden left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! With LLVM5 released (candidate), LLVM4 is now the current stable, so yeah, we can default to this version.

@asterite
Copy link
Member

@luislavena Thank you! ❤️

@asterite asterite merged commit 02fca17 into crystal-lang:master Sep 21, 2017
@luislavena luislavena deleted the support-llvm-config-4.0 branch September 21, 2017 12:50
@asterite asterite added this to the Next milestone Sep 25, 2017
Vexatos added a commit to Vexatos/crystal that referenced this pull request Jan 4, 2018
RX14 pushed a commit that referenced this pull request Jan 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants