project(qtproject) # the name of your project

cmake_minimum_required(VERSION 2.4.0)

find_package(Qt3 REQUIRED) # find and setup Qt3 for this project
find_package(KDE3 REQUIRED) # find and setup KDE3 for this project

add_definitions(${QT_DEFINITIONS} ${KDE3_DEFINITIONS})

# tell cmake where to search for libraries:
link_directories(${KDE3_LIB_DIR})

# tell cmake where to search for Qt/KDE headers:
include_directories(${KDE3_INCLUDE_DIR} ${QT_INCLUDE_DIR})

# the variable "qtproject_SRCS" contains all .cpp files of this project
set(qtproject_SRCS
    main.cpp
	)

# create an executable file named "qtproject" from the source files in the variable "qtproject_SRCS".
add_executable(qtproject ${qtproject_SRCS})

# link the "qtproject" target (i.e. the executable file added above) agains the Qt and the kdecore libraries.
target_link_libraries(qtproject ${QT_AND_KDECORE_LIBRARIES})
		