Yes, it is in this location that changes the file destination, only the directory separator is /
and not \
.
If there is a directory with the same name as the output file, you may need other settings like putting the . exe at the end of the name in the run configuration (Propriedades -> Executar -> Comando Executar
).
Documentation of what it means is in the archive Makefile
, or at least clues for those that are not exactly the same as those listed. In the project, it is in a folder called "Arquivos Importantes" or "Important Files" in the English version.
- CND_DISTDIR: distribution directory, where the final files will be;
- CND_CONF: It doesn’t say, but it’s the configuration used, it seems equivalent to
${CONF}
: Has value Debug
, Release
or another name you create in the project properties;
- CND_PLATFORM: the target platform, from what I saw is the name of the compiler (defined by you) and the host operating system that is building the program. It can be
Cygwin_4.x-Windows
, or Arduino-Windows
, Arduino-Linux
, AVR-Linux
, etc..
You can also, without changing the program’s destination, copy it to the location you want by adding the command in the section .build-post
of Makefile
. If you want to run/debug in the new location change the settings of the Run and Debug commands. Example: after lines
.build-post: .build-impl
# Add your post 'build' code here...
In Windows, add the line:
${CP} ${CND_ARTIFACT_PATH_${CONF}}.exe ${USERPROFILE}/Desktop/
On Linux, the line is:
${CP} ${CND_ARTIFACT_PATH_${CONF}} ${HOME}/Desktop/
Important: This line starts with a character [Tab]
, otherwise does not work.
Important 2: Not always the ${USERPROFILE}/Desktop/
works. For example: In Windows I changed my desktop folder, and this path does not copy the file to my desktop. (Because I changed is another story) On Linux the environment I don’t even use the Desktop folder.
When we generate the
.jar
application it already goes to the project folder that does not suit you?– Wellington Avelino
No. Here the project is in C. The file it generates is a . exe (Windows), but in the context, the same as the . jar which is the executable of a Java project. But what I intend to do, is that . exe or . jar go to a directory defined, for example, I want that after the compilation of the project that is in Folder C: Netbeans Projectotest, the executable stops on my Desktop, ie the . exe or . jar.
– Vynstus
It would be appropriate to change the title to something like "Setting up the compiler output path in Netbeans" (as an example). The way it is, it looks like you want to set up the location of gcc, javac or another compiler you’re using.
– fbiazi