Coder Social home page Coder Social logo

Comments (15)

g-glowacki avatar g-glowacki commented on July 17, 2024 1

I manually replaced the PowerShell script, but it still doesn't work.

Start Clang Tidy

[ INFO ] WILL PROCESS PROJECTS: 
	xxx.vcxproj
[ INFO ] 1. PROCESSING PROJECT D:\xxx.vcxproj
Did not expect that
At C:\Users\gglowacki\AppData\Local\Microsoft\VisualStudio\14.0\Extensions\24rhmtuq.ud0\clang-build.ps1:802 char:9
+         throw "Did not expect that"
+         ~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : OperationStopped: (Did not expect that:String) [], RuntimeException
    + FullyQualifiedErrorId : Did not expect that
 

Done Clang Tidy

from clang-power-tools.

hero101111 avatar hero101111 commented on July 17, 2024 1

@g-glowacki Analyzing your sample files, I figured out what the problem is:
Your property sheets have item conditions written by hand, whereas clang-build.ps1 is currently looking for item conditions generated by Visual Studio (e.g. '$config|$platform'=='Debug|Win32').

We're working on enabling clang-build.ps1 to understand more complex conditions, such as yours.
Please keep in mind, however, that this is more than a trivial bug fix and will take some time to implement.

We'll keep you posted.
Thank you for your feedback.

from clang-power-tools.

cpp-red-lion avatar cpp-red-lion commented on July 17, 2024

Hi,

Project Include Directories should be automatically extracted from your *.vcxproj or VS property-sheets.
There is no need to configure them manually.
The global setting you are referring to was there for historical reasons and has been removed in version 1.4, to avoid further confusion.

from clang-power-tools.

cpp-red-lion avatar cpp-red-lion commented on July 17, 2024

If you have any issues with a specific project of yours (related to Include Directories) please attach a sample *.vcxproj reproducing the problem.

Thanks.

from clang-power-tools.

g-glowacki avatar g-glowacki commented on July 17, 2024

unfortunately the new version doesn't work for me... It gives error as mentioned in the beginning.
I installed 1.2.0, and it works fine. But i have to include dirs by hand.

from clang-power-tools.

cpp-red-lion avatar cpp-red-lion commented on July 17, 2024

I'm sorry about that.
Can you attach your project config (or a similar/simplified project) here, so we can debug your issue ?
That would really help. We are not able to reproduce this issue with any of our test projects...

from clang-power-tools.

g-glowacki avatar g-glowacki commented on July 17, 2024

unfortunately i can't, but our project is a big solution (about 50) projects with many references inside. But as i see the exception thrown inside the ps script means, that there can't be more then one

      if ($inheritedNodes.Count -gt 1)

I think You should consider looking here.

from clang-power-tools.

cpp-red-lion avatar cpp-red-lion commented on July 17, 2024

OK, good hint.
Will try that, but it's much more difficult to investigate blindly without a proper test case.
We'll dig into it and look for a way to patch it.

I'm counting on you to test the script afterwards to see if the problem was fixed.

from clang-power-tools.

g-glowacki avatar g-glowacki commented on July 17, 2024

with pleasure:)

from clang-power-tools.

hero101111 avatar hero101111 commented on July 17, 2024

HI @g-glowacki ,

There was a limitation in the PS scripts: it didn't allow for conditioned elements in property sheets.
It assumed the config/platform conditioning was handled in the .vcxproj xml.

My guess is that you have such conditioned elements in your property sheets.
I've just fixed this limitation.

Please test the latest clang-build.ps1 script from GitHub and let us know if it fixes your issue.


Note that this fix is currently live only for the github repository.
The latest Visual Studio extension (1.5.0) does not contain the fix. It will be included in the next release.

Until then, as a workaround, you can manually replace clang-build.ps1 in the VS extension directory with the latest from github.

To locate the extension directory search for clang-build.ps1 in %LOCALAPPDATA%

from clang-power-tools.

hero101111 avatar hero101111 commented on July 17, 2024

Did you restart Visual Studio after replacing the PS script?

from clang-power-tools.

g-glowacki avatar g-glowacki commented on July 17, 2024

Yes, i restarted it.

from clang-power-tools.

hero101111 avatar hero101111 commented on July 17, 2024

I'm afraid we're at a loss here. Can't spot any other potential cause for this issue.
We need a testable project. If you're unable to upload them here, you can send the project/prop sheets to gabriel dot diaconita at caphyon dot com

from clang-power-tools.

hero101111 avatar hero101111 commented on July 17, 2024

Hi @g-glowacki ,

We're happy to inform you that we've just released version 2.0 of Clang Power Tools.
It fixes the project xml data limitations that were at the core of this issue.

Your projects should now integrate successfully with Clang Power Tools.

The Visual Studio Extension should now update automatically to v2.0.
If you've disabled automatic updates you'll have to update the extension manually.

Thank you for feedback and patience.

Regards,
Gabriel.

from clang-power-tools.

g-glowacki avatar g-glowacki commented on July 17, 2024

I can confirm that it works fine now:) Thanks a lot!

from clang-power-tools.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.