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.
Hi, After an upgrade to Netbeans 7.0 remote build doesn't work anymore if buildCommandWorkingDir is not empty. If it is anything at all (for example ".."), it just changes to the remote home directory and the build naturally fails. I tried setting absolute paths but the result is the same. In local builds it still works fine. As far as I can tell this is a regression from 6.9.1 where it worked perfectly.
I wasn't able to reproduce this so far. I tried creating a project that needs a custom build directory, for me it builds both locally and remotely, in both 7.0 and current dev. version (see my test project in the attachment; make should be launched in "./src" subdirectory). Please describe the structure of your project, this will hopefully help me to reproduce the situation. (If it was possible, I would even ask you to create a simple project that is similar to yours and demonstrates wrong behavior).
Created attachment 108725 [details] my sample project; I wasn't able to reproduce the probelm with it
Hi, thanks for looking into this so quickly. I experimented the sample project and finally managed to reproduce the problem with it. I think it happens only when the build working directory is outside of the project directory. Specifically, in your sample project I added a file "build.sh" to "wd-mkf/..". Its contents are: #!/bin/sh set -e cd wd-mkf/src make -f ../mk/Makefile $* Then changed the build working directory to ".." and the build command to "./build.sh". (I am attaching an archive with the project). The build works locally but fails remotely. Note that the remote path mapper maps the parent directory, not just the project directory, so the remote machine has access to "build.sh". Now it appears that the scope of the problem is smaller than what I thought initially, and this may seem like a contrived case, but for whatever it is worth it used to work in 6.9. In our project it is necessary because we have a huge "top level" project with a common SCONS build script in the top level directory. Each NB project is a subdirectory which must invoke the parent build. The trick is that it must be invoked from within the parent directory or otherwise Netbeans doesn't like the file paths in the error messages...
Created attachment 108726 [details] Updated sample project The archive is one directory deeper.
Hi, Please ignore my previous posts. I did further tests and the problem appears to be more subtle. It also depends on the exact configuration of the path mapper. I managed to reproduce it in your sample project by doing the following steps (again, I will attach the updated sample): 1. Extract the project to $HOME/tmp 2. Change the build command to "echo $PWD" - we dont't care about the build, we just want to know that the directory is right. 3. Change the project source path from "." to "src" 4. On the remote machine mount $HOME/tmp/wd-mkf to the host $HOME/tmp/wd-mkf 5. Configure the path mapper to map $HOME/tmp/wd-mkf/ to $HOME/tmp/wd-mkf/ 6. Perform a remote build The output of "echo $PWD" is $HOME instead of $HOME/tmp/wd-mkf
Created attachment 108728 [details] Second ppdated sample showing the problem It requires the path mapper to be mapping the project directory (wd-mkf). If however the path mapper is configured to map the parent directory instead of the project directory, it works.
Thank you very much for your investigation. Now I see. (But please note that "echo $PWD" can mislead, so I changed it with /bin/pwd).
http://hg.netbeans.org/releases/rev/4bdec20724c2 http://hg.netbeans.org/releases/rev/f5b2c4f591bc http://hg.netbeans.org/releases/rev/2b8ffcbd9b54
Integrated into 'releases' Changeset: http://hg.netbeans.org/releases/rev/ User: Log:
Integrated into 'main-golden' Changeset: http://hg.netbeans.org/main-golden/rev/ User: Log:
Should be added to test scenarios.