The following issue has been SUBMITTED. 
====================================================================== 
http://public.kitware.com/Bug/view.php?id=13794 
====================================================================== 
Reported By:                Tobias Pfaff
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   13794
Category:                   CMake
Reproducibility:            always
Severity:                   major
Priority:                   high
Status:                     new
====================================================================== 
Date Submitted:             2012-12-13 19:47 EST
Last Modified:              2012-12-13 19:47 EST
====================================================================== 
Summary:                    find_package(PythonLibs) finds different version of
Python headers and libraries
Description: 
PythonLibs returns inconsistent versions for lib and include dir:
PYTHON_INCLUDE_DIR = /usr/include/python2.7
PYTHON_LIBRARIES = /usr/lib/python3.2/config/libpython3.2.so
resulting in linker errors. 
The latter is probably the culprit, see cmake output:

Found PythonLibs: /usr/lib/python3.2/config/libpython3.2.so (found version
"2.7.3") 

The 2.7 version is in /usr/lib/python2.7/config/libpython2.7.so

This problem is probably specific to Ubuntu 12.10. It ships with 3.2 libraries
on default, but no headers (unless you install python3-dev). It applies to both
cmake version 2.8.9 (which comes with the distribution) and the newest 2.8.10.2.

I have not found a workaround yet -- apart from directly specifying the
directories, which is not an option as I am distributing my code, and it should
run on all client configurations.
Python_ADDITIONAL_VERSIONS  e.g. do not help.

Steps to Reproduce: 
find_package(PythonLibs REQUIRED)
message(${PYTHON_INCLUDE_DIRS})
message(${PYTHON_LIBRARIES})

on Ubuntu 12.10, with package python-dev installed (but python3-dev NOT
installed)
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2012-12-13 19:47 Tobias Pfaff   New Issue                                    
======================================================================

--

Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers

Reply via email to