apadana
apadana

Reputation: 722

pkg-config: the correct usage of Requires.private field

This is the first time I'm creating a .pc file, and I'm facing an issue. The .pc file is created by a makefile when compiling and installing a library. The issue I have is related to Requires.private field. The library internally uses some other libraries. On some systems they are installed by the package installer of the operating system and they have a .pc file. On some other systems, they don't have a .pc file (for example, when compiled from source code and used locally).

On the other hand, I'm not sure if the name of the .pc files of the dependencies are the same on all systems. On one system it may be ompi.pc, and on another system it might be openmpi.pc.

Considering these, how should the field Requires.private be used?

Currently, the makefile produces Requires.private: mpi gsl hdf5. On Ubuntu it is OK, but on openSUSE pkg-config --cflags mylibname shows an error that it can't find mpi.pc.

Upvotes: 0

Views: 34

Answers (0)

Related Questions