viest / php-ext-xlswriter

🚀 PHP Extension for creating and reader XLSX files.
https://xlswriter.viest.me
BSD 2-Clause "Simplified" License
2.25k stars 232 forks source link

Compilation error - too few arguments to function lxw_worksheet_prepare_chart #90

Closed petk closed 5 years ago

petk commented 5 years ago

Hello, when compiling with the latest libxlswriter the following compilation error happens:

/packages/php-xlswriter/src/xlswriter-1.2.2/kernel/write.c: In function '_prepare_drawings':
/packages/php-xlswriter/src/xlswriter-1.2.2/kernel/write.c:370:13: error: too few arguments to function 'lxw_worksheet_prepare_chart'
             lxw_worksheet_prepare_chart(worksheet, chart_ref_id, drawing_id,
             ^~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/xlsxwriter/workbook.h:48:0,
                 from /usr/include/xlsxwriter.h:16,
                 from /packages/php-xlswriter/src/xlswriter-1.2.2/kernel/include.h:23,
                 from /packages/php-xlswriter/src/xlswriter-1.2.2/kernel/write.c:13:
/usr/include/xlsxwriter/worksheet.h:3247:6: note: declared here

Thank you.

petk commented 5 years ago

It seems this is already fixed via ea20f004930111865bc2b8a8dce9dfc577415ff7 so the only issue is that the release needs to be tagged...

Besides the 1.2.2 version is missing as a GitHub tag...

Thanks.

viest commented 5 years ago

@petk Have you updated bunled Lib? 🙂

petk commented 5 years ago

Thank you @viest It works with 1.2.3. Yes, I've used the "system" library (a custom built libxlswriter) and set the --with-libxlsxwriter option and now it works. Somehow, if the libxlswriter is already installed on the system and this configure option is not set it doesn't work. Maybe I've missed something but now it works so thank you for such a quick fix.

viest commented 5 years ago

Thank you for your issue. 🙂