# Cannot build Base: can't find file to patch

**URL:** https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952
**Category:** In Situ Support
**Created:** [May 28, 2019, 8:31pm UTC](https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952 "2019-05-28T20:31:38Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![tesari](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/e99b99/32.png) [@tesari](https://discourse.paraview.org/u/tesari)
#### Post date: [May 28, 2019, 8:31pm UTC](https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952/1 "2019-05-28T20:31:38Z")

</div>

Hi,

I successfully linked a code to Catalyst-v5.6.0-Base-Enable-Python-Essentials-Extras-Rendering-Base, but some writers, e.g. XMLHierarchicalBoxDataWriter and XMLUniformGridAMRWriter, are scrubbed away and not available in the catalyst editions. I am trying to build my extended edition, and to include these writers. As a first step I try to rebuild Base as it is. I made a copy of Base as myBase, and run catalyze.py, but it fails while applying patches (see below).

What do I miss here? Any help is highly appreciated.

Thanks,

Ted

[ews00734@Catalyst $] python catalyze.py -r /ascldap/users/tesari/projects/paraview -i Editions/myBase/ -o ~/projects/myBase

## Processing Editions/myBase/ patching file ParaViewCore/ClientServerCore/Core/CMakeLists.txt Hunk #1 FAILED at 34. Hunk #2 FAILED at 48. Hunk #3 FAILED at 108. 3 out of 3 hunks FAILED – saving rejects to file ParaViewCore/ClientServerCore/Core/CMakeLists.txt.rej can’t find file to patch at input line 33 Perhaps you used the wrong -p or --strip option? The text leading up to this was:

|diff --git a/ParaViewCore/ClientServerCore/Core/module.cmake b/ParaViewCore/ClientServerCore/Core/module.cmake  
|index f17c4df…f0db074 100644  
|— a/ParaViewCore/ClientServerCore/Core/module.cmake

| +++ b/ParaViewCore/ClientServerCore/Core/module.cmake |
| --- |

File to patch: ^CTraceback (most recent call last):  
File “catalyze.py”, line 418, in   
main()  
File “catalyze.py”, line 413, in main  
process(config)  
File “catalyze.py”, line 344, in process  
copy\_paths(config, manifest[‘modules’])  
File “catalyze.py”, line 214, in copy\_paths  
run\_patches(config, path\_entry)  
File “catalyze.py”, line 151, in run\_patches  
p.wait()  
File “/ascldap/users/tesari/local/python-2.7.16/lib/python2.7/subprocess.py”, line 1099, in wait  
pid, sts = \_eintr\_retry\_call(os.waitpid, self.pid, 0)  
File “/ascldap/users/tesari/local/python-2.7.16/lib/python2.7/subprocess.py”, line 125, in \_eintr\_retry\_call  
return func(\*args)  
KeyboardInterrupt

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.paraview.org/u/ben.boeckel)
#### Post date: [May 28, 2019, 8:33pm UTC](https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952/2 "2019-05-28T20:33:05Z")

</div>

Are you using `master`? Or a released 5.6.0?

---

<div class="post-metadata">

### Author: ![tesari](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/e99b99/32.png) [@tesari](https://discourse.paraview.org/u/tesari)
#### Post date: [May 28, 2019, 8:34pm UTC](https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952/3 "2019-05-28T20:34:34Z")

</div>

I pull from [gitlab.kitware.com/paraview/paraview.git](http://gitlab.kitware.com/paraview/paraview.git)

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.paraview.org/u/ben.boeckel)
#### Post date: [May 28, 2019, 8:39pm UTC](https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952/4 "2019-05-28T20:39:39Z")

</div>

`master` doesn’t support the `catalyze.py` scripts. See [https://gitlab.kitware.com/paraview/paraview/issues/18800](https://gitlab.kitware.com/paraview/paraview/issues/18800) for details. In the meantime, I suggest using the `release` branch to do `catalyze.py`-based builds.

---

<div class="post-metadata">

### Author: ![tesari](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/e99b99/32.png) [@tesari](https://discourse.paraview.org/u/tesari)
#### Post date: [May 28, 2019, 9:23pm UTC](https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952/5 "2019-05-28T21:23:36Z")

</div>

Thanks for the info. I checkout release, but now cmake cannot  
find vtkModuleAPI and vtkModuleMacros. Just to make sure, I did a  
fresh clone,

```auto
git clone --recursive ParaView
cd ParaView
git pull
git submodule update --init
git checkout --track -b release origin/release

```

```
  Still fails with the same error (see below). Could you advice,

```

please?

Thanks,

Ted

CMake Error at CMakeLists.txt:662 (include):

```
       include could not find load file:

         vtkModuleAPI

     CMake Error at CMakeLists.txt:663 (include):

       include could not find load file:

         vtkModuleMacros

     CMake Error at CMake/ParaViewModuleTop.cmake:44

```

(vtk\_add\_to\_module\_search\_path):

```
       Unknown CMake command "vtk_add_to_module_search_path".

     Call Stack (most recent call first):

       CMakeLists.txt:689 (include)
```

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.paraview.org/u/ben.boeckel)
#### Post date: [May 29, 2019, 12:15pm UTC](https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952/6 "2019-05-29T12:15:43Z")

</div>

The `submodule update --recursive --init` should be done after checking out ParaView’s `release` branch.

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [June 3, 2019, 12:45pm UTC](https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952/7 "2019-06-03T12:45:43Z")

</div>

We should inform better of this, we still have too many users failing this step.

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.paraview.org/u/ben.boeckel)
#### Post date: [June 3, 2019, 1:51pm UTC](https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952/8 "2019-06-03T13:51:54Z")

</div>

There’s code in the common-superbuild which detects out-of-date submodules. ParaView could copy it to detect it for VTK and the other submodules.

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [June 3, 2019, 1:55pm UTC](https://discourse.paraview.org/t/cannot-build-base-cant-find-file-to-patch/1952/9 "2019-06-03T13:55:37Z")

</div>

This is what I had in mind, yes.
