edrosten / libcvd

libcvd - efficient and easy to use C++ computer vision library.
Other
238 stars 103 forks source link

Build tests without -O0 also in the autoconf build #95

Open AdrianBunk opened 3 months ago

AdrianBunk commented 3 months ago

C++ code compiled without optimizations can be inefficient in many ways, and on some more exotic architectures (MIPS, Alpha) this caused a build failure: https://buildd.debian.org/status/fetch.php?pkg=libcvd&arch=mips64el&ver=0.0%7Egit20221020150751.30e8cfc%2Bds1-1&stamp=1695631656&raw=0 https://buildd.debian.org/status/fetch.php?pkg=libcvd&arch=alpha&ver=0.0%7Egit20221020150751.30e8cfc%2Bds1-1&stamp=1722259419&raw=0

/usr/bin/ld: /tmp/cc5JDH6b.o: .got subsegment exceeds 64K (size 86336)
/usr/bin/ld: failed to set dynamic section sizes: No such file or directory
collect2: error: ld returned 1 exit status
make[1]: *** [Makefile:298: tests/load_and_save.test] Error 1

CMake is already using the normal optimization flags also for building the tests.