Version: 3.1.91 (CVS) (using KDE Devel) Installed from: Compiled sources Compiler: gcc 3.3 OS: Linux (kdevelop CVS-050202) * Import Existing Project -> Generic C++ Application (Custom Makefiles) * the project is populated with any (*.cpp|*.h) files found * copy a file from somewhere * File Tree -> RMB to copied file -> Add to Project -> nothing seems to happen I found that an empty line is appended to $PROJECT.kdevelop.filelist any time I add a file to the project. Files already in the project can't be removed - the context menu just offers to add them again ...
*** This bug has been confirmed by popular vote. ***
The following simple patch to ./buildtools/custommakefiles/customprojectpart.cpp fixes the bug 191,192c191,193 < QString contextFileName = URLUtil::canonicalPath(fcontext->urls().first().fileName()); < bool inProject = project()->isProjectFile(contextFileName); --- > QString contextFileName = URLUtil::canonicalPath(fcontext->urls().first().path()); > > bool inProject = project()->isProjectFile(contextFileName);
if you could redo the diff with "diff -u" and attach it the bugreport, that would be great. Thanks. :)
Created attachment 10323 [details] A patch to fix the bug by using the file path rather than the name. Uses the path to the file rather than the file name, so that files not in the root of the project can be added or removed
I resubmitted the patch some time ago. Has anyone attempted to test this? I downloaded 3.2.1 and had to apply my own patch because it didn't make it into the release.
I have tried the patch against 3.2.0. It works perfectly
Thanks David Guthrie, Your patch works for me also against 3.2.0 release.
Fixed in svn, relative and absolute paths were not handled correctly. The patch was slightly more complicated than the one suggested here. http://lists.kde.org/?l=kde-commits&m=113285732705490&w=2 Alex