unable to load shared library libpdfium ALPINE LINUX

I am using the pdfviewer library on an Alpine Linux 3.12 operating system. When executing the executable I get the error "unable to load shared library 'libpdfium.so' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: Error loading shared library liblibpdfium.so: No such file or directory ". I've been following the instructions in this forum https://www.syncfusion.com/forums/149937/pdf-viewer-unable-to-load-shared-library-libpdfium-so , but they didn't help me much as the dependencies they mentioned there they were for ubuntu operating systems. And I have not found the necessary dependencies to install the libpdfium.so on Alpine linux.

10 Replies 1 reply marked as answer

DM Dhivyabharathi Mohan Syncfusion Team February 22, 2021 11:57 AM UTC

Hi Andres,   
   
Thank you for contacting Syncfusion support.   
   
   
Currently, we are checking on this and will provide you the more details on  24 February 2021.    
   
We are using Pdfium to render the PDF documents into our PDF Viewer control. So we need to install the additional dependency package by using the below commands for rendering the pages into our PDF Viewer control.   
   
RUN apt-get update \        
    && apt-get install -y --allow-unauthenticated \        
export LD_LIBRARY_PATH=/lib64/       
        libc6-dev \        
        libgdiplus \        
        libx11-dev \        
        curl \        
        vim \        
        supervisor \        
        procps        
  
 
Regards, 
Dhivya.


AS andres salgado February 23, 2021 12:35 AM UTC

Thank you very much for your response.

Yes, in another forum I found that you should install those dependencies for linux-x64 distributions, I even tried pdfium working in an ubuntu container, it worked perfect. But what happens is that my production container is Alpine Linux a linux-musl-64 distribution, so the dependencies change and maybe they don't work as if they work in linux-x64 distributions. It would be a great help if I could install pdfium correctly in my Alpine container so that I can successfully use PdfViewer. 

I am using :
.Net core 3.1
RID linux-musl-64 https://docs.microsoft.com/en-us/dotnet/core/rid-catalog#linux-rids
Syncfusion.EJ2.PdfViewer.AspNet.Core.Linux https://www.nuget.org/packages/Syncfusion.EJ2.PdfViewer.AspNet.Core.Linux/
Alpine Linux



VS Vasugi Sivajothi Syncfusion Team February 23, 2021 04:37 PM UTC

Hi andres, 
 
 
Thanks for the update.  
 
Currently, we are working on your issue. As we mentioned earlier, we will check further on this and update you with more details on 24 February 2021.   
 
 
Regards, 
Vasugi 



VS Vasugi Sivajothi Syncfusion Team February 24, 2021 10:02 AM UTC

Hi Andres, 
 
 
Sorry for the inconvenience caused. 
 
 
We have analyzed further but we are facing the following error on the PDF Viewer Core sample deployed with the Alpine Linux docker container. 
 
 
Unable to load shared library 'libpdfium. so' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: Error loading shared library liblibpdfium.so.so: No such file or directory  
 
This Alpine Linux distribution based on the musl libc and it differs from other Debian OS. We can’t find and install the exact dependencies of pdfium within Alpine Linux OS. Still, we are investigating to resolve it. Please find the details in the following reference link below,  
 
 
Could you please share any specific reason to choose the Alpine docker container? That would be very helpful for us to provide an alternate way to meet your requirement.  
 
Also, we have reported this issue on the alpine GitHub page. Please find the link below.    
 
 
We will update the details once we received an update from this forum.  
 
Let us know if you have any concerns about this. 
 
Regards, 
Vasugi 



AS andres salgado February 24, 2021 01:33 PM UTC

Thank you very much for your response.

I am using a docker container from Alpine Linux for its lightness, because it installs only what is necessary, something very important when using CI/CD.  What Debian image would you recommend me that only has the necessary and is very light, and pdfviewer if it works perfectly? 


AS andres salgado replied to andres salgado February 24, 2021 01:39 PM UTC

Thank you very much for your response.

I am using a docker container from Alpine Linux for its lightness, because it installs only what is necessary, something very important when using CI/CD.  What Debian image would you recommend me that only has the necessary and is very light, and pdfviewer if it works perfectly? 

Also, why did we look for Linux Alpine, because it is a standard in the deployment of productive environments by Dockers. The final packages are very small and it allows to control all the processes that run and the services that would be available on the server.


VS Vasugi Sivajothi Syncfusion Team March 2, 2021 04:19 PM UTC

Hi andres,  
  
Thanks for the update.   
Currently, we are working on your query with the provided details. We will analyze further on this and update you with more details on March 11, 2021.    
  
Regards,  
Vasug


VS Vasugi Sivajothi Syncfusion Team March 19, 2021 02:37 PM UTC

Hi andres,   
  
Sorry for the Inconvenience. 
  
Currently we are checking on your issue with the provided environment. So, we will update further details on March 25, 2021. 
  
Regards, 
Vasugi 



AS andres salgado March 19, 2021 04:18 PM UTC

okay thank you very much


VS Vasugi Sivajothi Syncfusion Team March 25, 2021 03:13 PM UTC

Hi andres, 
 
Thanks for your patience. 
 
We have analyzed to resolved the reported issue on Alpine Linux. We can’t fix. As we mentioned in our previous update on February 24th 2021 we can resolve it by getting update from the following issue  
 
 
We have support for Linux Centos OS. Could you please refer the following documentation link for more information about the docker usage of our PDF Viewer service 
 
 
Regards, 
Vasugi 


Marked as answer
Loader.
Up arrow icon