mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-15 04:05:38 +02:00
Fix for bugzilla 45311: "CVS tries to check in contents of build output"
The managed make builder generates the output directories, and the makefiles for those directories. Those files should be tagged as "derived" so that the CM system will ignore the files on check-in. Now, that is done when a new build directory or file is added to the project. The workspace will take care of files created by the build process through the Ignored Resources extension point.
This commit is contained in:
parent
cbd2bd573f
commit
e4bbb5dc9e
2 changed files with 34 additions and 4 deletions
|
@ -1,3 +1,13 @@
|
|||
2004-03-09 Sean Evoy
|
||||
Fix for bugzilla 45311: "CVS tries to check in contents of build output"
|
||||
|
||||
The managed make builder generates the output directories, and the makefiles
|
||||
for those directories. Those files should be tagged as "derived" so that the
|
||||
CM system will ignore the files on check-in. Now, that is done when a new
|
||||
build directory or file is added to the project. The workspace will take care
|
||||
of files created by the build process through the Ignored Resources
|
||||
extension point.
|
||||
|
||||
2004-03-08 Sean Evoy
|
||||
Committing the changes needed by our partners to better support a variety
|
||||
of tool references. A class hierarchy of tool references has been introduced.
|
||||
|
|
|
@ -877,7 +877,12 @@ public class MakefileGenerator {
|
|||
return subdirList;
|
||||
}
|
||||
|
||||
/* (non-javadoc)
|
||||
/* (non-Javadoc)
|
||||
* Return or create the folder needed for the build output. If we are
|
||||
* creating the folder, set the derived bit to true so the CM system
|
||||
* ignores the contents. If the resource exists, respect the existing
|
||||
* derived setting.
|
||||
*
|
||||
* @param string
|
||||
* @return IPath
|
||||
*/
|
||||
|
@ -885,7 +890,6 @@ public class MakefileGenerator {
|
|||
// Create or get the handle for the build directory
|
||||
IFolder folder = project.getFolder(dirName);
|
||||
if (!folder.exists()) {
|
||||
|
||||
// Make sure that parent folders exist
|
||||
IPath parentPath = (new Path(dirName)).removeLastSegments(1);
|
||||
// Assume that the parent exists if the path is empty
|
||||
|
@ -906,11 +910,22 @@ public class MakefileGenerator {
|
|||
else
|
||||
throw e;
|
||||
}
|
||||
|
||||
// Make sure the folder is marked as derived so it is not added to CM
|
||||
if (!folder.isDerived()) {
|
||||
folder.setDerived(true);
|
||||
}
|
||||
}
|
||||
|
||||
return folder.getFullPath();
|
||||
}
|
||||
|
||||
/* (non-javadoc)
|
||||
/* (non-Javadoc)
|
||||
* Return or create the makefile needed for the build. If we are creating
|
||||
* the resource, set the derived bit to true so the CM system ignores
|
||||
* the contents. If the resource exists, respect the existing derived
|
||||
* setting.
|
||||
*
|
||||
* @param makefilePath
|
||||
* @param monitor
|
||||
* @return IFile
|
||||
|
@ -926,6 +941,11 @@ public class MakefileGenerator {
|
|||
ByteArrayInputStream contents = new ByteArrayInputStream(new byte[0]);
|
||||
try {
|
||||
newFile.create(contents, false, monitor);
|
||||
// Make sure the new file is marked as derived
|
||||
if (!newFile.isDerived()) {
|
||||
newFile.setDerived(true);
|
||||
}
|
||||
|
||||
}
|
||||
catch (CoreException e) {
|
||||
// If the file already existed locally, just refresh to get contents
|
||||
|
@ -934,7 +954,7 @@ public class MakefileGenerator {
|
|||
else
|
||||
throw e;
|
||||
}
|
||||
|
||||
|
||||
return newFile;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue