Bug 692947

Summary: Support for QNX in MuPDF
Product: MuPDF Reporter: Mike Gorchak <mike.gorchak.qnx>
Component: mupdfAssignee: MuPDF bugs <mupdf-bugs>
Status: RESOLVED WONTFIX    
Severity: enhancement CC: jackie.rosen, robin.watts, tor.andersson
Priority: P2    
Version: unspecified   
Hardware: All   
OS: other   
Customer: Word Size: ---
Attachments: Patch to support QNX.
Screenshot of MuPDF viewer for QNX/Photon.
Another screenshot of MuPDF viewer for QNX/Photon.

Description Mike Gorchak 2012-03-27 07:58:19 UTC
Created attachment 8450 [details]
Patch to support QNX.

Hello!

I've added support for QNX 6.5.0 to the latest MuPDF source tree. Patch consists of:

Makefile.qnx - a modified makefile with QNX specific changes.
Makerules.qnx - modified make rules for QNX. QNX doesn't support -pipe gcc option, these are only changes.

mupdf/apps/phcallbacks.c
mupdf/apps/phcallbacks.h
mupdf/apps/phmupdf.c
mupdf/apps/phmupdf.h
mupdf/apps/phpdf.c
mupdf/apps/phpdf.h
mupdf/apps/phpictures.c
mupdf/apps/phpictures.h - All these files are source for MuPDF viewer for QNX's GUI, called Photon.

At start I did a simple viewer based on linux and windows sources, but it's performance was ugly, so I have created a QNX/Photon tuned viewer.

mupdf/fitz/res_font.c - QNX doesn't support a NULL as printf parameter, so there is a simple check for NULL argument.

I will post also a few screenshots of the viewer below.

Thanks!
Comment 1 Mike Gorchak 2012-03-27 07:59:52 UTC
Created attachment 8451 [details]
Screenshot of MuPDF viewer for QNX/Photon.

Screenshot of MuPDF viewer for QNX/Photon.
Comment 2 Mike Gorchak 2012-03-27 08:00:56 UTC
Created attachment 8452 [details]
Another screenshot of MuPDF viewer for QNX/Photon.

Another screenshot of MuPDF viewer for QNX/Photon.
Comment 3 Robin Watts 2012-04-05 22:28:17 UTC
Thanks for this patch, and apologies for not having replied sooner.

We have noted the presence of the patch, and we're interested in it. It does produce some interesting questions though; if we take it on, we have no way of maintaining it (or even testing it). All our other versions can be tested by at least one mupdf developer.

One possibility would be to take this on within a 'contrib' directory, but that can often become a graveyard for broken code. We need to discuss this some more. Such discussion has been delayed due to first me, then Tor being on holiday.

Please bear with us, and thank you for your contribution.
Comment 4 Mike Gorchak 2012-04-06 05:32:16 UTC
> One possibility would be to take this on within a 'contrib' directory, but that
> can often become a graveyard for broken code. We need to discuss this some
> more. Such discussion has been delayed due to first me, then Tor being on
> holiday.

I can maintain a fork at github, but this require much more efforts than just send patch to you. It's not a problem to put all my code into the 'contrib' folder. I can write HOWTO document which will describe building process under QNX.

For example, I can send you latest source code and binaries just before major/minor releases of MuPDF, when you ask for it. It would be much easier for users to grab binaries at main site rather than download them from github, like it is done currently: https://github.com/llmike/PhMuPDF/downloads

At this moment I did a lot of changes to this code, so when you are ready to include this source to contrib folder just notify me. I will attach latest source and binaries.

> Please bear with us, and thank you for your contribution.

Thank you.