diff --git a/Makefile b/Makefile index 1fb1411..e60ad49 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ # a look to the 'build.sh' script ! # #################################################### -COPT = -Wall -fpic -g -pg -no-pie -DDEBUG_LEVEL=0 +COPT = -Wall -Wextra -fpic -g -pg -no-pie -DDEBUG_LEVEL=0 LDOPT = libfloatimg.a -pg -lm all: essai diff --git a/experiment/Makefile b/experiment/Makefile index 0dd4f03..ff6a6a6 100644 --- a/experiment/Makefile +++ b/experiment/Makefile @@ -3,7 +3,7 @@ #  some ugly experiments, do not use in production # -COPT = -Wall -fpic -g -DDEBUG_LEVEL=1 -lm +COPT = -Wall -Wextra -fpic -g -DDEBUG_LEVEL=1 -lm DEPS = ../floatimg.h ../libfloatimg.a Makefile LIBS = ../libfloatimg.a -ltiff -lpnglite -lcfitsio -lm diff --git a/experiment/muxplanes.c b/experiment/muxplanes.c index eca36f0..f52b0d5 100644 --- a/experiment/muxplanes.c +++ b/experiment/muxplanes.c @@ -11,7 +11,7 @@ int verbosity; -/* ---------------------------------------------- ~~~~~~~~~~~~~~~~ */ +/* --------------------------------------------------------------- */ int triplane_muxer(FloatImg *sr, FloatImg *sg, FloatImg *sb, FloatImg *dst, int flages) @@ -40,7 +40,7 @@ memcpy(dst->B, sb->B, sz); return 0; } -/* ---------------------------------------------- ~~~~~~~~~~~~~~~~ */ +/* --------------------------------------------------------------- */ int try_this_muxplane(char *fr, char *fg, char *fb, char *dst, int flags) { int foo; @@ -72,14 +72,18 @@ if (foo) { return foo; } -fimg_export_picture(&dest, dst, 0); +foo = fimg_export_picture(&dest, dst, 0); +if (foo) { + fprintf(stderr, "%s: err %d exporting to %s\n", __func__, foo, dst); + return foo; + } fimg_destroy(&imr); fimg_destroy(&img); -fimg_destroy(&imr); fimg_destroy(&dest); +fimg_destroy(&imb); fimg_destroy(&dest); return 0; } -/* ---------------------------------------------- ~~~~~~~~~~~~~~~~ */ +/* --------------------------------------------------------------- */ int main(int argc, char *argv[]) { int foo; @@ -90,6 +94,11 @@ if (5 != argc) { return 1; } +/* + * and now, we have to decipher options on the + * command line. + */ + foo = try_this_muxplane(argv[1], argv[2], argv[3], argv[4], 0); if (foo) { fprintf(stderr, "oups %d\n", foo); @@ -98,4 +107,4 @@ if (foo) { return 0; } -/* ---------------------------------------------- ~~~~~~~~~~~~~~~~ */ +/* --------------------------------------------------------------- */ diff --git a/funcs/Makefile b/funcs/Makefile index 400aa90..584edc8 100644 --- a/funcs/Makefile +++ b/funcs/Makefile @@ -3,7 +3,7 @@ # Please, use the 'Gloabl.makefile' system ! -COPT = -Wall -fpic -g -no-pie -DDEBUG_LEVEL=0 +COPT = -Wall -Wextra -fpic -g -no-pie -DDEBUG_LEVEL=0 DEPS = ../floatimg.h Makefile OBJS = fimg-png.o fimg-tiff.o misc-plots.o filtrage.o utils.o \ diff --git a/lib/Makefile b/lib/Makefile index 0f3dfea..7a9a06f 100644 --- a/lib/Makefile +++ b/lib/Makefile @@ -2,7 +2,7 @@ # building the base library # -COPT = -Wall -fpic -g -no-pie -DDEBUG_LEVEL=0 +COPT = -Wall -Wextra -fpic -g -no-pie -DDEBUG_LEVEL=0 OBJS = fimg-core.o fimg-pnm.o fimg-file.o fimg-math.o \ fimg-timers.o operators.o fimg-2gray.o \ diff --git a/tools/Makefile b/tools/Makefile index 15c0db8..b16889f 100644 --- a/tools/Makefile +++ b/tools/Makefile @@ -5,7 +5,7 @@ # PLEASE ! update to the 'Global.makefile' concept ! # -COPT = -Wall -fpic -g -DDEBUG_LEVEL=0 +COPT = -Wall -Wextra -fpic -g -DDEBUG_LEVEL=0 DEPS = ../floatimg.h ../libfloatimg.a Makefile # ----------