Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fpm install does not copy c/c++ headers to the installation folder #996

Open
perazz opened this issue Feb 14, 2024 · 2 comments
Open

fpm install does not copy c/c++ headers to the installation folder #996

perazz opened this issue Feb 14, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@perazz
Copy link
Contributor

perazz commented Feb 14, 2024

Description

If I build a Fortran library that has an ISO C binding, and I provide C/C++ headers as a companion then I would like them to be shipped with the static library, so whoever wants to use said library have the whole solution. Currently, only Fortran module (.mod) files are shipped in library.include-dir.

Possible Solution

As a first step, let's address C/C++ headers from library.src-dir only. This way, there is no need to handle nested folders the headers may need. fpm should just parse them, include them in the list of installed files and copy them to library.include-dir.

Additional Information

An example can be seen running fpm install with fitpack.

@perazz perazz added the enhancement New feature or request label Feb 14, 2024
@MilanSkocic
Copy link

It would be convenient if fpm could install the C headers along the Fortran headers. Currently, I use a workaround with a makefile.

@rouson
Copy link
Contributor

rouson commented Aug 7, 2024

Installing header files would be very useful in the Assert repository, where I'm introducing the option to call a C-like assert procedure that via a macro in a .h header file. This facilitates completely eliminating the call for production builds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants