<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Signing file with a relative key path</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/115651/signing-file-with-a-relative-key-path</link><description>Hello, 
 In my project I have b0, mcuboot and an app. My nRF SDK version is v2.7.0. 
 My project works fine if I use an absolute address in SB_CONFIG_BOOT_SIGNATURE_KEY_FILE but it doesn&amp;#39;t work anymore when I put a relative address (SB_CONFIG_BOOT_SIGNATURE_KEY_FILE</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 29 Oct 2024 12:16:27 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/115651/signing-file-with-a-relative-key-path" /><item><title>RE: Signing file with a relative key path</title><link>https://devzone.nordicsemi.com/thread/508340?ContentTypeID=1</link><pubDate>Tue, 29 Oct 2024 12:16:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d85aaf3f-ba2c-4832-b92f-ea0f1f93deea</guid><dc:creator>Menon</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Sorry I couldn’t test this myself, as I was tied up with other work. But I &lt;a href="https://devzone.nordicsemi.com/support-private/support/331553"&gt;found a similar issue reported earlier&lt;/a&gt; where the customer was able to get it working. Please have a look and let me know if this helps. If it doesn’t, I can try it on my end.&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Abhijith&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Signing file with a relative key path</title><link>https://devzone.nordicsemi.com/thread/508310?ContentTypeID=1</link><pubDate>Tue, 29 Oct 2024 09:33:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f2ce79e8-6afb-419c-bf9b-a3a2f9e353d5</guid><dc:creator>QuentinD</dc:creator><description>&lt;p&gt;Could you answer me?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thank you&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Signing file with a relative key path</title><link>https://devzone.nordicsemi.com/thread/507784?ContentTypeID=1</link><pubDate>Thu, 24 Oct 2024 14:05:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:22af2589-d4d0-4ae9-9464-df5f0989eaa7</guid><dc:creator>QuentinD</dc:creator><description>&lt;p&gt;Have you been able to try?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Signing file with a relative key path</title><link>https://devzone.nordicsemi.com/thread/507592?ContentTypeID=1</link><pubDate>Wed, 23 Oct 2024 12:51:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:793904ea-294e-4fab-9b79-8479f27b35bc</guid><dc:creator>QuentinD</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;No it doesn&amp;#39;t work.&amp;nbsp;&lt;/p&gt;
&lt;p style="text-align:left;"&gt;For m&amp;#39;y key to be taken into account during compilation, I need to define SB_CONFIG_BOOT_SIGNATURE_KEY_FILE in the sysbuild.conf file. Doing it instead in the applications CMakeLists.txt or in the sysbuild.cmake does not fix my problem.&lt;/p&gt;
&lt;p style="text-align:left;"&gt;Could you try on your side qnd tell me what do you do exactly to do it?&lt;/p&gt;
&lt;p style="text-align:left;"&gt;Thank you&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Signing file with a relative key path</title><link>https://devzone.nordicsemi.com/thread/507429?ContentTypeID=1</link><pubDate>Tue, 22 Oct 2024 16:28:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c46ffb2d-8d54-4329-b63a-207b1e06ef91</guid><dc:creator>Menon</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;I&amp;nbsp; think this needs to be done as one of the first things in your &lt;code&gt;CMakeLists.txt&lt;/code&gt;, or before any &lt;code&gt;find_package&lt;/code&gt;, &lt;code&gt;include&lt;/code&gt;, or SDK-related commands. Set and convert paths early in &lt;code&gt;CMakeLists.txt&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Kind Regards,&lt;/p&gt;
&lt;p&gt;Abhijith&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Signing file with a relative key path</title><link>https://devzone.nordicsemi.com/thread/507411?ContentTypeID=1</link><pubDate>Tue, 22 Oct 2024 14:40:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:25521ba7-afac-47f0-8b28-ece8e7033da7</guid><dc:creator>QuentinD</dc:creator><description>&lt;p&gt;My board is the PCA10056 (nRF52840 DK)&lt;/p&gt;
&lt;p&gt;If I replace the command &amp;quot;set(keyfile &amp;quot;${SB_CONFIG_BOOT_SIGNATURE_KEY_FILE}&amp;quot; in b0_mcuboot_signing.cmake file by yours, it works but it works also if I write &amp;quot;set(keyfile &amp;quot;${APP_DIR}/keys/mcuboot_private.pem&amp;quot;.&lt;/p&gt;
&lt;p&gt;So where can I put this command to not modify the SDK files ?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thank you&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Signing file with a relative key path</title><link>https://devzone.nordicsemi.com/thread/507207?ContentTypeID=1</link><pubDate>Mon, 21 Oct 2024 18:22:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e4d880de-255a-4e47-bb37-eaeab55ebf19</guid><dc:creator>Menon</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;In nRF Connect SDK v2.7.0, the introduction of Sysbuild might have changed how the build system manages paths and configurations, but I&amp;#39;m not completely sure as I haven&amp;#39;t tested it myself. Which Nordic chip/DK are you using?&lt;/p&gt;
&lt;p&gt;Could you try using &lt;code&gt;get_filename_component&lt;/code&gt; inside CMake? This command will convert a relative path to an absolute path. For example: &lt;code&gt;get_filename_component(keyfile &amp;quot;${SB_CONFIG_BOOT_SIGNATURE_KEY_FILE}&amp;quot; ABSOLUTE ${CMAKE_CURRENT_SOURCE_DIR})&lt;/code&gt;.&lt;em style="font-family:inherit;"&gt;&amp;nbsp;&lt;a href="https://github.com/nrfconnect/sdk-nrf/blob/504a1446cbe433a7e2c482bc61daacfc02d228a8/share/ncs-package/cmake/NcsConfig.cmake#L7"&gt;See this&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;pre class="ui-code" data-mode="text"&gt;#  Define the relative APP_DIR

# Define the relative path to the key file

# Convert the relative path to an absolute path for signing purposes (using the get_filename_component())&lt;/pre&gt;&lt;br /&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Kind Regards,&lt;/p&gt;
&lt;p&gt;Abhijith&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>