aboutsummaryrefslogtreecommitdiff
path: root/am2cmake
diff options
context:
space:
mode:
authorAlexander Neundorf <neundorf@kde.org>2006-01-25 20:41:54 +0000
committerAlexander Neundorf <neundorf@kde.org>2006-01-25 20:41:54 +0000
commit1d78fb83f0d0c05d0d0bd8b4bbb53747fc55778d (patch)
tree656ef2601e1adce802373bb79ef185ee768bb638 /am2cmake
parent70e36df077f2685f6feda284cb02c27162d43344 (diff)
downloadextra-cmake-modules-1d78fb83f0d0c05d0d0bd8b4bbb53747fc55778d.tar.gz
extra-cmake-modules-1d78fb83f0d0c05d0d0bd8b4bbb53747fc55778d.tar.bz2
add the stuff moved from kdesdk, maybe...
Alex svn path=/trunk/KDE/kdelibs/; revision=502383
Diffstat (limited to 'am2cmake')
-rwxr-xr-xam2cmake17
1 files changed, 12 insertions, 5 deletions
diff --git a/am2cmake b/am2cmake
index 7eff7bc2..ae21aa3f 100755
--- a/am2cmake
+++ b/am2cmake
@@ -35,7 +35,8 @@ InstallDirsKDE3 = {
"kde_wallpaper"=> "/share/wallpapers",
"xdg_apps" => "/share/applications/kde",
"xdg_directory"=> "/share/desktop-directories",
- "data" => "/share"
+ "data" => "/share",
+ "include" => "/include"
}
InstallDirsKDE4 = {
@@ -55,7 +56,8 @@ InstallDirsKDE4 = {
"kde_wallpaper"=> "${KDE4_WALLPAPER_DIR}",
"xdg_apps" => "${XDG_APPS_DIR}",
"xdg_directory"=> "${XDG_DIRECTORY_DIR}",
- "data" => "/share"
+ "data" => "/share",
+ "include" => "/include"
}
$installDirs=InstallDirsKDE3
@@ -457,6 +459,11 @@ class CMakeFile
return
end
+ if line =~ /^\s*(\w*include)_HEADERS\s*=\s*(\S+.*)$/
+ addInstallFiles($1, $2)
+ return
+ end
+
if line =~ /^\s*SUBDIRS\s*=\s*(\S+.*)$/ || line =~ /^\s*COMPILE_FIRST\s*=\s*(\S+.*)$/
($1).split.each do |dir|
if dir =~ /\$\(.+\)/
@@ -620,7 +627,7 @@ class CMakeFile
else
if buildTarget.test
- file.printf("IF(KDE3_BUILD_TESTS)\n")
+ file.printf("IF(KDE3_BUILD_TESTS)\n\n")
end
file.printf("KDE3_ADD_EXECUTABLE(%s ${%s})\n\n", buildTarget.name, srcsName)
@@ -720,7 +727,7 @@ class CMakeFile
if buildTarget.type==StaticLib && $withConvLibs
#<porting info for libtool convenience libs>
$convFile.printf("# %s: %s\n\n", @amFile, buildTarget.name)
-
+
if buildTarget.sources.empty?
$convFile.printf("set(%s \n", srcsName)
buildTarget.sources.each { |currentFile| $convFile.printf(" ${CMAKE_SOURCE_DIR}/%s%s\n", @path, currentFile) }
@@ -866,7 +873,7 @@ class CMakeFile
else #executable
if buildTarget.test
- file.printf("if(KDE4_BUILD_TESTS)\n")
+ file.printf("if(KDE4_BUILD_TESTS)\n\n")
end
file.printf("kde4_add_executable(%s ${%s})\n\n", buildTarget.name, srcsName)