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.

Bug 151978 - Can't debug sample on remote host
Summary: Can't debug sample on remote host
Status: VERIFIED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Remote (show other bugs)
Version: 6.x
Hardware: All Windows XP
: P1 blocker (vote)
Assignee: Sergey Grinev
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-31 14:11 UTC by soldatov
Modified: 2008-11-01 09:49 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description soldatov 2008-10-31 14:11:32 UTC
Host: Solaris
Client: Windows XP
P:\ is mounted directory from Solaris machine

Scenario:
- Add 'tester@eaglet-sr' host
- Create Welcome project in P:/sv directory
- Select 'tester@eaglet-sr' and 'GCC' in project properties window
- Run project
==> ok
- Load projects into debugger
==> 'P:\home\sv\Welcome_3\dist\Debug\GNU-Solaris-x86\welcome_3 doesn't exist or is not an executable' message appeared.
Comment 1 soldatov 2008-10-31 14:41:43 UTC
build 200809240201 works correctly
Comment 2 Sergey Grinev 2008-10-31 15:25:54 UTC
Validation introduced by fix for 148841 doesn't missed path mapping.
I believe this is a showstopper. 

Proposed fix:

+++ b/cnd.makeproject/src/org/netbeans/modules/cnd/makeproject/api/DefaultProjectActionHandler.java     Fri Oct 31
17:23:55 2008 +0300
@@ -621,9 +621,11 @@
      * @return true if executable exists and is an executable, otherwise false
      */
     private boolean verifyRemoteExecutable(String hkey, String executable) {
+        PathMap mapper = HostInfoProvider.getDefault().getMapper(hkey);
+        String remoteExecutable = mapper.getRemotePath(executable);
         CommandProvider cmd = Lookup.getDefault().lookup(CommandProvider.class);
         if (cmd != null) {
-            return cmd.run(hkey, "test -x " + executable + " -a -f " + executable, null) == 0; // NOI18N
+            return cmd.run(hkey, "test -x " + remoteExecutable + " -a -f " + remoteExecutable, null) == 0; // NOI18N
         }
         return false;
     }


Please, review.
Comment 3 Sergey Grinev 2008-10-31 15:28:40 UTC
typo:  doesn't honor path mapping.

Justification for showstopper: user is unable to debug remote projects from Windows at all
Comment 4 Alexander Pepin 2008-10-31 16:23:20 UTC
This is a showstopper for NB6.5 FCS
Comment 5 Sergey Grinev 2008-10-31 16:35:20 UTC
fixed in trunk: http://hg.netbeans.org/main?cmd=changeset;node=0888a9d15ced
Comment 6 Alexander Pepin 2008-10-31 16:51:51 UTC
Proposed fix verified in RC2 with provided org-netbeans-modules-cnd-makeproject.jar
The fix works on all platforms. Please review the fix and put it into release65 branch.
Comment 7 Egor Ushakov 2008-10-31 17:13:27 UTC
fix reviewed and integrated into release65 with:
http://hg.netbeans.org/release65/rev/d8699fb7bdc5
Comment 8 Quality Engineering 2008-11-01 05:12:11 UTC
Integrated into 'main-golden', will be available in build *200811010201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/0888a9d15ced
User: Sergey Grinev <sergius@netbeans.org>
Log: fixed #151978 Can't debug sample on remote host
Comment 9 soldatov 2008-11-01 09:49:46 UTC
verified in a preliminary FCS build