Well, a few issues with this.
Currently, I don't believe best practice is to install config.h because it
defines so many general things like VERSION and PACKAGE_NAME. Image including
two of these from different packages.
I was going to add the new version define to swversion.h, but considered it yet
another redundant place we need to change the package version when we release.
I believe pkg-config is still the ubiquitously supported means for checking
version, cflags, and libs (which are just as important as version for shared
devel packages) on just about every package installed on your box.
If we could agree to a way to generate this between your cmake build system and
auto tools then I would consider swapping out config.h (already packaged for
non-UNIX builds and included in swversion.cpp) for whatever mechanism we agree
on. But this still doesn't replace the necessary work of pkg-config to query
SWORD build flags. Remember, just because you compile and link doesn't mean
you've successfully build your app against the exact state of the headers when
the library was compiled and this can be dangerous.
Greg Hellings <greg.helli...@gmail.com> wrote:
>On Tue, Aug 6, 2013 at 6:29 AM, Troy A. Griffitts
><scr...@crosswire.org>wrote:
>
>> Windows frontends do not use a common packaging system to share a
>SWORD
>> devel installation.
>>
>
>Correct, but accessing this information at build time might still be
>useful. Could config.h.in be updated to include this information in
>addition to sword.pc? I have seen multiple libraries that will give
>defines
>either the way you've specified it or by using SWORD_MAJOR_VERSION,
>SWORD_MINOR_VERSION and SWORD_PATCH_VERSION. Then the information would
>be
>available to anyone who included the header files.
>
>--Greg
>
>
>>
>> Greg Hellings <greg.helli...@gmail.com> wrote:
>>>
>>> Relying on pkgconfig is not an entirely viable solution as it is
>not
>>> feasible to use on all target platforms - most notably Windows.
>>>
>>> --Greg
>>>
>>>
>>> On Mon, Aug 5, 2013 at 9:07 PM, Troy A. Griffitts
><scr...@crosswire.org>wrote:
>>>
>>>> Jaak,
>>>>
>>>> I've include -DSWORD_NUMVERSION as a pkg-config cflag directive. I
>hope
>>>> this is good enough for you. You can get this defined for you by
>including
>>>> this in your .pro file.
>>>>
>>>> CONFIG += link_pkgconfig
>>>> PKGCONFIG += sword
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> On 08/05/2013 10:12 PM, Jaak Ristioja wrote:
>>>>
>>>>> -----BEGIN PGP SIGNED MESSAGE-----
>>>>> Hash: SHA1
>>>>>
>>>>> Its not simple to port to Sword 1.7.0_rc2, because the Sword test
>>>>> magic in BibleTime #includes <ftptrans.h>, which is not available
>in
>>>>> 1.7. Hence compilation of that file fails. There's no way to do
>stuff
>>>>> like:
>>>>>
>>>>> #include <sword/version.h>
>>>>> #if SWORD_VERSION >= 0x010690
>>>>> #include <sword/remotetrans.h>
>>>>> typedef sword::FTPTransport SwordRemoteRransport;
>>>>> #else
>>>>> #include <sword/ftptrans.h>
>>>>> typedef sword::RemoteTransport SwordRemoteRransport;
>>>>> #endif
>>>>>
>>>>> in the .cpp file to fix this easily. So I have to write A LOT of
>CMake
>>>>> scripts to -D a SWORD_VERSION macro to pass to the compiler, or
>worse.
>>>>>
>>>>> To sum up, it is currently not reasonably feasible to write C++
>source
>>>>> code which compiles with both 1.6 and 1.7 versions of Sword. One
>needs
>>>>> a lot of support from the build system :(
>>>>>
>>>>> I again urge you to save us all some time and define a
>preprocessable
>>>>> SWORD_VERSION macro alike the *_VERSION macros boost or Qt define!
>If
>>>>> properly defined, this would at minimum halve the time needed to
>port
>>>>> existing versions of BibleTime to work with both 1.6 and 1.7.
>>>>>
>>>>> Blessings,
>>>>> Jaak
>>>>>
>>>>> PS: It would be wise to install a ftptrans.h file anyway, which
>>>>> includes a deprecation #warning, an #include "remotetrans.h" and a
>>>>> typedef aliasing sword::FTPTransport to sword::RemoteTransport.
>>>>>
>>>>> On 05.08.2013 22:01, Troy A. Griffitts wrote:
>>>>>
>>>>>> Well, It's been quiet since the release of RC2. Does this mean
>>>>>> things are working as expected? Could I get a few positives from
>>>>>> frontends if you've tried the bundle? Thank you.
>>>>>>
>>>>>> Troy
>>>>>>
>>>>>>
>>>>>>
>>>>>> On 08/03/2013 12:01 PM, Troy A. Griffitts wrote:
>>>>>>
>>>>>>> Thanks for all the testing and reports against RC1. Things have
>>>>>>> quieted down, so hopefully we have all the remaining items
>>>>>>> polished off. RC2 is available for your weekend pleasure.
>>>>>>>
>>>>>>>
>http://crosswire.org/sword/**alpha/alpha/sword-1.7.0RC2.**tar.gz<http://crosswire.org/sword/alpha/alpha/sword-1.7.0RC2.tar.gz>
>>>>>>>
>>>>>>> ______________________________**_________________ sword-devel
>>>>>>> mailing list: sword-devel@crosswire.org
>>>>>>>
>http://www.crosswire.org/**mailman/listinfo/sword-devel<http://www.crosswire.org/mailman/listinfo/sword-devel>
>>>>>>> Instructions to unsubscribe/change your settings at above page
>>>>>>>
>>>>>>
>>>>>> ______________________________**_________________ sword-devel
>mailing
>>>>>> list: sword-devel@crosswire.org
>>>>>>
>http://www.crosswire.org/**mailman/listinfo/sword-devel<http://www.crosswire.org/mailman/listinfo/sword-devel>Instructions
>>>>>> to unsubscribe/change your settings at above page
>>>>>>
>>>>> -----BEGIN PGP SIGNATURE-----
>>>>> Version: GnuPG v2.0.20 (GNU/Linux)
>>>>>
>>>>>
>iQgcBAEBAgAGBQJSAAcUAAoJEEqsYm**Et1rCO0Rs//**0uSHdvVI8C5VEWfgodW9uoW
>>>>>
>5XCRHUVR8IMMInNEv5rXXyNnZc+**UdViN4QJNYg5tjEOzxVtL6NTTR/**WWY0Uola2w
>>>>>
>Qj8NU3g6DgqVMXo7uFtEOuoQ6/**oyrKFLfiodMOcF3zMQZkBPWNc1KGPL**8OMUe7a9
>>>>>
>c5oiVqyg3LLrxGpgjTGKZWnEWawF9S**v9KgIwNyf4qILaStrDuF//**3AqYt4IHwdNL
>>>>>
>oHoZiZo7wtY4PCddJ0umEo0uF323Q0**xNX9iwM2bBNwFnGPSTpY7i3Oi5Tksb**7OJF
>>>>>
>HFnDMzdvo8ivVKEnwbnk3MUFCSBFL6**i3iyMeP6RCrPZw3wrFfMEbW6ufaghQ**5pqX
>>>>>
>MndwchusgJyN0KTTeEdMydd9xZ8i18**tUaiQZyYyPuiPwZ2uSf2vFIDrjt9TI**DuiU
>>>>>
>3uyk5ToWiWw9crc35PETh12iyaO7n9**ZVorYJwHNAYpQpCMkyJrdyt5Pvj18p**Eytt
>>>>>
>0Z8c9lxBn/+**m6yh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>>>
>rvcGe7PDvI2FxY50c2QgPGOqPvAsLl**2ahwCS0OMsS8WnJpIqYCzlGh+hZ/**crAxL5
>>>>>
>DTvANBhuUwaAANV2m8eoYd36R1naJy**P8TjngwOLNL6eIbIXFXylmWyjYMKt8**281S
>>>>>
>Qrod5OJNzLEhm5AW27NAi+**au5XjO4wH8/JU7f+**iCP6AikmDWFxzn6l2ozvFeuP0C
>>>>>
>o76ghOmieLFHulMHi5MKpb57bC2vDQ**MMIpU7SvzwcLDiDenZbaP3dIu3sj25**TUI5
>>>>>
>Lf7pM6pYBqsO0P6BtStCU3REtkcvOm**pv1js/**jQ9YyZRFnNEHOWQAzA8eSxpNWW3b
>>>>>
>gbJ44+**iIQ7npfPlEhhbPP0Wcdaps0EHRuiwn**MitSPM/5mW2VmuY3GzA728n2DhSh
>>>>> k+umEB2KHXSboFDxZJPW
>>>>> =31JW
>>>>> -----END PGP SIGNATURE-----
>>>>>
>>>>> ______________________________**_________________
>>>>> sword-devel mailing list: sword-devel@crosswire.org
>>>>>
>http://www.crosswire.org/**mailman/listinfo/sword-devel<http://www.crosswire.org/mailman/listinfo/sword-devel>
>>>>> Instructions to unsubscribe/change your settings at above page
>>>>>
>>>>
>>>>
>>>> ______________________________**_________________
>>>> sword-devel mailing list: sword-devel@crosswire.org
>>>>
>http://www.crosswire.org/**mailman/listinfo/sword-devel<http://www.crosswire.org/mailman/listinfo/sword-devel>
>>>> Instructions to unsubscribe/change your settings at above page
>>>>
>>>
>>> ------------------------------
>>>
>>> sword-devel mailing list: sword-devel@crosswire.org
>>> http://www.crosswire.org/mailman/listinfo/sword-devel
>>> Instructions to unsubscribe/change your settings at above page
>>>
>>>
>> --
>> Sent from my Android phone with K-9 Mail. Please excuse my brevity.
>>
>
>
>------------------------------------------------------------------------
>
>_______________________________________________
>sword-devel mailing list: sword-devel@crosswire.org
>http://www.crosswire.org/mailman/listinfo/sword-devel
>Instructions to unsubscribe/change your settings at above page
--
Sent from my Android phone with K-9 Mail. Please excuse my brevity.
_______________________________________________
sword-devel mailing list: sword-devel@crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page