# Header files are not copied when install GROMACS 2022

**URL:** <https://gromacs.bioexcel.eu/t/header-files-are-not-copied-when-install-gromacs-2022/4843>\
**Category:** User discussions\
**Tags:** installation-error\
**Created:** [September 23, 2022, 5:17am UTC](https://gromacs.bioexcel.eu/t/header-files-are-not-copied-when-install-gromacs-2022/4843 "2022-09-23T05:17:54Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![zwyolo](https://avatars.discourse-cdn.com/v4/letter/z/e8c25b/32.png) [@zwyolo](https://gromacs.bioexcel.eu/u/zwyolo)\
**Post date:** [September 23, 2022, 5:17am UTC](https://gromacs.bioexcel.eu/t/header-files-are-not-copied-when-install-gromacs-2022/4843/1 "2022-09-23T05:17:54Z")

</div>

GROMACS version: 2022.1  
GROMACS modification: No

Hi everyone,

I tried to compile my own trajectory analysis program based on GROMACS 2022.1, and I tried to compile the template.cpp in

> share/template/template.cpp

first. And it seems that due to the header files are not copied/installed to

> include/gromacs

where GROMACS installed, so when I compiled template.cpp using

> make -f Makefile.pkg

it prompted an error said that

> **fatal error:** gromacs/trajectoryanalysis.h: No such file or directory

Does anyone know how to resolve this problem in this version? because it works when I use GROMACS 2019 or the older version.

Thanks  
Wei

---

<div class="post-metadata">

**Author:** ![linuxfreak](https://avatars.discourse-cdn.com/v4/letter/l/a9adbd/32.png) [@linuxfreak](https://gromacs.bioexcel.eu/u/linuxfreak)\
**Post date:** [April 2, 2024, 11:47am UTC](https://gromacs.bioexcel.eu/t/header-files-are-not-copied-when-install-gromacs-2022/4843/2 "2024-04-02T11:47:07Z")

</div>

Hi,

I had the same problem. You need to set GMX\_INSTALL\_LEGACY\_API to ON and then “make install” will install the header files needed to use the template.

Best,  
Kamil
