Skip to content
New issue

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

PNG v3: Support for mDCV and cLLI #635

Merged
merged 2 commits into from
Jan 8, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion png.h
Original file line number Diff line number Diff line change
Expand Up @@ -3346,7 +3346,7 @@ PNG_EXPORT(244, int, png_set_option, (png_structrp png_ptr, int option,
* one to use is one more than this.)
*/
#ifdef PNG_EXPORT_LAST_ORDINAL
PNG_EXPORT_LAST_ORDINAL(251);
PNG_EXPORT_LAST_ORDINAL(259);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So we'll git-merge all this into the libpng18 branch as planned, but beyond that, these ordinals gotta go.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
PNG_EXPORT_LAST_ORDINAL(259);
PNG_EXPORT_LAST_ORDINAL(259);

At least the script (only in the configure build) that checks the ordinals then faults the build unless the machine-generated files have been updated too.

1.8; a simple change that is unlikely to cause merge conflicts against 1.6 since I believe it's only a few lines. Remove the symbol-by-ordinal support. Throw that PoS against the wall and see what breaks. But don't make any other change to those damned macros because if it has to be reintroduced the result would be a nightmare bug farm.

Completely off topic: the same applies to pnglibconf.h.prebuilt, but generate that in the tarball for the "approved" Linux config. Just don't check it in autoconf or cmake builds that use it.

I think you said this years ago, but if it wasn't you it wasn't me or Glenn either yet it is still correct: The machine generated files should not be in the Git.

#endif

#ifdef __cplusplus
Expand Down
6 changes: 6 additions & 0 deletions scripts/pnglibconf.h.prebuilt
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,13 @@
#define PNG_READ_bKGD_SUPPORTED
#define PNG_READ_cHRM_SUPPORTED
#define PNG_READ_cICP_SUPPORTED
#define PNG_READ_cLLI_SUPPORTED
#define PNG_READ_eXIf_SUPPORTED
#define PNG_READ_gAMA_SUPPORTED
#define PNG_READ_hIST_SUPPORTED
#define PNG_READ_iCCP_SUPPORTED
#define PNG_READ_iTXt_SUPPORTED
#define PNG_READ_mDCV_SUPPORTED
#define PNG_READ_oFFs_SUPPORTED
#define PNG_READ_pCAL_SUPPORTED
#define PNG_READ_pHYs_SUPPORTED
Expand Down Expand Up @@ -160,11 +162,13 @@
#define PNG_WRITE_bKGD_SUPPORTED
#define PNG_WRITE_cHRM_SUPPORTED
#define PNG_WRITE_cICP_SUPPORTED
#define PNG_WRITE_cLLI_SUPPORTED
#define PNG_WRITE_eXIf_SUPPORTED
#define PNG_WRITE_gAMA_SUPPORTED
#define PNG_WRITE_hIST_SUPPORTED
#define PNG_WRITE_iCCP_SUPPORTED
#define PNG_WRITE_iTXt_SUPPORTED
#define PNG_WRITE_mDCV_SUPPORTED
#define PNG_WRITE_oFFs_SUPPORTED
#define PNG_WRITE_pCAL_SUPPORTED
#define PNG_WRITE_pHYs_SUPPORTED
Expand All @@ -179,11 +183,13 @@
#define PNG_bKGD_SUPPORTED
#define PNG_cHRM_SUPPORTED
#define PNG_cICP_SUPPORTED
#define PNG_cLLI_SUPPORTED
#define PNG_eXIf_SUPPORTED
#define PNG_gAMA_SUPPORTED
#define PNG_hIST_SUPPORTED
#define PNG_iCCP_SUPPORTED
#define PNG_iTXt_SUPPORTED
#define PNG_mDCV_SUPPORTED
#define PNG_oFFs_SUPPORTED
#define PNG_pCAL_SUPPORTED
#define PNG_pHYs_SUPPORTED
Expand Down
8 changes: 8 additions & 0 deletions scripts/symbols.def
Original file line number Diff line number Diff line change
Expand Up @@ -255,3 +255,11 @@ EXPORTS
png_set_eXIf_1 @249
png_get_cICP @250
png_set_cICP @251
png_get_cLLI @252
png_get_cLLI_fixed @253
png_set_cLLI @254
png_set_cLLI_fixed @255
png_get_mDCV @256
png_get_mDCV_fixed @257
png_set_mDCV @258
png_set_mDCV_fixed @259
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah... this @259 and all of its friends must be no more by the time we publish libpng-1.8.0.

Loading