Summary: | ImageMagick coredumps in libgs while convert pdf to png if IM compiled with LCMS2 and GSLIB support | ||
---|---|---|---|
Product: | Ghostscript | Reporter: | VVD <vvd> |
Component: | Color Management | Assignee: | Chris Liddell (chrisl) <chris.liddell> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | chris.liddell, robin.watts |
Priority: | P4 | ||
Version: | 9.52 | ||
Hardware: | PC | ||
OS: | FreeBSD | ||
Customer: | Word Size: | 64 | |
Attachments: |
visibility of lcms2mt
Visibility of lcms2mt. Visibility of lcms2mt. Doesn't work. |
Description
VVD
2020-04-22 17:33:45 UTC
What other information I have to show? Yes, as you say, that's quite possibly a conflict between lcms2mt and lcms2. BUT... it's not a gs bug. It's an Imagemagick one, you should report it to them. It's a problem with their integration. Or at least, it's down to the person that tried to link libraries built in conflicting ways. > It's an Imagemagick one, you should report it to them. Already did. Read, plz, links above. > Or at least, it's down to the person that tried to link libraries built in conflicting ways. What is the correct way? ImageMagick using lcms2 and libgs. Apologies, I handled this badly. My point was intended to be that you should report the issue to the maintainers of IM, and they should contact us to work together to solve the problem. BUT, one of my colleagues may have a workaround. *if* the segfault is being caused by a symbol clash between lcms2mt (in gs) and lcms2 (in ImageMagick), then I *think* this should resolve it: http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=f210e4c009f7 I'm closing this as resolved/fixed. If that turns out not to be the problem (or the above solution doesn't work), could you re-open and point the Imagemagick devs at this bug, or #ghostscript (on freenode) or the gs-devel mailing list (links on ghostcript.com), we can work with them to find a solution? Thanks. Created attachment 19181 [details]
visibility of lcms2mt
Thanks.
This patch work for me.
Look at configure changes - without it I got error.
Created attachment 19182 [details]
Visibility of lcms2mt.
This one is correct.
Oh, wait. Created attachment 19183 [details]
Visibility of lcms2mt.
This one work.
2nd doesn't work.
Created attachment 19184 [details]
Doesn't work.
This patch doesn't work with hard coded CFLAGS_VISIBILITY="-fvisibility=hidden" in configure.ac.
But if it hard coded in Makefile.in - work fine.
(In reply to VVD from comment #10) > Created attachment 19184 [details] > Doesn't work. > > This patch doesn't work with hard coded > CFLAGS_VISIBILITY="-fvisibility=hidden" in configure.ac. > But if it hard coded in Makefile.in - work fine. Well, hard coding in Makefile.in is unacceptable - we have to support more compilers than just gcc and clang. I can't see any reason why the tests in configure.ac would not work (they certainly do on Linux), and I don't have a FreeBSD install to test on. (In reply to Chris Liddell (chrisl) from comment #11) > Well, hard coding in Makefile.in is unacceptable - we have to support more > compilers than just gcc and clang. Agree, ofc you are right. > I can't see any reason why the tests in configure.ac would not work (they > certainly do on Linux), and I don't have a FreeBSD install to test on. He is not transferred from configure.ac to this Makefile.in. Without this one: --- configure.orig +++ configure @@ -868,6 +868,7 @@ ECHO_N ECHO_C DEFS +CFLAGS_VISIBILITY mandir localedir libdir I got error: cc: error: no such file or directory: '@CFLAGS_VISIBILITY@' gmake[4]: *** [base/lcms2mt.mak:101: soobj/cmscam02.o] Error 1 You need to run autogen.sh to regenerate configure from configure.ac. (In reply to Chris Liddell (chrisl) from comment #13) > You need to run autogen.sh to regenerate configure from configure.ac. FreeBSD port print/ghostscript9-agpl-base doesn't use autogen.sh during build process. It patch configure and run it: https://svnweb.freebsd.org/ports/head/print/ghostscript9-agpl-base/files/ I made patch for port print/ghostscript9-agpl-base: https://bugs.freebsd.org/bugzilla/attachment.cgi?id=213868&action=diff https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=245782 Thanks a lot for fix it! |