[PC-BSD Commits] r2154 - pcbsd/trunk/libpcbsd

svn at pcbsd.org svn at pcbsd.org
Mon Jun 23 07:27:28 PDT 2008


Author: kris
Date: 2008-06-23 07:27:27 -0700 (Mon, 23 Jun 2008)
New Revision: 2154

Modified:
   pcbsd/trunk/libpcbsd/CMakeLists.txt
   pcbsd/trunk/libpcbsd/netif.cpp
Log:

Updated libpcbsd to QT4 and fixed CmakeLists to compile it properly



Modified: pcbsd/trunk/libpcbsd/CMakeLists.txt
===================================================================
--- pcbsd/trunk/libpcbsd/CMakeLists.txt	2008-06-22 14:53:11 UTC (rev 2153)
+++ pcbsd/trunk/libpcbsd/CMakeLists.txt	2008-06-23 14:27:27 UTC (rev 2154)
@@ -1,15 +1,20 @@
 PROJECT (PCBSD_LIBS)
-cmake_minimum_required(VERSION 2.4.0)
-set (CMAKE_INSTALL_PREFIX /)
+cmake_minimum_required(VERSION 2.6)
 
-find_package(Qt3 REQUIRED)
-find_package(KDE3 REQUIRED)
 
-add_definitions(${QT_DEFINITIONS} ${KDE3_DEFINITIONS})
+# where to look first for cmake modules, before ${CMAKE_ROOT}/Modules/ is checked
+set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules )
 
-link_directories(${KDE3_LIB_DIR})
-include_directories(${KDE3_INCLUDE_DIR} ${QT_INCLUDE_DIR} ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR})
+find_package(KDE4 REQUIRED)
+include(KDE4Defaults)
 
+find_package(Qt4 REQUIRED)
+
+add_definitions(${QT_DEFINITIONS} ${KDE4_DEFINITIONS})
+
+link_directories(${KDE4_LIB_DIR})
+include_directories(${KDE4_INCLUDE_DIR} ${QT_INCLUDE_DIR} ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR})
+
 set (pcbsd_SRCS
  netif.cpp
  utils.cpp
@@ -17,9 +22,9 @@
 
 add_library(pcbsd SHARED ${pcbsd_SRCS})
 
-target_link_libraries(pcbsd ${QT_AND_KDECORE_LIBRARIES} ${KDE3_KIO_LIBS})
+target_link_libraries(pcbsd ${QT_AND_KDECORE_LIBRARIES} ${KDE4_KIO_LIBS})
 
 ### INSTALL ###
 
-INSTALL_TARGETS(/usr/local/lib pcbsd)
-INSTALL_FILES(/PCBSD/includes "([A-Z]|[a-z]|[0-9])+\\.h$")
\ No newline at end of file
+INSTALL_TARGETS(/../../usr/local/lib pcbsd)
+INSTALL_FILES(/../../PCBSD/includes "([A-Z]|[a-z]|[0-9])+\\.h$")

Modified: pcbsd/trunk/libpcbsd/netif.cpp
===================================================================
--- pcbsd/trunk/libpcbsd/netif.cpp	2008-06-22 14:53:11 UTC (rev 2153)
+++ pcbsd/trunk/libpcbsd/netif.cpp	2008-06-23 14:27:27 UTC (rev 2154)
@@ -34,6 +34,7 @@
 #include <ifaddrs.h>
 #include <netinet/in.h>
 #include <arpa/inet.h>
+#include <stdlib.h>
 
 #include <qregexp.h>
 



More information about the Commits mailing list