This needs 'HB_PRE10' to be #defined for pre-Harbour 1.0.0 releases:
---
#if defined( __XHARBOUR__ )
/* code for xhb */
#endif
#if ! defined( __XHARBOUR__ ) && defined( __HARBOUR__ )
/* code for harbour */
#endif
#if ! defined( __XHARBOUR__ ) && defined( __HARBOUR__ ) && defined( HB_PRE10 )
/* code for harbour-pre-10x */
#endif
#if ! defined( __XHARBOUR__ ) && defined( __HARBOUR__ ) && ! defined( HB_PRE10 )
#if __HARBOUR__ >= 0x010000 && __HARBOUR__ < 0x010100
/* code for harbour-10x */
#endif
#endif
#if ! defined( __XHARBOUR__ ) && defined( __HARBOUR__ ) && ! defined( HB_PRE10 )
#if __HARBOUR__ >= 0x010100
/* code for harbour-11x-or-upper */
#endif
#endif
---
For to not make many changes in the code, it will be enough to write
in funcleto.h insead of
/* #define HARBOUR_VER_BEFORE_100 */
/* #define HARBOUR_VER_AFTER_101 */
the following:
/* #define HARBOUR_VER_BEFORE_100 */
#if ! defined( __XHARBOUR__ ) && defined( __HARBOUR__ ) && ! defined(
HARBOUR_VER_BEFORE_100 )
#if __HARBOUR__ >= 0x010100
#define HARBOUR_VER_AFTER_101
#endif
#endif
Thanks for the tip.
Things get simpler if you decide to drop support for very old Harbour versions:
---
I don't like to force people to get rid of old versions without really
serious reasons.
Regards, Alexander.
_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour