Facing issue with dependencies

I have installed Pressbooks on a fresh WordPress and set up everything according to the documentation and set all the paths for third-party dependencies which used to export the book but in Export in WordPress backed it’s still saying that third-party dependencies could not be found http://prntscr.com/lby8c5 Please help and let me know what I miss in order to export books. Thanks

In addition to setting all the paths for third-party dependencies… Did you install the third party dependencies?

Scroll down to “Suggested Topics” just below. These types questions have been asked many times. Maybe the other threads can help you.


Here’s one to get you started:

Hope this helps.

Yes, I have installed all the third party libraries and set their paths. But in backend it still saying that libraries not installed.

Your screenshot shows that all the dependencies have failed. Not one, not two, all of them. That is highly unusual.

Here are some ideas.

Check your error logs:

Check that PHP has permission to run binaries using the exec function:

Check if you are in safe mode. Turn this off.

Check if you are running Suhosin. Uninstall.

Modules require the ability to create a temporary directory in whatever sys_get_temp_dir() returns. Configure accordingly:

The code that generates the error in your screenshot is located here:

These lines of code call dependency checking functions. The simplest function to check would be check_xmllint_install() because that one is usually an apt get install to get goind, that code is located here:

In \Pressbooks\Utility\check_xmllint_install, before $output = $output[0]; do a print_r($output); die(); or error_log(print_r($output,true)) or set a breakpoint and use XDebug or … your favourite PHP debugging method here, then reload the page. The $ouput array will contain CLI output as to the reason why that command failed.

Rinse and repeat for the other dependency checking functions. Remove debug code once you figure it out.


Thank you so much for such an informative help, I figure it out and find that exec command was not enable on server so I enable it now it showing the option for export but I select the export option and press export it showing error on exporting. Here is screenshot: http://prntscr.com/leci9d
Is there anything I missed?

Your server doesn’t seem to have iconv installed:


Thanks again. You are really awesome. Now epub and mobi export are working but PDF(mpdf) is not working and showing error:

what is missing now?

The mPDF export plugin is maintained by @brad at BCcampus: https://github.com/BCcampus/pressbooks-mpdf. I suggest you navigate to Settings → Export, turn on the Email Validation Logs setting, and see what shows up when you try to export.

Thanks @ned I have enabled email validation logs but receiving any email regarding the issue. Is there any other way to log the error.


I already have enabled error log of WordPress. But it not showing anything there,

Sorry, don’t know what to tell you.

@brad Could you please help? I am stuck at it.

Hi @hussnainsheikh - if you feel comfortable opening up an issue on github, that is the best place to troubleshoot what might be going on for you.

Hello @brad and @ned

I have installed pressbooks on another website and export for mobi, kindle and mpdf are working fine but there is some issue with PDF(print) and PDF(for digital distribution). I have installed all the requirements for both of these but these 2 export are not working and showing the error to check logs.

Could you please let me know what I miss there? And where I can check logs for it. Thanks

These instructions still apply, and should result in you getting an email with some debugging information about why the export failed.

Hello @ned

Thanks for your reply. I enable the email Validation log but didn’t receive any email regarding logs. And PDF(print) is still not working and showing error to check logs. Is there anything else by which I can trace error? Thanks

Scroll down to where it says:

else {
			\Pressbooks\Utility\email_error_log( $this->errorsEmail, $subject, $message );

Do a print_r($message); die();

Remove debug code once you figure it out.

Hello @dac.chartrand

Thanks for you reply. I have tried your given solution but it didn’t work and didn’t show any error. Actually this code is not calling on export. Is there any other solution? Thanks