conversion to the cmake building system

Signed-off-by: gregory guy <g-gregory@gmx.fr>
pull/4/head
gregory guy 5 years ago committed by Slávek Banko
parent 3994ab2ba9
commit f9440f0f50
No known key found for this signature in database
GPG Key ID: 608F5293A04BE668

@ -0,0 +1,79 @@
############################################
# #
# Improvements and feedbacks are welcome #
# #
# This file is released under GPL >= 3 #
# #
############################################
cmake_minimum_required( VERSION 2.8 )
#### general package setup
project( kooldock )
set( VERSION R14.1.0 )
#### include essential cmake modules
include( FindPkgConfig )
include( CheckFunctionExists )
include( CheckSymbolExists )
include( CheckIncludeFile )
include( CheckLibraryExists )
include( CheckCSourceCompiles )
include( CheckCXXSourceCompiles )
#### include our cmake modules
set( CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/modules" )
include( TDEMacros )
##### setup install paths
include( TDESetupPaths )
tde_setup_paths( )
##### optional stuff
option( WITH_ALL_OPTIONS "Enable all optional support" OFF )
option( WITH_GCC_VISIBILITY "Enable fvisibility and fvisibility-inlines-hidden" ${WITH_ALL_OPTIONS} )
##### user requested modules
option( BUILD_ALL "Build all" ON )
option( BUILD_TRANSLATIONS "Build translations" ${BUILD_ALL} )
##### configure checks
include( ConfigureChecks.cmake )
###### global compiler settings
add_definitions( -DHAVE_CONFIG_H -UTQT_NO_ASCII_CAST )
set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${TQT_CXX_FLAGS}" )
set( CMAKE_SHARED_LINKER_FLAGS "-Wl,--no-undefined" )
set( CMAKE_MODULE_LINKER_FLAGS "-Wl,--no-undefined" )
##### directories
add_subdirectory( src )
add_subdirectory( backgrounds )
add_subdirectory( icons )
tde_conditional_add_subdirectory( BUILD_TRANSLATIONS po )
##### write configure files
configure_file( config.h.cmake config.h @ONLY )

@ -0,0 +1,26 @@
###########################################
# #
# Improvements and feedback are welcome #
# #
# This file is released under GPL >= 3 #
# #
###########################################
# required stuff
find_package( TQt )
find_package( TDE )
tde_setup_architecture_flags( )
include(TestBigEndian)
test_big_endian(WORDS_BIGENDIAN)
tde_setup_largefiles( )
##### check for gcc visibility support
if( WITH_GCC_VISIBILITY )
tde_setup_gcc_visibility( )
endif( WITH_GCC_VISIBILITY )

@ -0,0 +1 @@
tde_auto_add_subdirectories( )

@ -0,0 +1,6 @@
file( GLOB _pics RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.png )
install(
FILES ${_pics}
DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/backgrounds/border-black
)

@ -0,0 +1,6 @@
file( GLOB _pics RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.png )
install(
FILES ${_pics}
DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/backgrounds/border-white
)

@ -0,0 +1,6 @@
file( GLOB _pics RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.png )
install(
FILES ${_pics}
DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/backgrounds/crystal
)

@ -0,0 +1,6 @@
file( GLOB _pics RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.png )
install(
FILES ${_pics}
DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/backgrounds/default
)

@ -0,0 +1,6 @@
file( GLOB _pics RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.png )
install(
FILES ${_pics}
DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/backgrounds/fadeout
)

@ -0,0 +1,6 @@
file( GLOB _pics RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.png )
install(
FILES ${_pics}
DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/backgrounds/fadeout2
)

@ -0,0 +1,6 @@
file( GLOB _pics RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.png )
install(
FILES ${_pics}
DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/backgrounds/fadeout3
)

@ -0,0 +1,6 @@
file( GLOB _pics RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.png )
install(
FILES ${_pics}
DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/backgrounds/osx
)

@ -0,0 +1,8 @@
#define VERSION "@VERSION@"
// Defined if you have fvisibility and fvisibility-inlines-hidden support.
#cmakedefine __KDE_HAVE_GCC_VISIBILITY 1
/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
significant byte first (like Motorola and SPARC, unlike Intel). */
#cmakedefine WORDS_BIGENDIAN @WORDS_BIGENDIAN@

@ -0,0 +1,3 @@
tde_install_icons( )
tde_install_icons( DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/icons )

@ -0,0 +1,5 @@
file( GLOB _srcs RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.po )
if( _srcs )
tde_create_translation( LANG auto OUTPUT_NAME ${PROJECT_NAME} )
endif( )

@ -0,0 +1,34 @@
include_directories(
${CMAKE_BINARY_DIR}
${CMAKE_CURRENT_BINARY_DIR}
${CMAKE_CURRENT_SOURCE_DIR}
${TDE_INCLUDE_DIR}
${TQT_INCLUDE_DIRS}
)
link_directories(
${TQT_LIBRARY_DIRS}
${TDE_LIB_DIR}
)
##### kooldock (executable)
tde_add_executable( ${PROJECT_NAME} AUTOMOC
SOURCES
appProp.ui
setupdialog.ui
apppropprg.cpp
clip.cpp dinfo.cpp
item.cpp kooldock.cpp
main.cpp
setupdialogprg.cpp
xosd.cpp
LINK
tdecore-shared
tdeio-shared
tdeui-shared
DESTINATION ${BIN_INSTALL_DIR}
)

@ -12,7 +12,7 @@
#ifndef APPPROPPRG_H #ifndef APPPROPPRG_H
#define APPPROPPRG_H #define APPPROPPRG_H
#include <ntqwidget.h> #include <tqwidget.h>
#include "appProp.h" #include "appProp.h"
/** /**

@ -1,8 +1,8 @@
#include "clip.h" #include "clip.h"
#include <ntqwidget.h> #include <tqwidget.h>
#include <ntqbitmap.h> #include <tqbitmap.h>
#include <ntqpainter.h> #include <tqpainter.h>
#include <netwm.h> #include <netwm.h>
#include <netwm_def.h> #include <netwm_def.h>
#include <twin.h> #include <twin.h>
@ -47,3 +47,4 @@ void clip::paintEvent(TQPaintEvent*)
mp.end(); mp.end();
setMask(bm); setMask(bm);
} }
#include "clip.moc"

@ -5,7 +5,7 @@
#include <config.h> #include <config.h>
#endif #endif
#include <ntqwidget.h> #include <tqwidget.h>
#include <netwm.h> #include <netwm.h>
#include <twin.h> #include <twin.h>

@ -18,9 +18,9 @@
#include <tdeglobal.h> #include <tdeglobal.h>
#include <kicontheme.h> #include <kicontheme.h>
#include <ntqfile.h> #include <tqfile.h>
#include <ntqimage.h> #include <tqimage.h>
#include <ntqtextstream.h> #include <tqtextstream.h>
#include "item.h" #include "item.h"

@ -21,13 +21,13 @@
#include <kiconloader.h> #include <kiconloader.h>
#include <twin.h> #include <twin.h>
#include <ntqstring.h> #include <tqstring.h>
#include <ntqpixmap.h> #include <tqpixmap.h>
#include <ntqptrlist.h> #include <tqptrlist.h>
#include <vector> #include <vector>
#include <ntqevent.h> #include <tqevent.h>
#include <ntqnamespace.h> #include <tqnamespace.h>
const int MAX_LEN = 256; const int MAX_LEN = 256;
const int SIZE_INC = 1; const int SIZE_INC = 1;

@ -19,21 +19,21 @@
#include <math.h> #include <math.h>
#include <algorithm> #include <algorithm>
#include <ntqpixmap.h> #include <tqpixmap.h>
#include <ntqimage.h> #include <tqimage.h>
#include <ntqpainter.h> #include <tqpainter.h>
#include <ntqcursor.h> #include <tqcursor.h>
#include <ntqdir.h> #include <tqdir.h>
#include <ntqstringlist.h> #include <tqstringlist.h>
#include <ntqvaluelist.h> #include <tqvaluelist.h>
#include <ntqtooltip.h> #include <tqtooltip.h>
#include <ntqrect.h> #include <tqrect.h>
#include <ntqfile.h> #include <tqfile.h>
#include <ntqtextstream.h> #include <tqtextstream.h>
#include <ntqbrush.h> #include <tqbrush.h>
#include <ntqpoint.h> #include <tqpoint.h>
#include <ntqfont.h> #include <tqfont.h>
#include <ntqdatetime.h> #include <tqdatetime.h>
#include <twin.h> #include <twin.h>
#include <kprocess.h> #include <kprocess.h>
@ -46,7 +46,7 @@
#include <kpixmapio.h> #include <kpixmapio.h>
#include <kstandarddirs.h> #include <kstandarddirs.h>
#include <tdeaboutapplication.h> #include <tdeaboutapplication.h>
#include <ntqlistbox.h> #include <tqlistbox.h>
#include <keditlistbox.h> #include <keditlistbox.h>
// for "renicing" the bar // for "renicing" the bar
@ -61,13 +61,12 @@
#include "setupdialogprg.h" #include "setupdialogprg.h"
// macros // macros
#define min(a, b) (a < b) ? (a) : (b) #define min(a, b) (a < b) ? (a) : (b)
#define max(a, b) (a > b) ? (a) : (b) #define max(a, b) (a > b) ? (a) : (b)
#include <dcopclient.h> #include <dcopclient.h>
#include <iostream> //#include <iostream>
#include <ntqdatastream.h> #include <tqdatastream.h>
KoolDock::KoolDock(TQWidget* parent, const char* name) : KoolDock::KoolDock(TQWidget* parent, const char* name) :
TQWidget(parent, name, WStyle_Customize | WStyle_NoBorder | WNoAutoErase | WDestructiveClose | WStyle_StaysOnTop) TQWidget(parent, name, WStyle_Customize | WStyle_NoBorder | WNoAutoErase | WDestructiveClose | WStyle_StaysOnTop)
@ -3959,3 +3958,4 @@ void KoolDock::rmFromTaskList(WId id)
} }
} }
} }
#include "kooldock.moc"

@ -28,14 +28,14 @@
#include <kpixmap.h> #include <kpixmap.h>
#include <kurifilter.h> #include <kurifilter.h>
#include <ntqwidget.h> #include <tqwidget.h>
#include <ntqptrlist.h> #include <tqptrlist.h>
#include <ntqtimer.h> #include <tqtimer.h>
#include <ntqcolor.h> #include <tqcolor.h>
#include <netwm.h> #include <netwm.h>
#include <ntqdatetime.h> #include <tqdatetime.h>
#include "item.h" #include "item.h"
#include "xosd.h" #include "xosd.h"

@ -19,13 +19,13 @@
#include <kpushbutton.h> #include <kpushbutton.h>
#include <keditlistbox.h> #include <keditlistbox.h>
#include <klineedit.h> #include <klineedit.h>
#include <ntqlistbox.h> #include <tqlistbox.h>
#include <krun.h> #include <krun.h>
#include <ntqiconview.h> #include <tqiconview.h>
#include <ntqdir.h> #include <tqdir.h>
#include <ntqstringlist.h> #include <tqstringlist.h>
#include <ntqtabwidget.h> #include <tqtabwidget.h>
#include "setupdialog.h" #include "setupdialog.h"
#include "setupdialogprg.h" #include "setupdialogprg.h"

@ -16,16 +16,16 @@
#include "apppropprg.h" #include "apppropprg.h"
// QT includes // QT includes
#include <ntqcolor.h> #include <tqcolor.h>
#include <ntqstring.h> #include <tqstring.h>
#include <ntqcheckbox.h> #include <tqcheckbox.h>
#include <ntqlineedit.h> #include <tqlineedit.h>
#include <ntqspinbox.h> #include <tqspinbox.h>
#include <ntqfont.h> #include <tqfont.h>
#include <ntqptrlist.h> #include <tqptrlist.h>
#include <ntqtabwidget.h> #include <tqtabwidget.h>
#include <ntqpushbutton.h> #include <tqpushbutton.h>
#include <ntqradiobutton.h> #include <tqradiobutton.h>
// KDE includes // KDE includes
#include <tdefontcombo.h> #include <tdefontcombo.h>

@ -1,12 +1,12 @@
#include "xosd.h" #include "xosd.h"
#include <ntqpainter.h> #include <tqpainter.h>
#include <ntqbitmap.h> #include <tqbitmap.h>
#include <ntqstring.h> #include <tqstring.h>
#include <ntqfont.h> #include <tqfont.h>
#include <ntqfontmetrics.h> #include <tqfontmetrics.h>
#include <ntqwidget.h> #include <tqwidget.h>
#include <tdelocale.h> #include <tdelocale.h>
#include <netwm.h> #include <netwm.h>
#include <netwm_def.h> #include <netwm_def.h>
@ -193,3 +193,4 @@ void xosd::move2(int x, int y)
lastY = y; lastY = y;
} }
} }
#include "xosd.moc"

@ -5,11 +5,11 @@
#include <config.h> #include <config.h>
#endif #endif
#include <ntqstring.h> #include <tqstring.h>
#include <ntqwidget.h> #include <tqwidget.h>
#include <ntqfont.h> #include <tqfont.h>
#include <ntqpixmap.h> #include <tqpixmap.h>
#include <ntqbitmap.h> #include <tqbitmap.h>
#include <netwm.h> #include <netwm.h>
#include <twin.h> #include <twin.h>

Loading…
Cancel
Save