jsummers / bmpsuite

A set of Windows BMP image files, for testing purposes
https://entropymine.com/jason/bmpsuite/
GNU General Public License v3.0
56 stars 16 forks source link

Separate LDLIBS and LDFLAGS. #10

Closed sebras closed 4 years ago

sebras commented 4 years ago

The GNU make manual explains how LDFLAGS and LDLIBS ought to be separated.

Without this change gcc 9.2.1 will complain about undefined references like so:

/usr/bin/ld: bmpsuite.o: in function `srgb_to_linear':
/home/user/src/bmpsuite/bmpsuite.c:193: undefined reference to `pow'
/usr/bin/ld: bmpsuite.o: in function `linear_to_srgb':
/home/suer/src/bmpsuite/bmpsuite.c:203: undefined reference to `pow'
/usr/bin/ld: bmpsuite.o: in function `quantize':
/home/user/src/bmpsuite/bmpsuite.c:328: undefined reference to `floor'
collect2: error: ld returned 1 exit status

This proposed commit fixes the problem. If you need me to change it somehow, please let me know. :)

jsummers commented 4 years ago

Acknowledged. I'll fix it in a separate commit.

sebras commented 4 years ago

This was resolved in a different way by commit 2ee7fee048751f85ef0ab6d4e5f86b36a2cde2d8. Thus this pull request can now safely be closed.