Skip to content
Snippets Groups Projects
Commit 1482952c authored by Fernando Herrero's avatar Fernando Herrero
Browse files

Update library name from firewire to firewire_camera

parent 429ecab0
No related branches found
No related tags found
No related merge requests found
......@@ -7,7 +7,7 @@ if(COMMAND cmake_policy)
endif(COMMAND cmake_policy)
# The project name and the type of project
PROJECT(firewire)
PROJECT(firewire_camera)
SET(CPACK_PACKAGE_VERSION "1.0.0")
SET(CPACK_PACKAGE_VERSION_MAJOR "1")
SET(CPACK_PACKAGE_VERSION_MINOR "0")
......
FIND_PATH(firewire_INCLUDE_DIR firewirecamera.h firewireserver.h firewireexceptions.h /usr/include/iri/firewire /usr/local/include/iri/firewire)
FIND_LIBRARY(firewire_LIBRARY
NAMES firewire
PATHS /usr/lib /usr/lib/iri/firewire /usr/local/lib /usr/local/lib/iri/firewire)
SET(firewire_INCLUDE_DIRS ${firewire_INCLUDE_DIR})
SET(firewire_LIBRARIES ${firewire_LIBRARY})
IF (firewire_INCLUDE_DIR AND firewire_LIBRARY)
SET(firewire_FOUND TRUE)
ENDIF (firewire_INCLUDE_DIR AND firewire_LIBRARY)
IF (firewire_FOUND)
IF (NOT firewire_FIND_QUIETLY)
MESSAGE(STATUS "Found firewire camera driver: ${firewire_LIBRARY}")
ENDIF (NOT firewire_FIND_QUIETLY)
ELSE (firewire_FOUND)
IF (firewire_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find firewire camera driver")
ENDIF (firewire_FIND_REQUIRED)
ENDIF (firewire_FOUND)
FIND_PATH(firewire_camera_INCLUDE_DIRS firewirecamera.h firewireserver.h firewireexceptions.h /usr/include/iri/firewire_camera /usr/local/include/iri/firewire_camera)
FIND_LIBRARY(firewire_camera_LIBRARIES
NAMES firewire_camera
PATHS /usr/lib /usr/lib/iri/firewire_camera /usr/local/lib /usr/local/lib/iri/firewire_camera)
SET(firewire_camera_INCLUDE_DIR ${firewire_camera_INCLUDE_DIRS})
SET(firewire_camera_LIBRARY ${firewire_camera_LIBRARIES})
IF (firewire_camera_INCLUDE_DIRS AND firewire_camera_LIBRARIES)
SET(firewire_camera_FOUND TRUE)
ENDIF (firewire_camera_INCLUDE_DIRS AND firewire_camera_LIBRARIES)
IF (firewire_camera_FOUND)
IF (NOT firewire_camera_FIND_QUIETLY)
MESSAGE(STATUS "Found firewire_camera camera driver: ${firewire_camera_LIBRARIES}")
ENDIF (NOT firewire_camera_FIND_QUIETLY)
ELSE (firewire_camera_FOUND)
IF (firewire_camera_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find firewire_camera camera driver")
ENDIF (firewire_camera_FIND_REQUIRED)
ENDIF (firewire_camera_FOUND)
\ No newline at end of file
......@@ -23,36 +23,36 @@ endif(OpenCV_FOUND)
FIND_PACKAGE(iriutils REQUIRED)
# try to find the raw1394 dc1394 2.0 library
FIND_PATH(raw1394_INCLUDE_DIR libraw1394/raw1394.h /usr/include /usr/local/include)
FIND_PATH(dc1394_INCLUDE_DIR dc1394/control.h /usr/include /usr/local/include)
FIND_PATH(raw1394_INCLUDE_DIRS libraw1394/raw1394.h /usr/include /usr/local/include)
FIND_PATH(dc1394_INCLUDE_DIRS dc1394/control.h /usr/include /usr/local/include)
FIND_LIBRARY(raw1394_LIBRARY
FIND_LIBRARY(raw1394_LIBRARIES
NAMES raw1394
PATHS /usr/lib /usr/local/lib)
FIND_LIBRARY(dc1394_LIBRARY
FIND_LIBRARY(dc1394_LIBRARIES
NAMES dc1394
PATHS /usr/lib /usr/local/lib)
IF (raw1394_INCLUDE_DIR AND raw1394_LIBRARY AND dc1394_INCLUDE_DIR AND dc1394_LIBRARY)
SET(firewire_ready TRUE)
ENDIF (raw1394_INCLUDE_DIR AND raw1394_LIBRARY AND dc1394_INCLUDE_DIR AND dc1394_LIBRARY)
IF (raw1394_INCLUDE_DIRS AND raw1394_LIBRARIES AND dc1394_INCLUDE_DIRS AND dc1394_LIBRARIES)
SET(firewire_camera_ready TRUE)
ENDIF (raw1394_INCLUDE_DIRS AND raw1394_LIBRARIES AND dc1394_INCLUDE_DIRS AND dc1394_LIBRARIES)
IF (firewire_ready)
IF (firewire_camera_ready)
MESSAGE(STATUS "The system is libdc 2.0 capable")
# add all the necessary include directories (project_name_INDLUDE_DIR)
INCLUDE_DIRECTORIES(${iriutils_INCLUDE_DIR} ${dc1394_INCLUDE_DIR} ${raw1394_INCLUDE_DIR} .)
INCLUDE_DIRECTORIES(${iriutils_INCLUDE_DIR} ${dc1394_INCLUDE_DIRS} ${raw1394_INCLUDE_DIRS} .)
ADD_LIBRARY(firewire SHARED ${sources})
ADD_LIBRARY(firewire_camera SHARED ${sources})
#if CV then add the libraries
if (USE_CV)
TARGET_LINK_LIBRARIES(firewire ${OpenCV_LIBS} ${iriutils_LIBRARY} ${dc1394_LIBRARY} ${raw1394_LIBRARY})
TARGET_LINK_LIBRARIES(firewire_camera ${OpenCV_LIBS} ${iriutils_LIBRARY} ${dc1394_LIBRARIES} ${raw1394_LIBRARIES})
INCLUDE_DIRECTORIES(${OpenCV_INCLUDE_DIRS})
else(USE_CV)
TARGET_LINK_LIBRARIES(firewire ${iriutils_LIBRARY} ${dc1394_LIBRARY} ${raw1394_LIBRARY})
TARGET_LINK_LIBRARIES(firewire_camera ${iriutils_LIBRARY} ${dc1394_LIBRARIES} ${raw1394_LIBRARIES})
endif(USE_CV)
INSTALL(TARGETS firewire
INSTALL(TARGETS firewire_camera
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib/iri/${PROJECT_NAME}
ARCHIVE DESTINATION lib/iri/${PROJECT_NAME}
......@@ -60,10 +60,10 @@ IF (firewire_ready)
INSTALL(FILES ${headers} DESTINATION include/iri/${PROJECT_NAME})
INSTALL(FILES ../Findfirewire.cmake DESTINATION ${CMAKE_ROOT}/Modules/)
INSTALL(FILES ../Findfirewire_camera.cmake DESTINATION ${CMAKE_ROOT}/Modules/)
ADD_SUBDIRECTORY(examples)
ELSE (firewire_ready)
ELSE (firewire_camera_ready)
MESSAGE(FATAL_ERROR "The system is not libdc 2.0 capable")
ENDIF (firewire_ready)
ENDIF (firewire_camera_ready)
......@@ -3,41 +3,41 @@
# edit the following line to add the source code for the example and the name of the executable
ADD_EXECUTABLE(firewire_console firewire_console.cpp)
# edit the following line to add the necessary libraries
TARGET_LINK_LIBRARIES(firewire_console ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire pthread)
TARGET_LINK_LIBRARIES(firewire_console ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire_camera pthread)
# edit the following line to add the source code for the example and the name of the executable
ADD_EXECUTABLE(firewire_oneshot firewire_camera_oneshot.cpp)
# edit the following line to add the necessary libraries
TARGET_LINK_LIBRARIES(firewire_oneshot ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire pthread)
TARGET_LINK_LIBRARIES(firewire_oneshot ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire_camera pthread)
# edit the following line to add the source code for the example and the name of the executable
ADD_EXECUTABLE(firewire_cont firewire_camera_cont.cpp)
# edit the following line to add the necessary libraries
TARGET_LINK_LIBRARIES(firewire_cont ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire pthread)
TARGET_LINK_LIBRARIES(firewire_cont ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire_camera pthread)
# edit the following line to add the source code for the example and the name of the executable
ADD_EXECUTABLE(firewire_2camera firewire_2camera.cpp)
# edit the following line to add the necessary libraries
TARGET_LINK_LIBRARIES(firewire_2camera ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire pthread)
TARGET_LINK_LIBRARIES(firewire_2camera ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire_camera pthread)
# edit the following line to add the source code for the example and the name of the executable
ADD_EXECUTABLE(bumblebee bumblebee.cpp)
# edit the following line to add the necessary libraries
TARGET_LINK_LIBRARIES(bumblebee ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire pthread)
TARGET_LINK_LIBRARIES(bumblebee ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire_camera pthread)
# edit the following line to add the source code for the example and the name of the executable
ADD_EXECUTABLE(ptg_camera ptg_camera.cpp)
# edit the following line to add the necessary libraries
TARGET_LINK_LIBRARIES(ptg_camera ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire pthread)
TARGET_LINK_LIBRARIES(ptg_camera ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire_camera pthread)
# edit the following line to add the source code for the example and the name of the executable
ADD_EXECUTABLE(ladybug ladybug.cpp)
# edit the following line to add the necessary libraries
TARGET_LINK_LIBRARIES(ladybug ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire pthread)
TARGET_LINK_LIBRARIES(ladybug ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire_camera pthread)
if (USE_CV)
# edit the following line to add the source code for the example and the name of the executable
ADD_EXECUTABLE(firewire_cont_CV firewire_camera_cont_CV.cpp)
# edit the following line to add the necessary libraries
TARGET_LINK_LIBRARIES(firewire_cont_CV ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire pthread ${OpenCV_LIBS})
TARGET_LINK_LIBRARIES(firewire_cont_CV ${iriutils_LIBRARY} ${raw1394_LIBRARY} ${dc1394_LIBRARY} firewire_camera pthread ${OpenCV_LIBS})
endif()
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment