surveiller les warnings du gcc

This commit is contained in:
tTh 2022-01-22 14:47:46 +01:00
parent af7266eb30
commit 3f7abf4ea0
6 changed files with 20 additions and 11 deletions

View File

@ -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

View File

@ -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

View File

@ -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;
}
/* ---------------------------------------------- ~~~~~~~~~~~~~~~~ */
/* --------------------------------------------------------------- */

View File

@ -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 \

View File

@ -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 \

View File

@ -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
# ----------