PDFium plugin

Jonathan Schultz jonathan at imatix.com
Wed Jan 18 07:02:55 UTC 2017


Please excuse the silly comment about providing an executable - I see 
that you said that we'd have to build it ourselves.

So I just tried building, got most of the way without a hitch. I had to 
also use ninja build libfx_lpng.a and libfx_freetype.a to satisfy the 
dependencies in the okular Makefile. But once that was done it seems to 
work. I wasn't too sure that it was actually using pdfium, but when I 
moved the poppler generator out of the way I could see that it is 
working. Some small differences in appearance... So at least it works as 
a proof-of-concept...

On 18/01/17 10:14, Jonathan Schultz wrote:
> Looks interesting. How does it compare (performance, features, etc.)
> with the Poppler plugin?
>
> Any chance you could save us the bother of building ourselves and post a
> link to an executable?
>
> Cheers,
> Jonathan
>
> On 18/01/17 03:30, Gilbert Assaf wrote:
>> Hi all,
>>
>> I worked on an okular pdf plugin using pdfium as a backend. At this
>> point it is little more than a “proof-of-concept”. But you can already
>> view simple pdf files.
>>
>> I would like to get some feedback on this: maybe somebody else is
>> already working on an okular pdfium plugin? I am relatively new to KDE
>> and don’t know all the development processes.
>> How do you normally proceed from here on? Reviewboard? A personal branch?
>>
>> I attached a git patch file, if somebody would like to try it out.
>>
>> A small warning: pdfium only works on x64 and at this point it is
>> basically a mixture of static and shared libraries. So you definitely
>> have to compile it yourself.
>>
>> Thanks,
>> Gilbert
>>
>> === Install depot tools ===
>> Needed for fetching and building pdfium
>> See instructions:
>> https://www.chromium.org/developers/how-tos/install-depot-tools
>>
>> === Install pdfium ===
>> mkdir repo
>> cd repo
>> gclient config --unmanaged https://pdfium.googlesource.com/pdfium.git
>> gclient sync
>> cd pdfium
>> export PDFIUM_DIR=`pwd`
>> gn gen out/Debug --args="pdf_enable_xfa=false pdf_enable_v8=true
>> use_sysroot=false is_debug=true"
>> ninja -C out/Debug pdfium
>>
>> === Compile Okular ===
>> cd <okular build dir>
>> cmake .. -DPDFIUM_ROOT_DIR=$PDFIUM_DIR
>> You probably have to add $PDFIUM_DIR dir to your LD_LIBRARY_PATH variable
>


More information about the Okular-devel mailing list