From e80453471504424d687d4db64ad637b6c6191132 Mon Sep 17 00:00:00 2001 From: Tonton Th Date: Thu, 23 Jan 2020 12:38:19 +0100 Subject: [PATCH] added -lz to ld flags (for Fedora ?) --- Makefile | 4 ++-- funcs/Makefile | 2 +- lib/Makefile | 2 +- tools/Makefile | 8 ++++++-- v4l2/Makefile | 2 +- 5 files changed, 11 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index 3d629b1..76a3444 100644 --- a/Makefile +++ b/Makefile @@ -11,12 +11,12 @@ all: essai #--------------------------------------------------------------- essai: essai.c libfloatimg.a floatimg.h Makefile - gcc $(COPT) $< $(LDOPT) -lpnglite -o $@ + gcc $(COPT) $< $(LDOPT) -lpnglite -lz -o $@ #--------------------------------------------------------------- TOTAR = *.[ch] Makefile *.sh *.txt \ - doc/*.tex doc/mkdoc.sh \ + doc/*.tex doc/mkdoc.sh doc/*.txt \ funcs/*.[ch] funcs/Makefile \ tools/*.[ch] tools/Makefile \ v4l2/*.[ch] v4l2/Makefile \ diff --git a/funcs/Makefile b/funcs/Makefile index c631a7e..55fa0fe 100644 --- a/funcs/Makefile +++ b/funcs/Makefile @@ -8,7 +8,7 @@ OBJS = fimg-png.o fimg-tiff.o misc-plots.o filtrage.o utils.o \ #--------------------------------------------------------------- t: t.c $(DEPS) ../libfloatimg.a - gcc $(COPT) $< ../libfloatimg.a -lnetpbm -lpnglite -lm -o $@ + gcc $(COPT) $< ../libfloatimg.a -lnetpbm -lpnglite -lz -lm -o $@ #--------------------------------------------------------------- diff --git a/lib/Makefile b/lib/Makefile index 92bc1a5..83d026a 100644 --- a/lib/Makefile +++ b/lib/Makefile @@ -16,7 +16,7 @@ AR=ar all: $(OBJS) ../libfloatimg.a t: t.c ../libfloatimg.a $(DEPS) - gcc $(COPT) $< ../libfloatimg.a -lpnglite -lm -o $@ + gcc $(COPT) $< ../libfloatimg.a -lpnglite -lz -lm -o $@ # -------------------------------------------- diff --git a/tools/Makefile b/tools/Makefile index 088d54f..bdf820a 100644 --- a/tools/Makefile +++ b/tools/Makefile @@ -30,8 +30,12 @@ fimg2pnm: fimg2pnm.c $(DEPS) gcc $(COPT) $< ../libfloatimg.a -o $@ fimg2png: fimg2png.c $(DEPS) - gcc $(COPT) $< ../libfloatimg.a -lpnglite -o $@ + gcc $(COPT) $< ../libfloatimg.a -lpnglite -lz -o $@ +# +# this tool require an external library +# http://la.buvette.org/devel/libimage/libimage.html +# addtga2fimg: addtga2fimg.c $(DEPS) gcc $(COPT) $< ../libfloatimg.a -limageSO -lm -o $@ @@ -41,5 +45,5 @@ addpnm2fimg: addpnm2fimg.c $(DEPS) # if "undefined reference to crc32" then "use -lz" png2fimg: png2fimg.c $(DEPS) - gcc $(COPT) $< ../libfloatimg.a -lpnglite -o $@ + gcc $(COPT) $< ../libfloatimg.a -lpnglite -lz -o $@ diff --git a/v4l2/Makefile b/v4l2/Makefile index 86cad48..e439bb2 100644 --- a/v4l2/Makefile +++ b/v4l2/Makefile @@ -18,7 +18,7 @@ v4l2_pr_structs.o: v4l2_pr_structs.c v4l2_pr_structs.h Makefile gcc ${COPT} -c $< grabvidseq: grabvidseq.c ${DEPS} rgb2fimg.o - gcc ${COPT} $< rgb2fimg.o ../libfloatimg.a -lm -lv4l2 -o $@ + gcc ${COPT} $< rgb2fimg.o ../libfloatimg.a -lz -lm -lv4l2 -o $@ video-infos: video-infos.c Makefile funcs.o v4l2_pr_structs.o gcc -Wall -g $< funcs.o v4l2_pr_structs.o -o $@