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

Syncs mozjpeg.podspec #335

Closed
wants to merge 1 commit into from
Closed

Conversation

diegosanchezr
Copy link
Contributor

Wraps transupp.h with extern C

Fixes: facebookincubator/spectrum#26

@kornelski
Copy link
Member

Change to a hardcoded tag from :tag => "v#{spec.version}" seems undesirable.

Also modification of source files looks hacky. Is DONT_USE_EXTERN_C essential here? Otherwise it looks like a standard pattern, and could probable be added to the transupp.h directly and perhaps even contributed to libjpeg-turbo upstream.

@cuva
Copy link
Contributor

cuva commented May 24, 2019

Hey @kornelski - thanks for your quick answer.

We guarded this with DONT_USE_EXTERN_C since this is also the pattern used in jpeglib.h - but happy to get rid of it if you think it's unnecessary.

Change to a hardcoded tag from :tag => "v#{spec.version}" seems undesirable.

Agreed - this was the only way for use to push a new spec version without forcing a new version of mozjpeg - the plan is to drop that on the next release of mozjpeg when it gets back into sync with the podspec version. If you can think of a better alternative more than happy to hear it out!

and could probable be added to the transupp.h directly and perhaps even contributed to libjpeg-turbo upstream.

We assumed that it wasn't there for a reason and this allowed us to fix a long standing issue in Spectrum without being dependant on changes applied to dependant libraries - that being said if you think it's a reasonably thing to do I'm more than happy to submit a PR there and get rid of this hack in the podfile.

We've already pushed the spec 3.3.2 spec file to the central cocoapods spec repo to make sure it fixed our issues - but I think the changes you're suggested are reasonable.

Also, while we'll be keeping the spec up to date with new releases of mozjpeg - there may be a value for you to register as a co-owner of the pod as described in #310.

If anything, please let us know - thanks again.

@kornelski
Copy link
Member

Oh, I didn't notice DONT_USE_EXTERN_C is already used in jpeglib.h. In that case it seems OK to stick with it.

Could you add these guards to transupp.h directly, without changing the spec file? I'll merge it then and make a patch for upstream.

@cuva
Copy link
Contributor

cuva commented May 24, 2019

Sure thing - @diegosanchezr will take care of it first thing next week! Thanks @kornelski - have an excellent weekend.

@diegosanchezr
Copy link
Contributor Author

I'm abandoning this since the .podspec was already published and we'd need to point to the code with the fix in transupp.h. We'll get back to normal with the next release.

kornelski pushed a commit that referenced this pull request Aug 22, 2019
(regression introduced by 5b177b3)

The SSE2 implementation of progressive Huffman encoding performed
extraneous iterations when the scan length was a multiple of 16.

Based on:
rouault/libjpeg-turbo@bb7f1ef

Fixes #335
Closes #367
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SpectrumKit in cocoapod use_modulars_headers!
3 participants