Bug 360812

Summary: CMake fails to Locate poppler-qt4
Product: [Applications] okular Reporter: Gianni <nasus.maximos>
Component: PDF backendAssignee: Okular developers <okular-devel>
Status: RESOLVED FIXED    
Severity: major CC: aacid
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Gentoo Packages   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: patch that fixes the syntax issue.

Description Gianni 2016-03-21 13:42:06 UTC
A syntax error in FindPoppler.cmake causes CMake to not locate Poppler.

Reproducible: Always

Steps to Reproduce:
1. cmake ../source_dir

Actual Results:  
-- checking for module 'poppler-qt4'
--   found poppler-qt4, version 0.32.0
-- Performing Test HAVE_POPPLER_0_12_1
-- Performing Test HAVE_POPPLER_0_12_1 - Success
-- Performing Test HAVE_POPPLER_0_16
-- Performing Test HAVE_POPPLER_0_16 - Success
-- Performing Test HAVE_POPPLER_0_20
-- Performing Test HAVE_POPPLER_0_20 - Success
-- Performing Test HAVE_POPPLER_0_22
-- Performing Test HAVE_POPPLER_0_22 - Success
-- Performing Test HAVE_POPPLER_0_24
-- Performing Test HAVE_POPPLER_0_24 - Success
-- Performing Test HAVE_POPPLER_0_28
-- Performing Test HAVE_POPPLER_0_28 - Success
-- Performing Test HAVE_POPPLER_0_37
-- Performing Test HAVE_POPPLER_0_37 - Failed
CMake Warning (dev) at /usr/share/apps/cmake/modules/MacroOptionalFindPackage.cmake:32 (find_package):
  A logical block opening on the line

    /var/tmp/portage/kde-apps/okular-15.12.3/work/okular-15.12.3/cmake/modules/FindPoppler.cmake:149 (if)

  closes on the line

    /var/tmp/portage/kde-apps/okular-15.12.3/work/okular-15.12.3/cmake/modules/FindPoppler.cmake:165 (endif)

  with mis-matching arguments.
Call Stack (most recent call first):
  generators/CMakeLists.txt:5 (macro_optional_find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.


Expected Results:  
-- checking for module 'poppler-qt4'
--   found poppler-qt4, version 0.32.0
-- Performing Test HAVE_POPPLER_0_12_1
-- Performing Test HAVE_POPPLER_0_12_1 - Success
-- Performing Test HAVE_POPPLER_0_16
-- Performing Test HAVE_POPPLER_0_16 - Success
-- Performing Test HAVE_POPPLER_0_20
-- Performing Test HAVE_POPPLER_0_20 - Success
-- Performing Test HAVE_POPPLER_0_22
-- Performing Test HAVE_POPPLER_0_22 - Success
-- Performing Test HAVE_POPPLER_0_24
-- Performing Test HAVE_POPPLER_0_24 - Success
-- Performing Test HAVE_POPPLER_0_28
-- Performing Test HAVE_POPPLER_0_28 - Success
-- Performing Test HAVE_POPPLER_0_37
-- Performing Test HAVE_POPPLER_0_37 - Failed
-- Found Poppler-Qt4: /usr/lib64/libpoppler-qt4.so, (>= 0.28)
Comment 1 Gianni 2016-03-21 13:43:09 UTC
Created attachment 98005 [details]
patch that fixes the syntax issue.
Comment 2 Gianni 2016-03-21 13:43:49 UTC
cmake version 3.3.1
Comment 3 Albert Astals Cid 2016-03-21 22:10:05 UTC
Thanks for the report, this was fixed 19 days ago https://github.com/KDE/okular/commit/425dc7d948574237fd0dad216be553ca5ee90e53 and will be on next release.