libcv-dev: error: 'ptrdiff_t' does not name a type

Bug #791527 reported by Jose Luis Blanco-Claraco
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenCV Manager
New
Undecided
Unassigned
opencv (Debian)
Fix Released
Unknown
opencv (Ubuntu)
Fix Released
High
Unassigned

Bug Description

Not only the package itself fails to build, but any other package depending on libcv-dev also fails with the new g++ with this error:

error: 'ptrdiff_t' does not name a type

The solution is very simple: to add an #include <stddef.h> to /usr/include/opencv/cxcore.hpp.

Please, could any maintainer patch this package?

An equivalent bug was already reported in Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=624917

Thanks,
Jose Luis

Related branches

Changed in opencv (Ubuntu):
importance: Undecided → High
status: New → Triaged
Revision history for this message
Gal Shalif (gal-fourier) wrote :

See a proposed fix at: LP: #791527

Revision history for this message
Gal Shalif (gal-fourier) wrote :

Note on of testing of fix for LP: #791527 :
 * The new FFmpeg sources from Ubuntu 11.10 Oneiric do NOT compile against the OpenCV package (that is 2.1)
However, testing was OK with:
 * Ubuntu 11.04 Natty gcc 4.5
 * Ubuntu 11.10 Oneiric gcc 4.6 while using the old Ffmpeg sources from Ubuntu 11.04 Natty

Revision history for this message
Gal Shalif (gal-fourier) wrote :

More notes on testing of fix for LP: #791527:

After fixing the ptrdiff_t error above - we get more build errors of the OpenCV package on Ubuntu 11.10 Oneiric because of:

1. The OpenCV 2.1 version is used
2. The new FFmpeg 0.7 version is used
3. OpenCV version 2.1 do not compile against the new FFmpeg version 0.7

AFAIK, the latest SVN version of OpenCV do not either compile against the new ffmpeg 0.7 and it is likely that the OpenCV developers will have to modify the OpenCV sources to allow a build against the new ffmpeg 0.7.

Revision history for this message
Gal Shalif (gal-fourier) wrote :

Verify that latest OpenCV-2.3.0rc.tar.bz2 (released on 2011-06-21) do also have compilation errors when compiled against Ffmpeg0.7 from Ubuntu 11.10 oneiric (OpenCV-2.3.0rc.tar.bz2 is available from http://sourceforge.net/projects/opencvlibrary/)

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package opencv - 2.1.0-3ubuntu2

---------------
opencv (2.1.0-3ubuntu2) oneiric; urgency=low

  [ Reinhard Tartler ]
  * enable parallel builds

  [ Gal Shalif (Work at Fourier Systems) ]
  * Add patch ubuntu11.04_no_videodev.h_include_file.patch
    - fix build error on Ubuntu 11.04 Natty (LP: #756154):
    - Backport the upstream 2.2 changeset to void the use
      of the obsolete V4L1 (linux/videodev.h)
  * Add patch ubuntu11.10_oneiric_fix_compilation_error_with_gcc4.6.patch
      - fix build error on Ubuntu 11.10 Oneiric (LP: #791527):
  * Add cvcap_ffmpeg_fix_compile_against_libav0.7.patch
      - fix compilation errors when compiled against libav-0.7
        (as applicable for Ubuntu 11.10 Oneiric) (LP: #756154)
 -- Gal Shalif (Work at Fourier Systems) <email address hidden> Thu, 07 Jul 2011 10:25:00 +0300

Changed in opencv (Ubuntu):
status: Triaged → Fix Released
Changed in opencv (Debian):
status: Unknown → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.