mirror of
https://github.com/zint/zint
synced 2024-11-16 20:57:25 +13:00
Update version to 2.3.2
This commit is contained in:
@ -6,7 +6,7 @@
|
||||
# make clean cleans up a previous compilation and any object or editor files
|
||||
#
|
||||
|
||||
ZINT_VERSION:=-DZINT_VERSION=\"2.3.1\"
|
||||
ZINT_VERSION:=-DZINT_VERSION=\"2.3.2\"
|
||||
|
||||
|
||||
CC := gcc
|
||||
@ -33,7 +33,7 @@ libzint: code.c code128.c 2of5.c upcean.c medical.c telepen.c plessey.c postal.c
|
||||
$(CC) -Wall -fPIC $(CFLAGS) $(ZINT_VERSION) -c $(POSTAL)
|
||||
$(CC) -Wall -fPIC $(CFLAGS) $(ZINT_VERSION) -c $(TWODIM)
|
||||
$(CC) -Wall -fPIC $(CFLAGS) $(ZINT_VERSION) -c $(COMMON)
|
||||
$(CC) $(CFLAGS) $(ZINT_VERSION) -shared -Wl,-soname,libzint.so -o libzint.so.2.3.0 $(INCLUDE) $(COMMON_OBJ) $(ONEDIM_OBJ) $(TWODIM_OBJ) $(POSTAL_OBJ) $(LIBS)
|
||||
$(CC) $(CFLAGS) $(ZINT_VERSION) -shared -Wl,-soname,libzint.so -o libzint.so.2.3.2 $(INCLUDE) $(COMMON_OBJ) $(ONEDIM_OBJ) $(TWODIM_OBJ) $(POSTAL_OBJ) $(LIBS)
|
||||
ln -s libzint.so.* libzint.so
|
||||
|
||||
.PHONY: install uninstall clean dist
|
||||
|
@ -6,7 +6,7 @@
|
||||
# make clean cleans up a previous compilation and any object or editor files
|
||||
#
|
||||
|
||||
ZINT_VERSION:=-DZINT_VERSION=\"2.3.1\"
|
||||
ZINT_VERSION:=-DZINT_VERSION=\"2.3.2\"
|
||||
|
||||
|
||||
CC:= gcc
|
||||
|
@ -38,17 +38,6 @@
|
||||
#include "common.h"
|
||||
#include "dm200.h"
|
||||
|
||||
// simple checked response malloc
|
||||
static void *safemalloc(int n)
|
||||
{
|
||||
void *p = malloc(n);
|
||||
if (!p) {
|
||||
fprintf(stderr, "Malloc(%d) failed\n", n);
|
||||
exit(1);
|
||||
}
|
||||
return p;
|
||||
}
|
||||
|
||||
// Annex M placement alorithm low level
|
||||
static void ecc200placementbit(int *array, int NR, int NC, int r, int c, int p, char b)
|
||||
{
|
||||
@ -847,9 +836,9 @@ int data_matrix_200(struct zint_symbol *symbol, unsigned char source[], int leng
|
||||
int x, y, NC, NR, *places;
|
||||
NC = W - 2 * (W / FW);
|
||||
NR = H - 2 * (H / FH);
|
||||
places = (int*)safemalloc(NC * NR * sizeof(int));
|
||||
places = (int*)malloc(NC * NR * sizeof(int));
|
||||
ecc200placement(places, NR, NC);
|
||||
grid = (unsigned char*)safemalloc(W * H);
|
||||
grid = (unsigned char*)malloc(W * H);
|
||||
memset(grid, 0, W * H);
|
||||
for (y = 0; y < H; y += FH) {
|
||||
for (x = 0; x < W; x++)
|
||||
|
@ -36,6 +36,8 @@
|
||||
|
||||
The date of publication for these functions is 30 November 2006
|
||||
*/
|
||||
|
||||
/* Includes numerous bugfixes thanks to Pablo Orduña @ the PIRAmIDE project */
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
Reference in New Issue
Block a user