mirror of
https://git.code.sf.net/p/zint/code
synced 2025-12-23 04:47:03 +00:00
updated ZINT_VERSION
fixed build on TDM x86_64
This commit is contained in:
@@ -6,14 +6,18 @@
|
|||||||
# make clean cleans up a previous compilation and any object or editor files
|
# make clean cleans up a previous compilation and any object or editor files
|
||||||
#
|
#
|
||||||
|
|
||||||
ZINT_VERSION:=-DZINT_VERSION=\"2.3.2\"
|
ZINT_VERSION:=-DZINT_VERSION=\"2.4.1\"
|
||||||
|
|
||||||
|
|
||||||
CC:= gcc
|
CC:= gcc -m32
|
||||||
|
LD:= ld
|
||||||
AR:= ar rc
|
AR:= ar rc
|
||||||
RANLIB:= ranlib
|
RANLIB:= ranlib
|
||||||
INCLUDE:= -I/mingw/include
|
INCLUDE:= -I/mingw/include
|
||||||
CFLAGS:= -D_WIN32 -O2 -fms-extensions -mms-bitfields -fno-exceptions -fomit-frame-pointer -Wall
|
CFLAGS:= -O2 -fms-extensions -mms-bitfields -fno-exceptions -fomit-frame-pointer -Wall
|
||||||
|
LDFLAGS = -Wl,--major-image-version=2 -Wl,--minor-image-version=40
|
||||||
|
RC:= windres
|
||||||
|
RCFLAGS:= -v -F pe-i386 --define GCC_WINDRES
|
||||||
|
|
||||||
prefix := /mingw
|
prefix := /mingw
|
||||||
includedir := $(prefix)/include
|
includedir := $(prefix)/include
|
||||||
@@ -22,7 +26,9 @@ bindir := $(prefix)/bin
|
|||||||
DESTDIR :=
|
DESTDIR :=
|
||||||
APP:=zint
|
APP:=zint
|
||||||
DLL:=$(APP).dll
|
DLL:=$(APP).dll
|
||||||
|
DLLIMP:=lib$(DLL).a
|
||||||
STATLIB:=lib$(APP).a
|
STATLIB:=lib$(APP).a
|
||||||
|
TOOLLIB:=lib$(APP).la
|
||||||
|
|
||||||
COMMON_OBJ:= common.o render.o png.o library.o ps.o large.o reedsol.o gs1.o svg.o
|
COMMON_OBJ:= common.o render.o png.o library.o ps.o large.o reedsol.o gs1.o svg.o
|
||||||
ONEDIM_OBJ:= code.o code128.o 2of5.o upcean.o telepen.o medical.o plessey.o rss.o
|
ONEDIM_OBJ:= code.o code128.o 2of5.o upcean.o telepen.o medical.o plessey.o rss.o
|
||||||
@@ -32,7 +38,6 @@ TWODIM_OBJ:= code16k.o dmatrix.o pdf417.o qr.o maxicode.o composite.o aztec.o co
|
|||||||
LIB_OBJ:= $(COMMON_OBJ) $(ONEDIM_OBJ) $(TWODIM_OBJ) $(POSTAL_OBJ)
|
LIB_OBJ:= $(COMMON_OBJ) $(ONEDIM_OBJ) $(TWODIM_OBJ) $(POSTAL_OBJ)
|
||||||
DLL_OBJ:= $(LIB_OBJ:.o=.lo) dllversion.lo
|
DLL_OBJ:= $(LIB_OBJ:.o=.lo) dllversion.lo
|
||||||
|
|
||||||
|
|
||||||
ifeq ($(NO_PNG),true)
|
ifeq ($(NO_PNG),true)
|
||||||
DEFINES+= -DNO_PNG
|
DEFINES+= -DNO_PNG
|
||||||
else
|
else
|
||||||
@@ -43,6 +48,8 @@ endif
|
|||||||
LIBS+= -lm
|
LIBS+= -lm
|
||||||
|
|
||||||
all: $(DLL) $(STATLIB)
|
all: $(DLL) $(STATLIB)
|
||||||
|
DLL: $(DLL)
|
||||||
|
static: $(STATLIB)
|
||||||
|
|
||||||
%.lo:%.c
|
%.lo:%.c
|
||||||
@echo Compiling $< ...
|
@echo Compiling $< ...
|
||||||
@@ -52,9 +59,12 @@ all: $(DLL) $(STATLIB)
|
|||||||
@echo Compiling $< ...
|
@echo Compiling $< ...
|
||||||
$(CC) $(CFLAGS) $(DEFINES) $(ZINT_VERSION) -c -o $@ $<
|
$(CC) $(CFLAGS) $(DEFINES) $(ZINT_VERSION) -c -o $@ $<
|
||||||
|
|
||||||
$(DLL):$(DLL_OBJ)
|
libzint.o: libzint.rc
|
||||||
|
$(RC) $(RCFLAGS) -o $@ $<
|
||||||
|
|
||||||
|
$(DLL):$(DLL_OBJ) libzint.o
|
||||||
@echo Linking $@...
|
@echo Linking $@...
|
||||||
o2dll.sh -o $@ $(DLL_OBJ) $(LIBS)
|
$(CC) -shared -Wl,--out-implib,$(DLLIMP) $(LDFLAGS) -o $@ zint.def $(DLL_OBJ) libzint.o $(LIBS)
|
||||||
|
|
||||||
$(STATLIB): $(LIB_OBJ)
|
$(STATLIB): $(LIB_OBJ)
|
||||||
@echo Linking $@...
|
@echo Linking $@...
|
||||||
@@ -64,16 +74,20 @@ $(STATLIB): $(LIB_OBJ)
|
|||||||
.PHONY: install uninstall clean dist
|
.PHONY: install uninstall clean dist
|
||||||
|
|
||||||
install:
|
install:
|
||||||
cp -fp libzint.* $(DESTDIR)$(libdir)
|
cp -fp $(DLLIMP) $(DESTDIR)$(libdir)
|
||||||
|
cp -fp $(STATLIB) $(DESTDIR)$(libdir)
|
||||||
|
cp -fp $(TOOLLIB) $(DESTDIR)$(libdir)
|
||||||
cp -fp zint.h $(DESTDIR)$(includedir)/zint.h
|
cp -fp zint.h $(DESTDIR)$(includedir)/zint.h
|
||||||
cp -fp zint.dll $(DESTDIR)$(bindir)
|
cp -fp $(DLL) $(DESTDIR)$(bindir)
|
||||||
|
|
||||||
uninstall:
|
uninstall:
|
||||||
rm $(DESTDIR)$(libdir)/libzint.*
|
rm $(DESTDIR)$(libdir)/$(DLLIMP)
|
||||||
|
rm $(DESTDIR)$(libdir)/$(STATLIB)
|
||||||
|
rm $(DESTDIR)$(libdir)/$(TOOLLIB)
|
||||||
rm $(DESTDIR)$(includedir)/zint.h
|
rm $(DESTDIR)$(includedir)/zint.h
|
||||||
rm $(DESTDIR)$(bindir)/zint.dll
|
rm $(DESTDIR)$(bindir)/$(DLL)
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -f *.lib *.dll *.o *.a *~ *.res *.exe *.def *.lo *.bak
|
rm -f *.lib *.dll *.o *.a *~ *.res *.exe *.lo *.bak
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user