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

Makefile: Use Clang CFLAGS when running analyzegc #50002

Merged
merged 1 commit into from
May 31, 2023

Conversation

topolarity
Copy link
Member

@topolarity topolarity commented May 30, 2023

I believe it's supported to build the analysis plugin with GCC, but the flags we actually run it with need to match Clang.

@topolarity topolarity changed the title Makefile: Error when building analyzegc with GCC Makefile: Use Clang CFLAGS when running analyzegc May 30, 2023
@topolarity
Copy link
Member Author

Changed direction here.

Instead of removing support for building analyzegc with GCC, this updates the Makefile to use the Clang CFLAGS only when running Clang with the GC analyzer plugin.

Copy link
Sponsor Member

@staticfloat staticfloat left a comment

Choose a reason for hiding this comment

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

I think I do actually like splitting the CFLAGS by compiler type

Copy link
Sponsor Member

@vtjnash vtjnash left a comment

Choose a reason for hiding this comment

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

SGTM

It's supported to build the analysis plugin with GCC, but the flags we
actually run it with need to match Clang.
@inkydragon
Copy link
Sponsor Member

CI error seems related
analyzegc

make: Entering directory '/cache/build/default-amdci5-2/julialang/julia-master/src'
    ANALYZE src/clang-sa-llvm-pass-helpers
In file included from /cache/build/default-amdci5-2/julialang/julia-master/src/llvm-pass-helpers.cpp:8:
/cache/build/default-amdci5-2/julialang/julia-master/src/llvm-version.h:5:10: fatal error: 'platform.h' file not found
#include "platform.h"
         ^~~~~~~~~~~~
1 error generated.

https://buildkite.com/julialang/julia-master/builds/24396#01886e4e-9f55-48ef-be00-a2a0cfde28d5/846-982

@inkydragon inkydragon added the building Build system, or building Julia or its dependencies label May 31, 2023
@topolarity topolarity force-pushed the clangsa-gcc-error branch 2 times, most recently from 6964e0e to c3a08fe Compare May 31, 2023 15:56
@topolarity
Copy link
Member Author

Should be passing CI now - Would be good to get a re-review from @staticfloat for the new changes

This scheme is not ideal, since by convention we update our JCFLAGs etc. in many places after they are initialized in Make.inc, but I think the important flag updates have all been included now.

@staticfloat staticfloat merged commit 28630ee into JuliaLang:master May 31, 2023
@topolarity topolarity deleted the clangsa-gcc-error branch May 31, 2023 23:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
building Build system, or building Julia or its dependencies
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants