Hi David,

BTW, I notice that other FIND_PATH macro search
  - ${headername}
  - lib${shortname}/${headername}
  - ffmpeg/${headername}
 in
  - /usr/local/include
  - /usr/include

but ffmpeg plugin use <avcodec.h>, so cmake have to search avcodec.h in
  - /usr/include/
  - /usr/include/lib${shortname}
  - /usr/include/ffmpeg
  - /usr/include/ffmpeg/lib${shortname}

Am i wrong ?

Check src/osgPlugins/ffmpeg/CMakeLists.txt, you will see lines like this:

    INCLUDE_DIRECTORIES(
        ${FFMPEG_LIBAVFORMAT_INCLUDE_DIRS}
        ${FFMPEG_LIBAVFORMAT_INCLUDE_DIRS}/libavformat
        ${FFMPEG_LIBAVFORMAT_INCLUDE_DIRS}/ffmpeg
        ...

That means that the three cases in FIND_PATH are added to the lib path.

In your case, you would need to add ffmpeg/lib${shortname}/${headername} to the FIND_PATH macro, and ${FFMPEG_LIBAVFORMAT_INCLUDE_DIRS}/ffmpeg/libavformat to the INCLUDE_DIRECTORIES... Or we could just make it search for ${headername} and use the complete directory it finds it in to the INCLUDE_DIRECTORIES, so we can add new cases to a single place instead of two places.

J-S
--
______________________________________________________
Jean-Sebastien Guay    [email protected]
                               http://www.cm-labs.com/
                        http://whitestar02.webhop.org/
_______________________________________________
osg-submissions mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org

Reply via email to