Out of source build and KDevelop
Andy Cedilnik
andy.cedilnik at kitware.com
Wed Oct 13 17:00:22 BST 2004
Hi Alex,
On Tue, 2004-10-12 at 19:39, Andy Cedilnik wrote:
> > Ok, and here you can find a patch against current cmake cvs which adds support
> > for the out-of-source filelist files introduced in the kdevelop patch.
I guess this solves the problem where Project.kdevelop.filelist file is:
- QFile f(dirName + "/" + projectName + ".filelist");
+ QString filelistDir=DomUtil::readEntry(dom,
"/kdevcustomproject/filelistdirectory");
+ if (filelistDir.isEmpty())
+ filelistDir=dirName;
+
+ QFile f(filelistDir + "/" + projectName + ".filelist");
That however does not solve the problem of source-files being, well,
anywhere.
For example, let say my source tree is /home/andy/source/, the build
tree is /home/andy/build and the actual sources are in
/home/andy/source, /home/andy/build (generated sources), and
/usr/local/share/doc/mpich/example/ (something vendor provided and I
want to use in my project). I think the solution is that the .filelist
files are written out as absolute path.
Maybe the code that uses files should do something like:
if ( !fileExists(filename) )
{
QString sfilename = sourcedir + "/" + filename;
if (fileExists(sfilename) )
{
filename = sfilename;
}
else
{
sfilename = builddir + "/" + filename;
if ( fileExists(sfilename) )
{
filename = sfilename;
}
else
{
reportError();
}
}
}
Or something like this...
Andy
-
to unsubscribe from this list send an email to kdevelop-request at kdevelop.org with the following body:
unsubscribe »your-email-address«
More information about the KDevelop
mailing list