# Build error: No such file or directory

**URL:** <https://root-forum.cern.ch/t/build-error-no-such-file-or-directory/49281>\
**Category:** ROOT\
**Tags:** build, root\
**Created:** [March 21, 2022, 6:28am UTC](https://root-forum.cern.ch/t/build-error-no-such-file-or-directory/49281 "2022-03-21T06:28:38Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Yeung](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/yeung/32/15884_2.png) [@Yeung](https://root-forum.cern.ch/u/Yeung)\
**Post date:** [March 21, 2022, 6:28am UTC](https://root-forum.cern.ch/t/build-error-no-such-file-or-directory/49281/1 "2022-03-21T06:28:38Z")

</div>

Hello,  
I am trying to build the master from source but the following error occurs.

```auto
Scanning dependencies of target RooFitHS3
[98%] Building CXX object roofit/hs3/CMakeFiles/RooFitHS3.dir/src/JSONParser.cxx.o
[98%] Building CXX object roofit/hs3/CMakeFiles/RooFitHS3.dir/src/RooJSONFactoryWSTool.cxx.o
[98%] Building CXX object roofit/hs3/CMakeFiles/RooFitHS3.dir/src/HistFactoryJSONTool.cxx.o
[98%] Building CXX object roofit/hs3/CMakeFiles/RooFitHS3.dir/src/JSONFactories_RooFitCore.cxx.o
[98%] Building CXX object roofit/hs3/CMakeFiles/RooFitHS3.dir/src/JSONFactories_HistFactory.cxx.o
[98%] Building CXX object roofit/hs3/CMakeFiles/RooFitHS3.dir/src/JSONInterface.cxx.o
/home/Downloads/root/roofit/hs3/src/HistFactoryJSONTool.cxx:16:10: fatal error: RooStats/HistFactory/Measurement.h: No such file or directory
   16 | #include "RooStats/HistFactory/Measurement.h"
      | ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
gmake[2]: *** [roofit/hs3/CMakeFiles/RooFitHS3.dir/src/HistFactoryJSONTool.cxx.o] Error 1
gmake[2]: *** Waiting for unfinished jobs....
/home/Downloads/root/roofit/hs3/src/JSONFactories_HistFactory.cxx:16:10: fatal error: RooStats/HistFactory/ParamHistFunc.h: No such file or directory
   16 | #include <RooStats/HistFactory/ParamHistFunc.h>
      | ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
gmake[2]: *** [roofit/hs3/CMakeFiles/RooFitHS3.dir/src/JSONFactories_HistFactory.cxx.o] Error 1
gmake[1]: *** [roofit/hs3/CMakeFiles/RooFitHS3.dir/all] Error 2
gmake: *** [all] Error 2

```

I have tried again on a machine with `libxml2-devel` and get a successful build. Thanks a lot!

* * *

_ROOT Version:_ 6.27/01  
_Platform:_ CentOS7.9  
_Compiler:_ gcc9.3.0

* * *

---

<div class="post-metadata">

**Author:** ![couet](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/couet/32/12037_2.png) [@couet](https://root-forum.cern.ch/u/couet)\
**Post date:** [March 21, 2022, 7:28am UTC](https://root-forum.cern.ch/t/build-error-no-such-file-or-directory/49281/2 "2022-03-21T07:28:22Z")

</div>

As it is a roostats/roofit error, @moneta mays have an idea about it.

---

<div class="post-metadata">

**Author:** ![eguiraud](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/eguiraud/32/32217_2.png) [@eguiraud](https://root-forum.cern.ch/u/eguiraud)\
**Post date:** [March 21, 2022, 9:00am UTC](https://root-forum.cern.ch/t/build-error-no-such-file-or-directory/49281/3 "2022-03-21T09:00:04Z")

</div>

Hi,  
sorry for the trouble, this is a known, recent bug in the build system fixed by [[RF] Build HistFactory also with xml=OFF, only excluding hist2workspace by guitargeek · Pull Request #10104 · root-project/root · GitHub](https://github.com/root-project/root/pull/10104) .

In the meanwhile installing xlm development packages on your machine should work around the problem (e.g. `libxml2-dev` on some Linux flavors).

cc: @jonas

Cheers,  
Enrico

---

<div class="post-metadata">

**Author:** ![system](https://root-forum.cern.ch/uploads/default/original/3X/e/f/efe4f24398fd8ffeb76bccb6ecc46d9d9c003376.png) [@system](https://root-forum.cern.ch/u/system)\
**Post date:** [April 4, 2022, 9:00am UTC](https://root-forum.cern.ch/t/build-error-no-such-file-or-directory/49281/4 "2022-04-04T09:00:08Z")

</div>

Closed on April 4, 2022, 9:00am UTC

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