Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Special Interest Groups
  3. Independent Developers
  4. How do i use poppler lib in Qt quick application.

How do i use poppler lib in Qt quick application.

Scheduled Pinned Locked Moved Unsolved Independent Developers
35 Posts 4 Posters 6.6k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    NIvil Wilson
    wrote on 27 Mar 2021, 08:31 last edited by
    #1

    sir,
    how do i use plopper library in Qt quick application (using qmake). could you give me instructions to use poppler with my application.

    E 1 Reply Last reply 27 Mar 2021, 09:04
    0
    • N NIvil Wilson
      27 Mar 2021, 08:31

      sir,
      how do i use plopper library in Qt quick application (using qmake). could you give me instructions to use poppler with my application.

      E Offline
      E Offline
      eyllanesc
      wrote on 27 Mar 2021, 09:04 last edited by
      #2

      @NIvil-Wilson See this answer: https://stackoverflow.com/questions/52843694/how-i-can-use-poppler-qml-plugin-in-my-application/52844509#52844509

      If you want me to help you develop some work then you can write to my email: e.yllanescucho@gmal.com.

      N 1 Reply Last reply 27 Mar 2021, 14:57
      0
      • E eyllanesc
        27 Mar 2021, 09:04

        @NIvil-Wilson See this answer: https://stackoverflow.com/questions/52843694/how-i-can-use-poppler-qml-plugin-in-my-application/52844509#52844509

        N Offline
        N Offline
        NIvil Wilson
        wrote on 27 Mar 2021, 14:57 last edited by NIvil Wilson
        #3

        @eyllanesc
        sir ,
        when i tried to build for android it shows error: cannot find -lpoppler-qt5

        Screenshot from 2021-03-27 21-16-42.png

        J 1 Reply Last reply 29 Mar 2021, 04:51
        0
        • N NIvil Wilson
          27 Mar 2021, 14:57

          @eyllanesc
          sir ,
          when i tried to build for android it shows error: cannot find -lpoppler-qt5

          Screenshot from 2021-03-27 21-16-42.png

          J Offline
          J Offline
          jsulm
          Lifetime Qt Champion
          wrote on 29 Mar 2021, 04:51 last edited by
          #4

          @NIvil-Wilson said in How do i use poppler lib in Qt quick application.:

          cannot find -lpoppler-qt5

          Did you build poppler for Android?
          From your screen-shot it does not look like you did...

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          N 1 Reply Last reply 29 Mar 2021, 06:19
          0
          • J jsulm
            29 Mar 2021, 04:51

            @NIvil-Wilson said in How do i use poppler lib in Qt quick application.:

            cannot find -lpoppler-qt5

            Did you build poppler for Android?
            From your screen-shot it does not look like you did...

            N Offline
            N Offline
            NIvil Wilson
            wrote on 29 Mar 2021, 06:19 last edited by
            #5

            @jsulm
            sir,
            i dont know how to build poppler for android.could you please tell me.

            J 1 Reply Last reply 29 Mar 2021, 06:27
            0
            • N NIvil Wilson
              29 Mar 2021, 06:19

              @jsulm
              sir,
              i dont know how to build poppler for android.could you please tell me.

              J Offline
              J Offline
              jsulm
              Lifetime Qt Champion
              wrote on 29 Mar 2021, 06:27 last edited by
              #6

              @NIvil-Wilson https://gitlab.freedesktop.org/poppler/poppler/-/blob/master/INSTALL

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              N 1 Reply Last reply 29 Mar 2021, 07:26
              0
              • J jsulm
                29 Mar 2021, 06:27

                @NIvil-Wilson https://gitlab.freedesktop.org/poppler/poppler/-/blob/master/INSTALL

                N Offline
                N Offline
                NIvil Wilson
                wrote on 29 Mar 2021, 07:26 last edited by
                #7

                @jsulm
                after building poppler for android it shows the same errror
                skipping incompatible /usr/local/lib//libpoppler-qt5.so when searching for -lpoppler-qt5.

                J 2 Replies Last reply 29 Mar 2021, 07:29
                0
                • N NIvil Wilson
                  29 Mar 2021, 07:26

                  @jsulm
                  after building poppler for android it shows the same errror
                  skipping incompatible /usr/local/lib//libpoppler-qt5.so when searching for -lpoppler-qt5.

                  J Offline
                  J Offline
                  jsulm
                  Lifetime Qt Champion
                  wrote on 29 Mar 2021, 07:29 last edited by
                  #8

                  @NIvil-Wilson said in How do i use poppler lib in Qt quick application.:

                  /usr/local/lib//libpoppler-qt5.so

                  I'm sure this is not poppler built for Android.
                  You have to provide proper path to the Android version using LIBS.

                  https://forum.qt.io/topic/113070/qt-code-of-conduct

                  N 1 Reply Last reply 29 Mar 2021, 14:11
                  0
                  • J jsulm
                    29 Mar 2021, 07:29

                    @NIvil-Wilson said in How do i use poppler lib in Qt quick application.:

                    /usr/local/lib//libpoppler-qt5.so

                    I'm sure this is not poppler built for Android.
                    You have to provide proper path to the Android version using LIBS.

                    N Offline
                    N Offline
                    NIvil Wilson
                    wrote on 29 Mar 2021, 14:11 last edited by
                    #9

                    @jsulm
                    sir,
                    this is my cmak_install file.could you please check it .

                    # Install script for directory: /home/nivilwilsonp/Pictures/poppler-21.03.0
                    
                    # Set the install prefix
                    if(NOT DEFINED CMAKE_INSTALL_PREFIX)
                      set(CMAKE_INSTALL_PREFIX "/usr/local")
                    endif()
                    string(REGEX REPLACE "/$" "" CMAKE_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}")
                    
                    # Set the install configuration name.
                    if(NOT DEFINED CMAKE_INSTALL_CONFIG_NAME)
                      if(BUILD_TYPE)
                        string(REGEX REPLACE "^[^A-Za-z0-9_]+" ""
                               CMAKE_INSTALL_CONFIG_NAME "${BUILD_TYPE}")
                      else()
                        set(CMAKE_INSTALL_CONFIG_NAME "RelWithDebInfo")
                      endif()
                      message(STATUS "Install configuration: \"${CMAKE_INSTALL_CONFIG_NAME}\"")
                    endif()
                    
                    # Set the component getting installed.
                    if(NOT CMAKE_INSTALL_COMPONENT)
                      if(COMPONENT)
                        message(STATUS "Install component: \"${COMPONENT}\"")
                        set(CMAKE_INSTALL_COMPONENT "${COMPONENT}")
                      else()
                        set(CMAKE_INSTALL_COMPONENT)
                      endif()
                    endif()
                    
                    # Install shared libraries without execute permission?
                    if(NOT DEFINED CMAKE_INSTALL_SO_NO_EXE)
                      set(CMAKE_INSTALL_SO_NO_EXE "1")
                    endif()
                    
                    # Is this installation the result of a crosscompile?
                    if(NOT DEFINED CMAKE_CROSSCOMPILING)
                      set(CMAKE_CROSSCOMPILING "TRUE")
                      set(CMAKE_SYSTEM_NAME Android)
                    set(CMAKE_SYSTEM_VERSION 24) # API level
                    set(CMAKE_ANDROID_ARCH_ABI armeabi-v7a)
                    set(CMAKE_ANDROID_NDK /home/nivilwilsonp/Android/Sdk/ndk/21.3.6528147)
                    set(CMAKE_ANDROID_STL_TYPE gnustl_static)
                    endif()
                    
                    if("x${CMAKE_INSTALL_COMPONENT}x" STREQUAL "xUnspecifiedx" OR NOT CMAKE_INSTALL_COMPONENT)
                      foreach(file
                          "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libpoppler.so.108.0.0"
                          "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libpoppler.so.108"
                          )
                        if(EXISTS "${file}" AND
                           NOT IS_SYMLINK "${file}")
                          file(RPATH_CHECK
                               FILE "${file}"
                               RPATH "")
                        endif()
                      endforeach()
                      file(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib" TYPE SHARED_LIBRARY FILES
                        "/home/nivilwilsonp/Pictures/poppler-21.03.0/build/libpoppler.so.108.0.0"
                        "/home/nivilwilsonp/Pictures/poppler-21.03.0/build/libpoppler.so.108"
                        )
                      foreach(file
                          "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libpoppler.so.108.0.0"
                          "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libpoppler.so.108"
                          )
                        if(EXISTS "${file}" AND
                           NOT IS_SYMLINK "${file}")
                          if(CMAKE_INSTALL_DO_STRIP)
                            execute_process(COMMAND "/usr/bin/strip" "${file}")
                          endif()
                        endif()
                      endforeach()
                    endif()
                    
                    if("x${CMAKE_INSTALL_COMPONENT}x" STREQUAL "xUnspecifiedx" OR NOT CMAKE_INSTALL_COMPONENT)
                      if(EXISTS "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libpoppler.so" AND
                         NOT IS_SYMLINK "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libpoppler.so")
                        file(RPATH_CHECK
                             FILE "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libpoppler.so"
                             RPATH "")
                      endif()
                      file(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib" TYPE SHARED_LIBRARY FILES "/home/nivilwilsonp/Pictures/poppler-21.03.0/build/libpoppler.so")
                      if(EXISTS "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libpoppler.so" AND
                         NOT IS_SYMLINK "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libpoppler.so")
                        if(CMAKE_INSTALL_DO_STRIP)
                          execute_process(COMMAND "/usr/bin/strip" "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/libpoppler.so")
                        endif()
                      endif()
                    endif()
                    
                    if("x${CMAKE_INSTALL_COMPONENT}x" STREQUAL "xUnspecifiedx" OR NOT CMAKE_INSTALL_COMPONENT)
                      file(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib/pkgconfig" TYPE FILE FILES "/home/nivilwilsonp/Pictures/poppler-21.03.0/build/poppler.pc")
                    endif()
                    
                    if("x${CMAKE_INSTALL_COMPONENT}x" STREQUAL "xUnspecifiedx" OR NOT CMAKE_INSTALL_COMPONENT)
                      file(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib/pkgconfig" TYPE FILE FILES "/home/nivilwilsonp/Pictures/poppler-21.03.0/build/poppler-qt5.pc")
                    endif()
                    
                    if("x${CMAKE_INSTALL_COMPONENT}x" STREQUAL "xUnspecifiedx" OR NOT CMAKE_INSTALL_COMPONENT)
                      file(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib/pkgconfig" TYPE FILE FILES "/home/nivilwilsonp/Pictures/poppler-21.03.0/build/poppler-cpp.pc")
                    endif()
                    
                    if(NOT CMAKE_INSTALL_LOCAL_ONLY)
                      # Include the install script for each subdirectory.
                      include("/home/nivilwilsonp/Pictures/poppler-21.03.0/build/utils/cmake_install.cmake")
                      include("/home/nivilwilsonp/Pictures/poppler-21.03.0/build/test/cmake_install.cmake")
                      include("/home/nivilwilsonp/Pictures/poppler-21.03.0/build/qt5/cmake_install.cmake")
                      include("/home/nivilwilsonp/Pictures/poppler-21.03.0/build/cpp/cmake_install.cmake")
                    
                    endif()
                    
                    if(CMAKE_INSTALL_COMPONENT)
                      set(CMAKE_INSTALL_MANIFEST "install_manifest_${CMAKE_INSTALL_COMPONENT}.txt")
                    else()
                      set(CMAKE_INSTALL_MANIFEST "install_manifest.txt")
                    endif()
                    
                    string(REPLACE ";" "\n" CMAKE_INSTALL_MANIFEST_CONTENT
                           "${CMAKE_INSTALL_MANIFEST_FILES}")
                    file(WRITE "/home/nivilwilsonp/Pictures/poppler-21.03.0/build/${CMAKE_INSTALL_MANIFEST}"
                         "${CMAKE_INSTALL_MANIFEST_CONTENT}")
                    
                    1 Reply Last reply
                    0
                    • SGaistS Offline
                      SGaistS Offline
                      SGaist
                      Lifetime Qt Champion
                      wrote on 29 Mar 2021, 18:13 last edited by
                      #10

                      Hi,

                      I would avoid putting a library like that built for a different architecture/OS in such a generic path. You should store in an explicit dedicated folder.

                      Interested in AI ? www.idiap.ch
                      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                      N 1 Reply Last reply 3 Apr 2021, 05:43
                      1
                      • N NIvil Wilson
                        29 Mar 2021, 07:26

                        @jsulm
                        after building poppler for android it shows the same errror
                        skipping incompatible /usr/local/lib//libpoppler-qt5.so when searching for -lpoppler-qt5.

                        J Offline
                        J Offline
                        jsulm
                        Lifetime Qt Champion
                        wrote on 30 Mar 2021, 05:37 last edited by
                        #11

                        @NIvil-Wilson said in How do i use poppler lib in Qt quick application.:

                        skipping incompatible /usr/local/lib//libpoppler-qt5.so when searching for -lpoppler-qt5.

                        This error clearly states that /usr/local/lib//libpoppler-qt5.so is not compatible with what you are building.
                        Do

                        file /usr/local/lib//libpoppler-qt5.so
                        

                        and post its output here.

                        https://forum.qt.io/topic/113070/qt-code-of-conduct

                        N 1 Reply Last reply 1 Apr 2021, 11:18
                        0
                        • J jsulm
                          30 Mar 2021, 05:37

                          @NIvil-Wilson said in How do i use poppler lib in Qt quick application.:

                          skipping incompatible /usr/local/lib//libpoppler-qt5.so when searching for -lpoppler-qt5.

                          This error clearly states that /usr/local/lib//libpoppler-qt5.so is not compatible with what you are building.
                          Do

                          file /usr/local/lib//libpoppler-qt5.so
                          

                          and post its output here.

                          N Offline
                          N Offline
                          NIvil Wilson
                          wrote on 1 Apr 2021, 11:18 last edited by
                          #12

                          @jsulm said in How do i use poppler lib in Qt quick application.:

                          file /usr/local/lib//libpoppler-qt5.so

                          /usr/local/lib//libpoppler-qt5.so: symbolic link to libpoppler-qt5.so.1

                          J 1 Reply Last reply 1 Apr 2021, 11:34
                          0
                          • N NIvil Wilson
                            1 Apr 2021, 11:18

                            @jsulm said in How do i use poppler lib in Qt quick application.:

                            file /usr/local/lib//libpoppler-qt5.so

                            /usr/local/lib//libpoppler-qt5.so: symbolic link to libpoppler-qt5.so.1

                            J Offline
                            J Offline
                            jsulm
                            Lifetime Qt Champion
                            wrote on 1 Apr 2021, 11:34 last edited by
                            #13

                            @NIvil-Wilson Then do

                            file /usr/local/lib//libpoppler-qt5.so.1
                            

                            https://forum.qt.io/topic/113070/qt-code-of-conduct

                            N 1 Reply Last reply 3 Apr 2021, 05:40
                            0
                            • J jsulm
                              1 Apr 2021, 11:34

                              @NIvil-Wilson Then do

                              file /usr/local/lib//libpoppler-qt5.so.1
                              
                              N Offline
                              N Offline
                              NIvil Wilson
                              wrote on 3 Apr 2021, 05:40 last edited by
                              #14

                              @jsulm
                              sir,
                              the result for the command file /usr/local/lib//libpoppler-qt5.so.1 is
                              /usr/local/lib//libpoppler-qt5.so.1: symbolic link to libpoppler-qt5.so.1.27.0

                              SGaistS 1 Reply Last reply 3 Apr 2021, 06:49
                              0
                              • SGaistS SGaist
                                29 Mar 2021, 18:13

                                Hi,

                                I would avoid putting a library like that built for a different architecture/OS in such a generic path. You should store in an explicit dedicated folder.

                                N Offline
                                N Offline
                                NIvil Wilson
                                wrote on 3 Apr 2021, 05:43 last edited by
                                #15

                                @SGaist
                                sir, i tried that too but the same problem occurs

                                1 Reply Last reply
                                0
                                • N NIvil Wilson
                                  3 Apr 2021, 05:40

                                  @jsulm
                                  sir,
                                  the result for the command file /usr/local/lib//libpoppler-qt5.so.1 is
                                  /usr/local/lib//libpoppler-qt5.so.1: symbolic link to libpoppler-qt5.so.1.27.0

                                  SGaistS Offline
                                  SGaistS Offline
                                  SGaist
                                  Lifetime Qt Champion
                                  wrote on 3 Apr 2021, 06:49 last edited by
                                  #16

                                  @NIvil-Wilson said in How do i use poppler lib in Qt quick application.:

                                  @jsulm
                                  sir,
                                  the result for the command file /usr/local/lib//libpoppler-qt5.so.1 is
                                  /usr/local/lib//libpoppler-qt5.so.1: symbolic link to libpoppler-qt5.so.1.27.0

                                  Check that file then.

                                  Did you ensure that cmake is finding your cross-compiled version and not the one from your system ?

                                  Interested in AI ? www.idiap.ch
                                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                  N 1 Reply Last reply 15 Apr 2021, 14:58
                                  0
                                  • SGaistS SGaist
                                    3 Apr 2021, 06:49

                                    @NIvil-Wilson said in How do i use poppler lib in Qt quick application.:

                                    @jsulm
                                    sir,
                                    the result for the command file /usr/local/lib//libpoppler-qt5.so.1 is
                                    /usr/local/lib//libpoppler-qt5.so.1: symbolic link to libpoppler-qt5.so.1.27.0

                                    Check that file then.

                                    Did you ensure that cmake is finding your cross-compiled version and not the one from your system ?

                                    N Offline
                                    N Offline
                                    NIvil Wilson
                                    wrote on 15 Apr 2021, 14:58 last edited by
                                    #17

                                    @SGaist
                                    sir,
                                    yes i ensured that the cmake is finding cross-compiled version and not the one from the system .
                                    i stored the cross-compiled version in an explicit dedicated folder and the same message appears.
                                    please help

                                    1 Reply Last reply
                                    0
                                    • SGaistS Offline
                                      SGaistS Offline
                                      SGaist
                                      Lifetime Qt Champion
                                      wrote on 15 Apr 2021, 18:26 last edited by
                                      #18

                                      Did you check the architecture of your cross-compiled library ?

                                      Interested in AI ? www.idiap.ch
                                      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                      N 1 Reply Last reply 18 Apr 2021, 04:50
                                      0
                                      • SGaistS SGaist
                                        15 Apr 2021, 18:26

                                        Did you check the architecture of your cross-compiled library ?

                                        N Offline
                                        N Offline
                                        NIvil Wilson
                                        wrote on 18 Apr 2021, 04:50 last edited by
                                        #19

                                        @SGaist
                                        sir ,
                                        the architecture of cross-compiled library is given below.

                                        readelf -h libpoppler-qt5.so.1.27.0
                                        ELF Header:
                                        Magic: 7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00
                                        Class: ELF64
                                        Data: 2's complement, little endian
                                        Version: 1 (current)
                                        OS/ABI: UNIX - System V
                                        ABI Version: 0
                                        Type: DYN (Shared object file)
                                        Machine: Advanced Micro Devices X86-64
                                        Version: 0x1
                                        Entry point address: 0x334f0
                                        Start of program headers: 64 (bytes into file)
                                        Start of section headers: 14323992 (bytes into file)
                                        Flags: 0x0
                                        Size of this header: 64 (bytes)
                                        Size of program headers: 56 (bytes)
                                        Number of program headers: 11
                                        Size of section headers: 64 (bytes)
                                        Number of section headers: 39
                                        Section header string table index: 38

                                        1 Reply Last reply
                                        0
                                        • SGaistS Offline
                                          SGaistS Offline
                                          SGaist
                                          Lifetime Qt Champion
                                          wrote on 18 Apr 2021, 07:05 last edited by
                                          #20

                                          @NIvil-Wilson said in How do i use poppler lib in Qt quick application.:

                                          Machine: Advanced Micro Devices X86-64

                                          Is your device running on a x86_64 machine ?

                                          Interested in AI ? www.idiap.ch
                                          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                          N 1 Reply Last reply 18 Apr 2021, 16:09
                                          0

                                          • Login

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • Users
                                          • Groups
                                          • Search
                                          • Get Qt Extensions
                                          • Unsolved