Thank you very much! This did the trick
>
> Well, the second install command has the wrong scope:
> install(CODE "include(version.cmake)")
> install(FILES firmware.hex
> RENAME firmware_\${version_string}.hex
> DESTINATION firmware)
>
I've tried that before, but without the
Am 20. Januar 2017 09:36:54 MEZ schrieb Wagner Martin
:
> Thanks for your answers.
>
> > >You will need to do the install as another target/command. For
>> >example:
>> >
>> >add_custom_command( TARGET version
>> >
Thanks for your answers.
> >You will need to do the install as another target/command. For
> >example:
> >
> >add_custom_command( TARGET version
> > POST_BUILD
> > COMMAND ${CMAKE_COMMAND} -D
>
Am 19. Januar 2017 15:26:47 MEZ schrieb "Gonzalo Garramuño"
:
>
>
>El 19/01/17 a las 05:30, Wagner Martin escribió:
>>
>> However, CMake needs to include version.cmake at first CMake run
>time,
>> which is not possible because it’s a generated file.
>>
>> Is there any other
El 19/01/17 a las 05:30, Wagner Martin escribió:
However, CMake needs to include version.cmake at first CMake run time,
which is not possible because it’s a generated file.
Is there any other way to do the rename?
You will need to do the install as another target/command. For example:
An: Wagner Martin
Cc: cmake@cmake.org
Betreff: Re: [CMake] install() rename with version string
You can try:
include(version.cmake OPTIONAL)
which will make include tolerate the absence of version.cmake,
but then your install statement will only be OK after version.cmake has been
created.
2017-01
You can try:
include(version.cmake OPTIONAL)
which will make include tolerate the absence of version.cmake,
but then your install statement will only be OK after version.cmake has
been created.
2017-01-19 9:30 GMT+01:00 Wagner Martin :
> Hello,
>
>
>
> I’ve
Hello,
I’ve searched for some time, but didn’t find anything useful. Most finds deal
with including version system stuff passed to header files for compilation.
I want to achieve something like that:
Include(version.cmake)
install(FILES firmware.hex RENAME firmware_${version_string}.hex)