This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | ClearCase plugin does not work when build directory is separate from source directory which is accessed through a symlink. | ||
---|---|---|---|
Product: | versioncontrol | Reporter: | paul_floyd <paul_floyd> |
Component: | ClearCase | Assignee: | issues@versioncontrol <issues> |
Status: | REOPENED --- | ||
Severity: | blocker | CC: | thp |
Priority: | P2 | ||
Version: | 7.1.2 | ||
Hardware: | PC | ||
OS: | Linux | ||
Issue Type: | DEFECT | Exception Reporter: | |
Attachments: |
Script to setup testcase in ClearCase
try again (forgot to save file before uploading it) |
Description
paul_floyd
2009-06-15 13:16:01 UTC
I just checked the version control support in C/C++ projects and everything seems to works OK. C/C++ projects supports generic version control and it is up the version control plugin to provide the implementation. C/C++ projects are not really aware of which VS system the project is under. The problems you are seeing could be because of the soft links but not sure I fully understand your project structure. Can you be a bit more specific? Perhaps create a test case that demonstrates the issue? Here's a transcript manually setting up a testcase that has the same layout as our existing directories (which works with NB 6.5) pfloyd> cd /vobs/adms/src cairngorm:/vobs/adms/src pfloyd> ct co -nc . Checked out "." from version "/main/pfbranch/2". cairngorm:/vobs/adms/src pfloyd> ct mkdir -c test test Changed protection on "/vobs/adms/src/test". Created directory element "test". Created branch "pfbranch" from "test" version "/main/0". Checked out "test" from version "/main/pfbranch/0". cairngorm:/vobs/adms/src pfloyd> cd test cairngorm:/vobs/adms/src/test pfloyd> xemacs test.c Makefile& cairngorm:/vobs/adms/src/test pfloyd> ct mkelem -c test Makefile Changed protection on "/vobs/adms/src/test/Makefile". Created element "Makefile" (type "text_file"). Created branch "pfbranch" from "Makefile" version "/main/0". Checked out "Makefile" from version "/main/pfbranch/0". cairngorm:/vobs/adms/src/test pfloyd> ct mkelem -c test test.c Changed protection on "/vobs/adms/src/test/test.c". Created element "test.c" (type "text_file"). Created branch "pfbranch" from "test.c" version "/main/0". Checked out "test.c" from version "/main/pfbranch/0". cairngorm:/vobs/adms/src/test [note ss5-dbg is my build area, a "view private directory" pfloyd> cd ../../ss5-dbg cairngorm:/vobs/adms/ss5-dbg [now make "shadows" of source and Makefile pfloyd> mkdir test cairngorm:/vobs/adms/ss5-dbg pfloyd> cd test cairngorm:/vobs/adms/ss5-dbg/test pfloyd> ln -s Isrc/Makefile Makefile cairngorm:/vobs/adms/ss5-dbg/test pfloyd> Next, in NB 6.7rc2 Add new project Existing Makefile /vobs/adms/ss5-dbg/test/Isrc Then, if I right click on test.c, then click on the clearcase menu entry, it doesn't open. Add new project in NB 6.5 works OK. A couple more observations. In NB65, if I open a file by double clicking on a compiler error/warning or from the Tasks list, then the file opens without clearcase functionality in the editor. If I open it from the Projects pane, clearcase functionality works. If I have a file already open from the Projects panel, and I double click the file in a compiler error, then the already opened file is not used, rather a new editor window is opened without clearcase functionality. In NB67rc3, I have one project for which I added the source from the source directory rather than from the object directory through its symbolic link. In this case, if I open a file from the Project panel, then the editor has clearcase functionality (as above). But if I open a file from the Tasks list, then the editor does not have clearcase functionality (also as above). It would help enourmosly if you create the test case, tar it up, and attach it to this IZ. Can you do that? Created attachment 83777 [details]
Script to setup testcase in ClearCase
I've just attached a script that should do the job (I'm at home at the moment, so I don't have access to ClearCase to test it). Running the script in a directory under clearcase control should give ls -R [these bits "view private"] .: WA/ test/ ./WA: test/ ./WA/test: Isrc@ Makefile@ [these bits under clearcase control, checked out] ./test: Makefile test.c In NB67, add a new project as [basedir]/WA/test/Makefile build dir [basedir]/WA/test/ source path [basedir]/WA/test/Isrc Created attachment 83778 [details]
try again (forgot to save file before uploading it)
is this still an problem? nobody else seems to be impacted, we can't reproduce as well. will close for now, but feel free to reopen in case this still is an issue ... thanks I do not at all consider this to be fixed. I's still a very annoying problem. Has anyone really tried to reproduce the problem? If you have done _exactly_ as I said, then I'm really interested in knowing how you can get Netbeans to handle this sort of configuration and have the editor open files with ClearCase features active. I'll repeat the steps to produce it again. Elements in angle brackets <> are general representations. Create a build directory outside of the source directory. It can be view private, or it can be entirely outside of clearcase. The build directory contains an "Isrc" symlink to the ClearCase source directory. The build directory also contains a "Makefile" symlink to "Isrc/Makefile" The Makefile, as well as the usual build rules, also contains "VPATH = Isrc" so that make can find the source files from the build directory. [We have a script that builds an entire shadow build directory tree that mirrors our source directory structure]. Ensure that gnu make works correctly. Create a new project. Choose "<build dir>/Isrc" for the source. I select custom, as we have a wrapper script for gnumake and we use fairly nonstandard options. Choose "<build dir>/Makefile". The rest of the options I leave as the default, except the project name (which defaults to "Isrc") and location (which I put in ~/SunStudioProjects for historical reasons). NB then automatically cleans and builds the project. In the 'Projects' pane, a new icon is added to the tree with 3 sub-elements. "Isrc - <source dir>", plain blue folder with all files in it. If I open files from this, then ClearCase is activated. Then there is just "Isrc", looks like a source icon, just .h and .c files in it. If I open files from here, clearCase is _not_ activated. If I open a file from "Isrc - <source dir>", edit it (and deliberaely introduce an error), then I get an error message Isrc/<source>.c:11:31: error: expected ')' before 'size' gnumake[1]: *** [<source>.o] Error 1 gnumake[1]: Leaving directory `<build dir>' The first line is a link. If I click on it, a new editor window opens (whereas I would expect the focus to simply just jump to the window that I just opened to deliberately introduce the fault). This window does not have ClearCase activated. When I choose the source directory in the 1st step of the new project dialog, it would be possible to choose <source dir> directly at this point, but it doesn't seem to work much better. I only get one "<source dir> - <source dir fullpath>" entry in the Projects tree (which is active in ClearCase), but following compiler errors still opens a window that is not active in ClearCase. My impression is that with a configuration like this, NetBeans does not know whether it is coming or going with respect to the build directory and the source directory. Changed the summary to be (a bit long and) more accurate. Due to a change in job, I no longer use ClearCase, so this can probably be closed. |