We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Getting below error on compiling.
lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 20.04.3 LTS Release: 20.04 Codename: focal
shrini@shrini-laptop:~/dev/dev/autocrop$ make CXXFLAGS=-DWRITE_DEBUG_IMAGES g++ -DWRITE_DEBUG_IMAGES -ansi -Werror -D_BSD_SOURCE -DANSI -fPIC -O3 -DL_LITTLE_ENDIAN -Ileptonica-1.68/src -c autoCropScribe.c -o autoCropScribe.o In file included from /usr/include/x86_64-linux-gnu/bits/libc-header-start.h:33, from /usr/include/stdio.h:27, from autoCropScribe.c:13: /usr/include/features.h:187:3: error: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Werror=cpp] 187 | # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" | ^~~~~~~ autoCropScribe.c: In function ‘double CalculateFullPageSADrow(PIX*, l_uint32, l_uint32, l_uint32, l_uint32)’: autoCropScribe.c:243:28: error: call of overloaded ‘abs(l_uint32)’ is ambiguous 243 | acc += (abs(a-b)); | ^ In file included from /usr/include/c++/9/cstdlib:75, from /usr/include/c++/9/stdlib.h:36, from autoCropScribe.c:14: /usr/include/stdlib.h:840:12: note: candidate: ‘int abs(int)’ 840 | extern int abs (int __x) __THROW attribute ((const)) __wur; | ^~~ In file included from /usr/include/c++/9/cstdlib:77, from /usr/include/c++/9/stdlib.h:36, from autoCropScribe.c:14: /usr/include/c++/9/bits/std_abs.h:79:3: note: candidate: ‘long double std::abs(long double)’ 79 | abs(long double __x) | ^~~ /usr/include/c++/9/bits/std_abs.h:75:3: note: candidate: ‘float std::abs(float)’ 75 | abs(float __x) | ^~~ /usr/include/c++/9/bits/std_abs.h:71:3: note: candidate: ‘double std::abs(double)’ 71 | abs(double __x) | ^~~ /usr/include/c++/9/bits/std_abs.h:61:3: note: candidate: ‘long long int std::abs(long long int)’ 61 | abs(long long __x) { return __builtin_llabs (__x); } | ^~~ /usr/include/c++/9/bits/std_abs.h:56:3: note: candidate: ‘long int std::abs(long int)’ 56 | abs(long __i) { return __builtin_labs(__i); } | ^~~ autoCropScribe.c: In function ‘int AdjustCropBoxByVariance(PIX*, l_int32*, l_int32*, l_int32*, l_int32*, l_int32, double)’: autoCropScribe.c:1229:1: error: no return statement in function returning non-void [-Werror=return-type] 1229 | } | ^ autoCropScribe.c: In function ‘int AdjustCropBox(PIX*, l_int32*, l_int32*, l_int32*, l_int32*, l_int32)’: autoCropScribe.c:1129:12: error: control reaches end of non-void function [-Werror=return-type] 1129 | *cropB = newB; | ~~~~~~~^~~~~~ cc1plus: all warnings being treated as errors make: *** [Makefile:36: autoCropScribe.o] Error 1
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Getting below error on compiling.
lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.3 LTS
Release: 20.04
Codename: focal
shrini@shrini-laptop:~/dev/dev/autocrop$ make CXXFLAGS=-DWRITE_DEBUG_IMAGES
g++ -DWRITE_DEBUG_IMAGES -ansi -Werror -D_BSD_SOURCE -DANSI -fPIC -O3 -DL_LITTLE_ENDIAN -Ileptonica-1.68/src -c autoCropScribe.c -o autoCropScribe.o
In file included from /usr/include/x86_64-linux-gnu/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from autoCropScribe.c:13:
/usr/include/features.h:187:3: error: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Werror=cpp]
187 | # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
| ^~~~~~~
autoCropScribe.c: In function ‘double CalculateFullPageSADrow(PIX*, l_uint32, l_uint32, l_uint32, l_uint32)’:
autoCropScribe.c:243:28: error: call of overloaded ‘abs(l_uint32)’ is ambiguous
243 | acc += (abs(a-b));
| ^
In file included from /usr/include/c++/9/cstdlib:75,
from /usr/include/c++/9/stdlib.h:36,
from autoCropScribe.c:14:
/usr/include/stdlib.h:840:12: note: candidate: ‘int abs(int)’
840 | extern int abs (int __x) __THROW attribute ((const)) __wur;
| ^~~
In file included from /usr/include/c++/9/cstdlib:77,
from /usr/include/c++/9/stdlib.h:36,
from autoCropScribe.c:14:
/usr/include/c++/9/bits/std_abs.h:79:3: note: candidate: ‘long double std::abs(long double)’
79 | abs(long double __x)
| ^~~
/usr/include/c++/9/bits/std_abs.h:75:3: note: candidate: ‘float std::abs(float)’
75 | abs(float __x)
| ^~~
/usr/include/c++/9/bits/std_abs.h:71:3: note: candidate: ‘double std::abs(double)’
71 | abs(double __x)
| ^~~
/usr/include/c++/9/bits/std_abs.h:61:3: note: candidate: ‘long long int std::abs(long long int)’
61 | abs(long long __x) { return __builtin_llabs (__x); }
| ^~~
/usr/include/c++/9/bits/std_abs.h:56:3: note: candidate: ‘long int std::abs(long int)’
56 | abs(long __i) { return __builtin_labs(__i); }
| ^~~
autoCropScribe.c: In function ‘int AdjustCropBoxByVariance(PIX*, l_int32*, l_int32*, l_int32*, l_int32*, l_int32, double)’:
autoCropScribe.c:1229:1: error: no return statement in function returning non-void [-Werror=return-type]
1229 | }
| ^
autoCropScribe.c: In function ‘int AdjustCropBox(PIX*, l_int32*, l_int32*, l_int32*, l_int32*, l_int32)’:
autoCropScribe.c:1129:12: error: control reaches end of non-void function [-Werror=return-type]
1129 | *cropB = newB;
| ~~~~~~~^~~~~~
cc1plus: all warnings being treated as errors
make: *** [Makefile:36: autoCropScribe.o] Error 1
The text was updated successfully, but these errors were encountered: