Blob Blame History Raw
diff -up kdenetwork-4.10.0/kopete/protocols/jabber/CMakeLists.txt.kopete_system_iris kdenetwork-4.10.0/kopete/protocols/jabber/CMakeLists.txt
--- kdenetwork-4.10.0/kopete/protocols/jabber/CMakeLists.txt.kopete_system_iris	2013-01-23 16:17:12.000000000 -0600
+++ kdenetwork-4.10.0/kopete/protocols/jabber/CMakeLists.txt	2013-02-11 09:14:26.067395997 -0600
@@ -1,19 +1,32 @@
 add_definitions(-DQT3_SUPPORT -DQT3_SUPPORT_WARNINGS -DIRIS_XMPP_JID_DEPRECATED)
 
 add_subdirectory( icons ) 
-add_subdirectory( libiris ) 
 
 #FIXME:glib : necessary ?
 include_directories( 
 ${KOPETE_INCLUDES} 
 ${CMAKE_CURRENT_SOURCE_DIR}/ui/
 ${CMAKE_CURRENT_SOURCE_DIR}/tasks/
+)
+
+if(USE_SYSTEM_IRIS)
+find_package(PkgConfig REQUIRED)
+pkg_check_modules(IRIS REQUIRED iris irisnet)
+include_directories( ${IRIS_INCLUDE_DIRS} )
+link_directories( ${IRIS_LIBRARY_DIRS} )
+else(USE_SYSTEM_IRIS)
+add_subdirectory( libiris )
+
+include_directories(
 ${CMAKE_CURRENT_SOURCE_DIR}/libiris/include/
 ${CMAKE_CURRENT_SOURCE_DIR}/libiris/iris/
 ${CMAKE_CURRENT_SOURCE_DIR}/libiris/iris/xmpp/jingle
 ${QCA2_INCLUDE_DIR}
 )
 
+link_directories( ${CMAKE_CURRENT_BINARY_DIR}/libiris/ )
+endif(USE_SYSTEM_IRIS)
+
 if(BUILD_GOOGLETALK)
   # We dont need other programs
   set ( BUILD_libjingle_natserver false )
@@ -43,9 +56,6 @@ IF(BUILD_JINGLE)
   include_directories(${CMAKE_CURRENT_SOURCE_DIR}/jingle)
 ENDIF(BUILD_JINGLE)
 
-#link_directories( ${CMAKE_CURRENT_BINARY_DIR}/libiris/ ${CMAKE_CURRENT_BINARY_DIR}/jingle/ )
-link_directories( ${CMAKE_CURRENT_BINARY_DIR}/libiris/ )
-
 ########### next target ###############
 
 set(kopete_jabber_ui_SRCS 
@@ -178,7 +188,12 @@ endif(BUILD_JINGLE)
 kde4_add_plugin(kopete_jabber ${kopete_jabber_PART_SRCS})
 
 
-target_link_libraries(kopete_jabber ${KDE4_KDE3SUPPORT_LIBS} ${QCA2_LIBRARIES} ${KDE4_SOLID_LIBS} kopete iris_kopete)
+target_link_libraries(kopete_jabber ${KDE4_KDE3SUPPORT_LIBS} ${QCA2_LIBRARIES} ${KDE4_SOLID_LIBS} kopete)
+if(USE_SYSTEM_IRIS)
+target_link_libraries(kopete_jabber ${IRIS_LIBRARIES})
+else(USE_SYSETM_IRIS)
+target_link_libraries(kopete_jabber iris_kopete)
+endif(USE_SYSTEM_IRIS)
 if(BUILD_JINGLE)	
   target_link_libraries(kopete_jabber ortp asound speex)
 endif(BUILD_JINGLE)