Issues with ROOT installation in windows

Hi
trying to install the latest version 6.28.06 (well also tried .04 for what that counts) -precompiled- on Win11. I think I followed all instructions AFA dependencies are concerned, I think I have the right VS version (17.7.4), and I am using the developer powershell in VS to launch it (yes after sourcing the right bat file). I still get the following error, which was already reported in other threads without clear conclusion of what was going wrong. No sign of missing dependencies.
Thanks a lot in advance for any hint or clue, Roberto

input_line_1:1:10: fatal error: ‘new’ file not found
#include
^~~~~
Assertion failed: OldBuilder->DeferredDeclsToEmit.empty() && “Should have emitted all decls deferred to emit.”, file C:\build\ws\BUILDTYPE\Release\LABEL\windows64\V\6-28\root\interpreter\llvm\src\tools\clang\lib\CodeGen\ModuleBuilder.cpp, line 155

Hello,

Thanks for posting. Our windows expert will be back in a couple of days and we’ll follow this up if you did not fix the issue yourself already.

Best,
D

Hi,
thought I would send a ping. Just to not let the ticket expire, you know…
R

Hi,
Make sure you have installed the Desktop development with C++ workload, and that typing cl.exe prints something like:

**********************************************************************
** Visual Studio 2022 Developer PowerShell v17.7.4
** Copyright (c) 2022 Microsoft Corporation
**********************************************************************
PS C:\Program Files\Microsoft Visual Studio\2022\Community> cl.exe
Microsoft (R) C/C++ Optimizing Compiler Version 19.37.32824 for x64
Copyright (C) Microsoft Corporation.  All rights reserved.

usage: cl [ option... ] filename... [ /link linkoption... ]
PS C:\Program Files\Microsoft Visual Studio\2022\Community>

And if you work from Developer PowerShell for VS, you must call thisroot.ps1, and not thisroot.bat

PS C:\root-dev\build\x64\release> .\bin\thisroot.ps1
PS C:\root-dev\build\x64\release> root
   ------------------------------------------------------------------
  | Welcome to ROOT 6.29/01                        https://root.cern |
  | (c) 1995-2022, The ROOT Team; conception: R. Brun, F. Rademakers |
  | Built for win64 on Aug 30 2023, 10:33:46                         |
  | From heads/master@v6-29-01-2522-g42ff76a850                      |
  | With MSVC 19.37.32822.0                                          |
  | Try '.help'/'.?', '.demo', '.license', '.credits', '.quit'/'.q'  |
   ------------------------------------------------------------------

root [0] .q
PS C:\root-dev\build\x64\release>

Hi,
I am in the developer PS but something must be wrong in my setup.
Thanks

PS C:\Software\root_v6.28.06> .\bin\thisroot.ps1
.\bin\thisroot.ps1 : File C:\Software\root_v6.28.06\bin\thisroot.ps1 cannot be loaded. The file C:\Software\root_v6.28.06\bin\thisroot.ps1 is not digitally signed. You cannot run this script on the current system. For
more information about running scripts and setting execution policy, see about_Execution_Policies at https:/go.microsoft.com/fwlink/?LinkID=135170.

OK, so this is not a ROOT issue. Then you can either try to fix the PowerShell execution policies, or try to run from a regular Visual Studio Command Prompt

Just to let you know the version I am using in case you want to reproduce the issue.
Well if this is an issue of the VS execution policies, than it is also an issue for root installation on windows via VS. Will try some other ways. Thanks
image

Of course, in case you can reproduce the issue, it would be nice to update the documentation on how to install root on windows, even if this is not a root problem.
Thanks again

I just tried with root_v6.28.06.win64.vc17.zip on another computer (with VS 2019, but it doesn’t matter):

**********************************************************************
** Visual Studio 2019 Developer PowerShell v16.11.29
** Copyright (c) 2021 Microsoft Corporation
**********************************************************************
PS C:\Users\bellenot\source\repos> cd C:\Software\root_v6.28.06
PS C:\Software\root_v6.28.06> .\bin\thisroot.ps1
PS C:\Software\root_v6.28.06> root
   ------------------------------------------------------------------
  | Welcome to ROOT 6.28/06                        https://root.cern |
  | (c) 1995-2023, The ROOT Team; conception: R. Brun, F. Rademakers |
  | Built for win64 on Aug 28 2023, 11:29:15                         |
  | From tags/v6-28-06@v6-28-06                                      |
  | With MSVC 19.32.31332.0                                          |
  | Try '.help'/'.?', '.demo', '.license', '.credits', '.quit'/'.q'  |
   ------------------------------------------------------------------

root [0]

So I can’t reproduce the issue. How did you install ROOT?

Hi, thanks Bertrand.
I installed as explained in Installing ROOT - ROOT and then Releases - ROOT, by choosing the latest release for Win, the right architecture, the right VS version. The exe, IIRC. Good to know you cannot reproduce it, this is helpful to me. Do not waste anymore time, now I know I must have made something weird in my VS install, rather. I am reinstalling everything on the VS side, including C++ and Python in the development kit, and will try again. Will post again in case this persists and do not manage to debug myself. Thanks

1 Like

Hi again.
I am writing to close the thread and maybe give some useful feedback? After full reinstallation it works, but only by executing the bat script, in both ways (powershell and command prompt). “Executing” the ps1 file still gives authorization issues for me in the PS prompt.
If you do not have any further question, I guess you can close this thread. And thanks for your time.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.