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 268070 - "Always relative" is not working for remote project
Summary: "Always relative" is not working for remote project
Status: VERIFIED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Project (show other bugs)
Version: 8.1
Hardware: PC Windows 10 x64
: P2 normal with 1 vote (vote)
Assignee: Vladimir Voskresensky
URL:
Keywords: 82_HR_FIX
Depends on:
Blocks:
 
Reported: 2016-09-16 17:53 UTC by comaniac0422
Modified: 2016-09-20 12:14 UTC (History)
0 users

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 comaniac0422 2016-09-16 17:53:21 UTC
This problem has been reported several years ago but it still hasn't been resolved in version 8.1. When I create a new project located in a remote directory (e.g. \\server.us\myHome\myProject), all source files will be created with absolute paths. Here is an example of file properties:

Item
Name: main.cpp
File Path: //server.us/myHome/myProject/main.cpp
Full Path: \\server.us\myHome\myProject\main.cpp
Last Modified: 

As can be seen, "File path" is an absolute path even I have set "Always relative" in Tools -> Options -> C/C++. It causes at least two serious problems for me:

1. You cannot use generated Makefile to build the project remotely since paths in Makefile are absolute paths and don't match the path on the server.

2. The header file cannot be found by code assistance because the statement #include "header.h" indicates a relative path, but we only have a header file with "//server.us/myHome/myProject/header.h".

The correct one should be:

Item
Name: main.cpp
File Path: main.cpp
Full Path: \\server.us\myHome\myProject\main.cpp
Last Modified: 

Please solve this problem ASAP, or provide an alternative solution.
Thanks.
Comment 1 soldatov 2016-09-16 19:17:42 UTC
Do you speak about old Java problem? Java breaks paths if path is a Windows UNC paths. Some cases has been fixed. For example: http://wiki.netbeans.org/FaqUNCPaths
Comment 2 comaniac0422 2016-09-16 19:25:58 UTC
Sorry I'm saying C++ project.
Comment 3 Vladimir Voskresensky 2016-09-19 15:39:01 UTC
Alexander demonstrated that even local Quote doesn't work from UNC drive:
fixed in
http://hg.netbeans.org/cnd-main/rev/84fe939c8432
Comment 4 Vladimir Voskresensky 2016-09-19 15:40:03 UTC
Alexander, please, review and nominate if it is needed
Comment 5 Vladimir Voskresensky 2016-09-19 17:21:52 UTC
extra fix for i18n
http://hg.netbeans.org/cnd-main/rev/6cd4012b6091
Comment 6 Quality Engineering 2016-09-20 02:37:39 UTC
Integrated into 'main-silver', will be available in build *201609200002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/84fe939c8432
User: Vladimir Voskresensky <vv159170@netbeans.org>
Log: fixed #268070 - "Always relative" is not working for remote project
- do not change UNC file paths
Comment 7 soldatov 2016-09-20 11:38:48 UTC
Verified in internal build (Quote on \\Host\folder)
Comment 8 Alexander Simon 2016-09-20 12:14:07 UTC
transplanted in releases, branch release82:
http://hg.netbeans.org/releases/rev/155a7af13727
http://hg.netbeans.org/releases/rev/fcd54d5ad1cf
increment spec version:
http://hg.netbeans.org/releases/rev/e7da9da74605