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

condformats_serialization_generate.py: fix include paths and fail on serious issues #10837

Merged
merged 1 commit into from Aug 24, 2015

Conversation

davidlt
Copy link
Contributor

@davidlt davidlt commented Aug 18, 2015

  • The script itself uses libClang for parsing C++ source files, thus we
    must use include files as seen by Clang. Note, this still points to GNU
    C++ standard library in GCC package, but there are special headers which
    are compiler specific, those are picked up from Clang package.
  • Print severity level names instead numbers.
  • Fail if there are 'Error' or/and 'Fatal' level diagnotic messages.
  • Remove obsolete ignore rules. They should not be triggered as long as
    include paths and arguments passed to libClang are valid.
  • This should resolve issue where get_statement could return None,
    because compiler couldn't do a correct job due to missing/wrong
    include paths or/and arguments.
  • Required for Clang 3.7.0.

Signed-off-by: David Abdurachmanov David.Abdurachmanov@cern.ch

…serious issues

- The script itself uses libClang for parsing C++ source files, thus we
must use include files as seen by Clang. Note, this still points to GNU
C++ standard library in GCC package, but there are special headers which
are compiler specific, those are picked up from Clang package.

- Print severity level names instead numbers.

- Fail if there are 'Error' or/and 'Fatal' level diagnotic messages.

- Remove obsolete ignore rules. They should not be triggered as long as
  include paths and arguments passed to libClang are valid.

- This should resolve issue where `get_statement` could return `None`,
  because compiler couldn't do a correct job due to missing/wrong
include paths or/and arguments.

- Required for Clang 3.7.0.

Signed-off-by: David Abdurachmanov <David.Abdurachmanov@cern.ch>
@davidlt
Copy link
Contributor Author

davidlt commented Aug 18, 2015

I requested some of this before. I finally bumped into this while testing Clang 3.7.0. We have to make sure that header is compilable with Clang and do not proceed if there are serious issues otherwise this has impact on translation unit. In particular case, Clang was not able to provide SourceRange, because one of SourceLocation was not valid. Because script never checks for get_statement() return this will cause the whole thing to crash and burn. Worked on the current Clang we have which is somewhere between 3.5.0 and 3.6.0 and Clang 3.7.0 RC2.

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @davidlt for CMSSW_7_6_X.

condformats_serialization_generate.py: fix include paths and fail on serious issues

It involves the following packages:

CondFormats/Serialization

@ggovi, @cmsbuild can you please review it and eventually sign? Thanks.
@apfeiffer1 this is something you requested to watch as well.
You can sign-off by replying to this message having '+1' in the first line of your reply.
You can reject by replying to this message having '-1' in the first line of your reply.
If you are a L2 or a release manager you can ask for tests by saying 'please test' in the first line of a comment.
@Degano you are the release manager for this.
You can merge this pull request by typing 'merge' in the first line of your comment.

@davidlt
Copy link
Contributor Author

davidlt commented Aug 18, 2015

Note, Jenkins testing is running, but it's useless because SCRAM or SCRAM generated Makefile does not check for modifications in condformats_serialization_generate.py, thus it does not checkout CondFormats. Test it locally by checking out git cms-addpkg CondFormats.

@cmsbuild
Copy link
Contributor

@cmsbuild
Copy link
Contributor

@davidlt
Copy link
Contributor Author

davidlt commented Aug 24, 2015

ping^1

@ggovi
Copy link
Contributor

ggovi commented Aug 24, 2015

+1

@cmsbuild
Copy link
Contributor

This pull request is fully signed and it will be integrated in one of the next CMSSW_7_6_X IBs (tests are also fine). This pull request requires discussion in the ORP meeting before it's merged. @davidlange6, @Degano, @smuzaffar

@davidlange6
Copy link
Contributor

+1

cmsbuild added a commit that referenced this pull request Aug 24, 2015
condformats_serialization_generate.py: fix include paths and fail on serious issues
@cmsbuild cmsbuild merged commit 04aedc4 into cms-sw:CMSSW_7_6_X Aug 24, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants