[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-windows
Subject: Re: Using msvc solution files
From: Peter_Kümmel <syntheticpp () gmx ! net>
Date: 2009-11-11 15:53:30
Message-ID: 4AFADDFA.6080006 () gmx ! net
[Download RAW message or body]
Ralf Habacker wrote:
> emerge --fetch emerge (or in emerge root "svn update emerge\bin" )
>
> then run
>
> set EMERGE_OPTION=cmake.useIDE=1
A candidate for kdesettings-example.bat?
> normaly self.package (generated from the emerge script file name)
> matches the project name in the CMakeLists.txt. If not
> self.subinfo.options.make.slnBaseName could be used in the package
> emerge script.
attachd a patch which reads the project filename from CMakeLists.txt
>>
> Thanks for this contribution - we only have to find a way to merge the
> recent feature (openening the ide in make action) and your approach.
We could introduce cmake.openIDE.
Also cmake.numberIDEThreads=<number of parallel builds> or is there already a
option for "make -j" which we could use?
And we must somehow generate the project configuration "Debug:Win32", ...
Peter
["useIDE.patch" (text/plain)]
Index: kdesettings-example.bat
===================================================================
--- kdesettings-example.bat (revision 1047621)
+++ kdesettings-example.bat (working copy)
@@ -144,6 +144,12 @@
rem for all other packages this option doesn't have any effect
rem set EMERGE_DEFAULTCATEGORY=kde-4.3
+
+rem This option configures CMake to generate Visual Studio solution files \
instead of nmake files. +rem set EMERGE_OPTION=cmake.useIDE=1
+
+
+
rem No editing should be necessary below this line (in an ideal world)
rem ##################################################################
Index: bin/BuildSystem/CMakeBuildSystem.py
===================================================================
--- bin/BuildSystem/CMakeBuildSystem.py (revision 1047621)
+++ bin/BuildSystem/CMakeBuildSystem.py (working copy)
@@ -96,10 +96,24 @@
os.putenv( "PATH", os.path.join( self.rootdir, self.envPath ) \
+ ";" + os.getenv("PATH") )
if self.compiler() == "msvc2008" and \
self.subinfo.options.cmake.useIDE:
- if self.subinfo.options.make.slnBaseName:
- command = "start %s.sln" % \
self.subinfo.options.make.slnBaseName + sourceDir = \
self.sourceDir() + topLevelCMakeList = \
os.path.join(self.sourceDir(),"CMakeLists.txt") + if \
os.path.exists(topLevelCMakeList): + f = \
open(topLevelCMakeList,'r') + lines = f.read().splitlines()
+ f.close()
+ for line in lines:
+ if line.find("project") > -1:
+ a = line.split("(")
+ a = a[1].split(")")
+ slnname = a[0].strip()
+ if slnname:
+ command = "vcbuild /M2 %s.sln \"Debug|Win32\"" % slnname
else:
- command = "start %s.sln" % self.package
+ if self.subinfo.options.make.slnBaseName:
+ command = "vcbuild /M2 %s.sln \"Debug|Win32\"" % \
self.subinfo.options.make.slnBaseName + else:
+ command = "vcbuild /M2 %s.sln \"Debug|Win32\"" % \
self.package else:
command = self.makeProgramm
@@ -122,14 +136,17 @@
if not self.noFast:
fastString = "/fast"
- if self.subinfo.options.install.useMakeToolForInstall == True: \
- command = "%s DESTDIR=%s install%s" % ( self.makeProgramm, \
self.installDir(), fastString ) + if \
self.subinfo.options.install.useMakeToolForInstall == True: + if \
self.compiler() == "msvc2008" and self.subinfo.options.cmake.useIDE: + \
command = "vcbuild INSTALL.vcproj \"Debug|Win32\"" + else:
+ command = "%s DESTDIR=%s install%s" % ( self.makeProgramm, \
self.installDir(), fastString ) else:
command = "cmake -DCMAKE_INSTALL_PREFIX=%s -P \
cmake_install.cmake" % self.installDir()
self.system( command, "install" )
- if self.subinfo.options.install.useMakeToolForInstall == True:
+ if self.subinfo.options.install.useMakeToolForInstall == True and \
not self.subinfo.options.cmake.useIDE:
utils.fixCmakeImageDir( self.installDir(), \
self.mergeDestinationDir() ) return True
_______________________________________________
Kde-windows mailing list
Kde-windows@kde.org
https://mail.kde.org/mailman/listinfo/kde-windows
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic