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

Build compiler-rt/builtins with MSVC #29233

Merged
merged 2 commits into from
Oct 28, 2015
Merged

Build compiler-rt/builtins with MSVC #29233

merged 2 commits into from
Oct 28, 2015

Conversation

angelsl
Copy link
Contributor

@angelsl angelsl commented Oct 22, 2015

Build compiler-rt/builtins with MSVC.

r? @alexcrichton

@rust-highfive
Copy link
Collaborator

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @alexcrichton (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. The way Github handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see the contribution instructions for more information.

@angelsl
Copy link
Contributor Author

angelsl commented Oct 22, 2015

cc: @retep998


# If the clang isn't already enabled, check for GCC, and if it is missing, turn
# on clang as a backup.
if [ -z "$CFG_ENABLE_CLANG" -a -z "$CFG_MSVC_ROOT"]
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This line was changed.

@alexcrichton
Copy link
Member

This'll need to update the compiler-rt submodule to land I think, and I've pushed https://github.com/rust-lang/compiler-rt/tree/rust-2015-10-23 which should have the most recent tip (which I think has the various patches of ours merged?)

@@ -856,230 +856,6 @@ then
putvar CFG_LOCAL_RUST_ROOT
fi

# Force bitrig to build with clang; gcc doesn't like us there
Copy link
Member

Choose a reason for hiding this comment

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

In the future, it's useful for large code movement like this to be split out into a separate commit so the changes to it can be reviewed separately, but it's fine for now

Copy link
Member

Choose a reason for hiding this comment

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

Although actually, could we avoid all this movement for now? I think the logic here is actually that if any triple is not MSVC then we need to look for gcc, but this looks like the logic is that if any triple is MSVC then we don't require gcc

@angelsl
Copy link
Contributor Author

angelsl commented Oct 23, 2015

Whoops. Didn't see your comments. Hold on.

@angelsl
Copy link
Contributor Author

angelsl commented Oct 23, 2015

@alexcrichton

OK, I've omitted all the skip-GCC/Clang-if-MSVC changes for now.

I'd like to keep the ability to build using a prebuilt LLVM though.

Also, the compiler-rt branch you pushed doesn't seem to have all (or any?) of the Rust-specific changes — triple.mk which we use to build on automake is missing. (It's also missing on the 2015-08-30 branch.)

Anyway, the MSVC build hasn't been enabled upstream yet; the last change needed is this line.

@alexcrichton
Copy link
Member

@bors: r+ f4ed46e822df792cd6599d06169400cc047e869a

Thanks @angelsl!

@bors
Copy link
Contributor

bors commented Oct 26, 2015

⌛ Testing commit f4ed46e with merge 4078d02...

@bors
Copy link
Contributor

bors commented Oct 26, 2015

💔 Test failed - auto-linux-32-opt

@angelsl
Copy link
Contributor Author

angelsl commented Oct 26, 2015

Sigh, I wonder what changed that the autotools build with GCC breaks.

@alexcrichton I'll fix this tomorrow. I expect it's just -fno-builtin or -ffreestanding ...

@angelsl
Copy link
Contributor Author

angelsl commented Oct 27, 2015

@alexcrichton

I hope chomping -Werror for this is OK. There's not really any other way to fix it unfortunately, unless you all are willing to move to CMake on Linux too (the build works fine there, at least on GCC 5.2.0 on x86_64, because the offending files aren't compiled it seems).

I don't even know why GCC is complaining. I checked the builtin's signature in libgcc and they match.

It should work now.

@alexcrichton
Copy link
Member

@bors: r+ 12150e3f1077865e56694d92ff0f0b735a2e134b

@bors
Copy link
Contributor

bors commented Oct 27, 2015

⌛ Testing commit 12150e3 with merge 905bb4c...

@bors
Copy link
Contributor

bors commented Oct 27, 2015

💔 Test failed - auto-linux-64-x-android-t

@angelsl
Copy link
Contributor Author

angelsl commented Oct 27, 2015

@alexcrichton

OK, I've fixed the regressions on FreeBSD and Android.

PR on compiler-rt.

@alexcrichton
Copy link
Member

@bors: r+ c31537e9ac0f1f365686771553276cbf46ebc1e1

@bors
Copy link
Contributor

bors commented Oct 28, 2015

⌛ Testing commit c31537e with merge 8592f17...

@retep998
Copy link
Member

I'd like to point out travis indicates this PR broke make tidy.

@bors
Copy link
Contributor

bors commented Oct 28, 2015

💔 Test failed - auto-linux-cross-opt

@angelsl
Copy link
Contributor Author

angelsl commented Oct 28, 2015

@retep998

I'd like to point out travis indicates this PR broke make tidy.

The build broke because my commits to compiler-rt had not been merged yet. Git was unable to checkout a nonexistent refspec.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
@angelsl
Copy link
Contributor Author

angelsl commented Oct 28, 2015

@alexcrichton

Fixed regressions on AArch64, MIPS and MIPSEL.

Couldn't find a binary cross-compiler for MIPS unfortunately. I'll look into building our own one day.. sigh. I disabled emutls on MIPS.

PR on compiler-rt.

@alexcrichton
Copy link
Member

@bors: r+ 6e61c6f

@bors
Copy link
Contributor

bors commented Oct 28, 2015

🙀 6e61c6f is not a valid commit SHA. Please try again with b09e8f5.

@alexcrichton
Copy link
Member

@bors: r+ b09e8f5

@bors
Copy link
Contributor

bors commented Oct 28, 2015

⌛ Testing commit b09e8f5 with merge e3f6a56...

bors added a commit that referenced this pull request Oct 28, 2015

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Build compiler-rt/builtins with MSVC.

r? @alexcrichton
@bors bors merged commit b09e8f5 into rust-lang:master Oct 28, 2015
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.

5 participants