--modversion format

Troy A. Griffitts junkmail at crosswire.org
Tue Oct 25 04:07:56 PDT 2011

This may sound like a really odd request for pkg-config, but we're 
getting requests for a #if 'comparable' version number for our library. 
  e.g., given:

SWORD_VERSION := $(shell pkg-config --modversion sword)

It's not easy in code to do something like

#if SWORD_VERSION > 1.6.2

But it would be easy to do something like:

#if SWORD_VERSION > 0x010602

Is there any chance for some logic in pkg-config and a new option like 
--modversion0x to turn 1.6.2 formatted version numbers into 0x010602?

Just thought I'd ask.


More information about the pkg-config mailing list