usnistgov / SCTK

Other
208 stars 52 forks source link

make all gives warnings and errors #26

Closed Brown-229 closed 2 years ago

Brown-229 commented 3 years ago

make all (mkdir -p bin) (cd src && if test -f makefile ; then make all ; fi) (cd asclite && if test -f makefile ; then make all ; fi) (cd core && if test -f makefile ; then make all ; fi) make[3]: Nothing to be done for all'. (cd test && if test -f makefile ; then make all ; fi) make[3]: Nothing to be done forall'. (cd sclite && if test -f makefile ; then make all ; fi) gcc -c -DHAVE_LIBM=1 -DHAVE_UNISTD_H=1 -I. -Os align.c align.c:29:20: warning: comparing a pointer to a null character constant; did you mean to compare to NULL? [-Wpointer-compare] if (R_paren == NULL_TEXT && L_paren == NULL_TEXT)
^~~~~ (void *)0 ./text.h:4:19: note: expanded from macro 'NULL_TEXT'

define NULL_TEXT '\0'

              ^

align.c:29:44: warning: comparing a pointer to a null character constant; did you mean to compare to NULL? [-Wpointer-compare] if (R_paren == NULL_TEXT && L_paren == NULL_TEXT)
^~~~~ (void *)0 ./text.h:4:19: note: expanded from macro 'NULL_TEXT'

define NULL_TEXT '\0'

              ^

align.c:32:20: warning: comparing a pointer to a null character constant; did you mean to compare to NULL? [-Wpointer-compare] if (R_paren == NULL_TEXT || L_paren == NULL_TEXT){ ^~~~~ (void *)0 ./text.h:4:19: note: expanded from macro 'NULL_TEXT'

define NULL_TEXT '\0'

              ^

align.c:32:44: warning: comparing a pointer to a null character constant; did you mean to compare to NULL? [-Wpointer-compare] if (R_paren == NULL_TEXT || L_paren == NULL_TEXT){ ^~~~~ (void *)0 ./text.h:4:19: note: expanded from macro 'NULL_TEXT'

define NULL_TEXT '\0'

              ^

align.c:63:36: warning: comparing a pointer to a null character constant; did you mean to compare to NULL? [-Wpointer-compare] if (((p = TEXT_strchr(id,'-')) == NULL_TEXT) && ^~~~~ (void *)0 ./text.h:4:19: note: expanded from macro 'NULL_TEXT'

define NULL_TEXT '\0'

              ^

align.c:64:36: warning: comparing a pointer to a null character constant; did you mean to compare to NULL? [-Wpointer-compare] ((p = TEXTstrchr(id,'')) == NULL_TEXT)){ ^~~~~ (void *)0 ./text.h:4:19: note: expanded from macro 'NULL_TEXT'

define NULL_TEXT '\0'

              ^

align.c:933:15: error: implicit declaration of function 'getpid' is invalid in C99 [-Werror,-Wimplicit-function-declaration] int pid = getpid(); ^ align.c:1070:5: error: implicit declaration of function 'unlink' is invalid in C99 [-Werror,-Wimplicit-function-declaration] unlink(refwords); ^ align.c:1295:5: error: implicit declaration of function 'unlink' is invalid in C99 [-Werror,-Wimplicit-function-declaration] unlink(refwords); ^ align.c:1438:5: error: implicit declaration of function 'unlink' is invalid in C99 [-Werror,-Wimplicit-function-declaration] unlink(refwords); ^ 6 warnings and 4 errors generated. make[2]: [align.o] Error 1 make[1]: [all] Error 2 make: *** [all] Error 2

ryandesign commented 2 years ago

The PR was merged and version 2.4.12 was released with which I don't see these errors so I guess this issue can be closed.

jfiscus commented 2 years ago

I agree with @ryandesign