Take version information from CmakeLists.txt

Warning: potential incompatibility because version number is no longer stored in zint.h
This commit is contained in:
Robin Stuart 2020-11-22 11:29:45 +00:00
parent 44923349f3
commit 3eb31fe3f8
9 changed files with 45 additions and 13 deletions

View file

@ -2,6 +2,8 @@
project(zint)
configure_file(zintconfig.h.in zintconfig.h)
find_package(PNG)
set(zint_COMMON_SRCS common.c library.c large.c reedsol.c gs1.c eci.c general_field.c sjis.c gb2312.c gb18030.c)

View file

@ -47,6 +47,7 @@
#define NEON "0123456789"
#include "zint.h"
#include "zintconfig.h"
#include <stdlib.h>
#include <string.h>

View file

@ -110,11 +110,6 @@ extern "C" {
int warn_level;
};
#define ZINT_VERSION_MAJOR 2
#define ZINT_VERSION_MINOR 9
#define ZINT_VERSION_RELEASE 1
#define ZINT_VERSION_BUILD 9 /* Set to 0 before release, set to 9 after release */
/* Tbarcode 7 codes */
#define BARCODE_CODE11 1
#define BARCODE_C25STANDARD 2

5
backend/zintconfig.h.in Normal file
View file

@ -0,0 +1,5 @@
// the configured options and settings for libzint
#define ZINT_VERSION_MAJOR @ZINT_VERSION_MAJOR@
#define ZINT_VERSION_MINOR @ZINT_VERSION_MINOR@
#define ZINT_VERSION_RELEASE @ZINT_VERSION_RELEASE@
#define ZINT_VERSION_BUILD @ZINT_VERSION_BUILD@