libschrift icon indicating copy to clipboard operation
libschrift copied to clipboard

Fix compilation for 32bit

Open pseregiet opened this issue 3 years ago • 3 comments

cmap_fmt4, cmap_fmt6 and glyph_id functions declaration and definition didn't match, causing errors when compiling for 32bit (-m32 compiler and linker flag). Some variables were created as unsigned long, pointer to them was passed to functions taking uint_fast_32_t* which is unsigned long int* (not the same as unsigned long*). I think the whole uint_fast_32_t can be replaced with just unsigned int, but I didn't do it in this PR.

pseregiet avatar Mar 24 '21 23:03 pseregiet

It does not compile in GCC 11 either (64 bits)

Darky-Lucera avatar Nov 26 '21 11:11 Darky-Lucera

Ok, I see this merge in the develop branch

Darky-Lucera avatar Nov 26 '21 11:11 Darky-Lucera

Hi @Darky-Lucera sorry for extremely late reply but somehow I didn't get a notification on this issue. This commit is outdated. I just tried compiling libschrift for 32 bit and it works. It only gives a warning in stress.c because the glyph variable is declared as long unsigned int instead of SFT_Glyph (which would be the same on 64 bit, hence no warning)

pseregiet avatar Aug 03 '22 19:08 pseregiet