Register gmp with pkg-config

Niels Möller nisse at
Thu Jun 16 05:31:28 UTC 2016

Irina Gossmann <irina.gossmann at> writes:

> Is there any reason for not including a .pc file with gmp? Since it's not
> registered with pkg-config, code depending on it won't build without some
> addition fiddling (I'm on Linux and OSX, not sure if/how it works
> differently on other platforms).

I guess the .pc file has to be generated by configure, to get file names
right. In a different project, I did it like this:

(There might be some helpers with libtool or automake; I don't know
those tools too well).

pkg-config support should also be documentated, somewhere close to the
section (generated from

> If you have a way of accepting contributions from outside, I can contribute
> a pkg-config file. Couldn't find a howto for contributors on the website,
> would've sent a patch directly otherwise.

Please send patches to this list. For non-trivial changes, we ask for a
Free Software Foundation copyright assignment.


Niels Möller. PGP-encrypted email is preferred. Keyid C0B98E26.
Internet email is subject to wholesale government surveillance.

More information about the gmp-devel mailing list