Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 430858 - net-libs/libkolabxml-0.8.0[php] fails to build: Could NOT find PHP4 (missing: PHP4_INCLUDE_PATH), possible failure in FindPHP4.cmake?
Summary: net-libs/libkolabxml-0.8.0[php] fails to build: Could NOT find PHP4 (missing:...
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo KDE team
URL: http://public.kitware.com/Bug/view.ph...
Whiteboard: tracking upstream
Keywords:
Depends on:
Blocks:
 
Reported: 2012-08-11 00:45 UTC by Travis Hansen
Modified: 2016-10-29 19:10 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
libkolabxml-0.8.4-php-include-dir.patch (libkolabxml-0.8.4-php-include-dir.patch,1.17 KB, patch)
2013-05-22 15:38 UTC, Chris Reffett (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Travis Hansen 2012-08-11 00:45:44 UTC
>>> Emerging (25 of 28) net-libs/libkolabxml-0.8.0
 * libkolabxml-0.8.0.tar.gz SHA256 SHA512 WHIRLPOOL size ;-) ...                                                                                                                                                                      [ ok ]
>>> Unpacking source...
>>> Unpacking libkolabxml-0.8.0.tar.gz to /var/tmp/portage/net-libs/libkolabxml-0.8.0/work
>>> Source unpacked in /var/tmp/portage/net-libs/libkolabxml-0.8.0/work
>>> Preparing source in /var/tmp/portage/net-libs/libkolabxml-0.8.0/work/libkolabxml-0.8.0 ...
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/net-libs/libkolabxml-0.8.0/work/libkolabxml-0.8.0 ...
>>> Working in BUILD_DIR: "/var/tmp/portage/net-libs/libkolabxml-0.8.0/work/libkolabxml-0.8.0_build"
cmake --no-warn-unused-cli -C /var/tmp/portage/net-libs/libkolabxml-0.8.0/work/libkolabxml-0.8.0_build/gentoo_common_config.cmake -DCMAKE_INSTALL_PREFIX=/usr -DCSHARP_BINDINGS=OFF -DJAVA_BINDINGS=ON -DPYTHON_BINDINGS=ON -DPHP_BINDINGS=ON -DBUILD_TESTS=OFF -DCMAKE_BUILD_TYPE=Gentoo -DCMAKE_INSTALL_DO_STRIP=OFF -DCMAKE_USER_MAKE_RULES_OVERRIDE=/var/tmp/portage/net-libs/libkolabxml-0.8.0/work/libkolabxml-0.8.0_build/gentoo_rules.cmake  /var/tmp/portage/net-libs/libkolabxml-0.8.0/work/libkolabxml-0.8.0
Not searching for unused variables given on the command line.
loading initial cache file /var/tmp/portage/net-libs/libkolabxml-0.8.0/work/libkolabxml-0.8.0_build/gentoo_common_config.cmake
Building DIST targets (make dist, make snapshot)
-- The CXX compiler identification is GNU 4.6.3
-- Check for working CXX compiler: /usr/bin/x86_64-pc-linux-gnu-g++
-- Check for working CXX compiler: /usr/bin/x86_64-pc-linux-gnu-g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Boost version: 1.49.0
-- Found the following Boost libraries:
--   thread
--   system
Found boost in /usr/include/boost-1_49
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.27") 
-- Found XSDCXX: /usr/bin/xsdcxx  
-- Found Xerces: /usr/lib64/libxerces-c.so  
-- Found Curl: /usr/lib64/libcurl.so  
SWIG found
-- Found LibkolabxmlDependencies: TRUE  
building java bindings
building python bindings
-- Found PythonLibs: /usr/lib64/libpython2.7.so (found version "2.7.3") 
found python include dirs: /usr/include/python2.7 /usr/include/python2.7
building php bindings
CMake Error at /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:97 (MESSAGE):
  Could NOT find PHP4 (missing: PHP4_INCLUDE_PATH) (Required is at least
  version "5.3")
Call Stack (most recent call first):
  /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:288 (_FPHSA_FAILURE_MESSAGE)
  /usr/share/cmake/Modules/FindPHP4.cmake:85 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  src/php/CMakeLists.txt:23 (find_package)


Reproducible: Always
Comment 1 Chris Reffett (RETIRED) gentoo-dev Security 2012-08-11 03:00:16 UTC
Issue here is a failure on the part of the FindPHP4.cmake, since it does not find the PHP includes and such correctly (it looks in /usr/include/php and a couple other places in /usr/include, whereas the includes are located in /usr/lib/php5.4. Not sure if that applies in 5.3.
Comment 2 Paul Klos 2012-08-11 13:42:07 UTC
It does.

I'm running PHP 5.3:

# php --version
PHP 5.3.15-pl0-gentoo with Suhosin-Patch (cli) (built: Aug  1 2012 10:46:16) 
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
    with Xdebug v2.1.2, Copyright (c) 2002-2011, by Derick Rethans


I'm getting the same error building libkolabxml.
Comment 3 Chris Reffett (RETIRED) gentoo-dev Security 2012-08-13 22:20:38 UTC
So basically, the FindPHP4 cmake module is completely broken. Excellent. Will put this on the to-do list for the next KDE meeting for opinions on what to do about this.
Comment 4 Paul Klos 2012-09-30 12:15:03 UTC
FWIW at least I got libkolabxml to build correctly by adding

/usr/lib/php5.4/include/php

to

SET(PHP4_POSSIBLE_INCLUDE_PATHS

in/usr/share/cmake/Modules/FindPHP4.cmake

Obviously this is a hack that probably isn't upgrade-safe, but for now it works.
Comment 5 Chris Reffett (RETIRED) gentoo-dev Security 2012-11-27 04:58:49 UTC
Note: libkolab and libkolabxml have php in package.use.mask now to get around this, but leaving this open until there's some sort of fix available.
Comment 6 Michael Palimaka (kensington) gentoo-dev 2013-03-18 17:18:11 UTC
This should be fixed upstream in the next release:

http://git.kolab.org/libkolabxml/commit/?h=libkolabxml-0.8&id=4e7f91b63500423565eb346a4f691753626795a9
Comment 7 Johannes Huber (RETIRED) gentoo-dev 2013-05-10 16:13:24 UTC
New version is in tree.

+  10 May 2013; Johannes Huber <johu@gentoo.org> +libkolabxml-0.8.4.ebuild,
+  metadata.xml:
+  Version bump.

I have moved the php use mask for easier testing to stable only.

At least it builds with php enabled, but seems not fully fixed:

building php bindings
CMake Warning at src/php/CMakeLists.txt:72 (message):
  not building php bindings because php was not found
Comment 8 Chris Reffett (RETIRED) gentoo-dev Security 2013-05-22 15:38:47 UTC
Created attachment 348928 [details, diff]
libkolabxml-0.8.4-php-include-dir.patch

Two steps forward, one step back: this patch makes it build with PHP (basically, it was looking in /usr/include for php includes, but our php includes are in /usr/lib64/php-5.x, so this makes it use php-config to find the right include dir), but it now has a build failure that I can't pin down.
Comment 9 alexander haensch 2013-07-11 12:35:48 UTC
i solved it by adding a symlink

ln -s /usr/lib/php/include/php php

because cmake's FINDPHP4 method is highly outdated.
Best would be to add a line in a cmake specific patch
Comment 10 Rolf Eike Beer archtester 2013-08-24 19:47:11 UTC
(In reply to Chris Reffett from comment #8)
> Created attachment 348928 [details, diff] [details, diff]
> libkolabxml-0.8.4-php-include-dir.patch

Use execute_process(... OUTPUT_STRIP_TRAILING_WHITESPACE) to get rid of the trailing newline.
Comment 11 Brian Evans (RETIRED) gentoo-dev 2016-10-19 13:37:51 UTC
libkolab an libkolabxml should leverage the php-ext-source-r3 eclass if possible.  The PHP slots allow installs of multiple PHP targets and extensions must be built for each independently.
Comment 12 Michael Palimaka (kensington) gentoo-dev 2016-10-19 13:39:04 UTC
Nobody has touched these kolab packages in years I would suggest dropping them once kdepim:4 leaves the tree.
Comment 13 Michael Palimaka (kensington) gentoo-dev 2016-10-29 19:10:12 UTC
kolab is being removed