<?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>ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/92581/ncs_add_partition_manager_config-not-working</link><description>ncs_add_partition_manager_config does not appear to be working. I am using ncs 2.1.0 and doing a build with MCUboot. Am I doing something wrong below? 
 I am using the following in a CMakeLists.txt to add a region to use for storage: 
 
 message ( &amp;quot;adding</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 16 Jan 2025 10:51:38 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/92581/ncs_add_partition_manager_config-not-working" /><item><title>RE: ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/thread/518600?ContentTypeID=1</link><pubDate>Thu, 16 Jan 2025 10:51:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ee4ef77f-e21f-472b-a7bd-f24c79e1a325</guid><dc:creator>bringert</dc:creator><description>&lt;p&gt;Great suggestion, thank you! I ran into the same problem, and this was the only way I could find to add dynamic partitions in a standalone project without modifying the SDK:&lt;/p&gt;
&lt;pre&gt;...&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;# This is a hack to work around ncs_add_partition_manager_config() behavior&lt;br /&gt;# Without this, we have to modify the partition manager subsystem in&lt;br /&gt;# &lt;a href="https://github.com/nrfconnect/sdk-nrf/blob/main/subsys/partition_manager/CMakeLists.txt"&gt;github.com/.../CMakeLists.txt&lt;/a&gt; &lt;br /&gt;# to add a custom partition.&lt;br /&gt;# See discussion here:&lt;br /&gt;# &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/92581/ncs_add_partition_manager_config-not-working"&gt;devzone.nordicsemi.com/.../ncs_add_partition_manager_config-not-working&lt;/a&gt;&lt;br /&gt;function(my_ncs_add_partition_manager_config config_file)&lt;br /&gt; get_filename_component(pm_path ${config_file} REALPATH)&lt;br /&gt; get_filename_component(pm_filename ${config_file} NAME)&lt;br /&gt;&lt;br /&gt;if (NOT EXISTS ${pm_path})&lt;br /&gt; message(FATAL_ERROR&lt;br /&gt; &amp;quot;Could not find specified partition manager configuration file &amp;quot;&lt;br /&gt; &amp;quot;${config_file} at ${pm_path}&amp;quot;&lt;br /&gt; )&lt;br /&gt; endif()&lt;br /&gt;&lt;br /&gt;set_property(GLOBAL APPEND PROPERTY&lt;br /&gt; PM_SUBSYS_PATHS&lt;br /&gt; ${pm_path}&lt;br /&gt; )&lt;br /&gt; set_property(GLOBAL APPEND PROPERTY&lt;br /&gt; PM_SUBSYS_OUTPUT_PATHS&lt;br /&gt; ${CMAKE_CURRENT_BINARY_DIR}/${pm_filename}&lt;br /&gt; )&lt;br /&gt;endfunction()&lt;br /&gt;&lt;br /&gt;my_ncs_add_partition_manager_config(pm.yml.flash_audio_buffer)&lt;br /&gt;&lt;br /&gt;find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})&lt;br /&gt;&lt;br /&gt;...&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/thread/474641?ContentTypeID=1</link><pubDate>Tue, 19 Mar 2024 13:45:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5c38388d-c4fa-4d47-87ae-cb877ef028b3</guid><dc:creator>grzegorz</dc:creator><description>&lt;p&gt;Actually the problem is in availability of ncs_add_partition_manager_config() in particular place in CMakeFiles.txt. It should be available before processing of yml files. So the workaround is to copy definition of this function into CMakeFiles.txt and place it and call it before find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE}). This way we get PM_SUBSYS_PATHS defined before Zephyr scripts are run.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/thread/447294?ContentTypeID=1</link><pubDate>Fri, 22 Sep 2023 21:00:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f8fd954b-1fe4-486d-bcbb-2252988104c7</guid><dc:creator>David Palchak</dc:creator><description>&lt;p&gt;We have the same problem on our project (out-of-tree project, need to&amp;nbsp;add a dynamic partition). The current design of partition manager is unnecessarily&amp;nbsp;shortsighted in this regard. One cannot add to a dynamic partition via a pm_static.yml file, and one cannot add to a dynamic partition using&amp;nbsp;ncs_add_partition_manager_config()&amp;nbsp;in an out-of-tree project.&lt;br /&gt;&lt;br /&gt;A reasonable&amp;nbsp;fix for this would be for the partition manager machinery to look for something like a `pm_config.cmake` or `pm_config_&amp;lt;board&amp;gt;.cmake&amp;#39;. The subsys/partition_manager/CMakeLists.txt would then include any such files before processing the list of partition manager configurations. An out-of-tree project could then add a call to&amp;nbsp;&lt;span&gt;ncs_add_partition_manager_config() in their local `pm_config.cmake`.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/thread/390272?ContentTypeID=1</link><pubDate>Tue, 11 Oct 2022 12:53:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:aad1158a-309b-4eb8-97bd-a11607738800</guid><dc:creator>denis</dc:creator><description>&lt;p&gt;I want to be able to build as a freestanding application, not a workspace application. &amp;nbsp;Having to maintain a modified nRF Connect SDK is not desirable (for most people I would think).&lt;/p&gt;
&lt;p&gt;I think&amp;nbsp;&lt;span&gt;ncs_add_partition_manager_config or something equivalent should be supported for out of tree use.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/thread/390166?ContentTypeID=1</link><pubDate>Tue, 11 Oct 2022 07:37:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:61c805b0-c01f-43e5-b0d2-343c2c60e6c1</guid><dc:creator>Marte Myrvold</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Thank you for clarifying. Then I agree that&amp;nbsp;ncs_add_partition_manager_config() is the correct solution, but you cannot use it in the application CMakeLists.txt.&lt;/p&gt;
&lt;p&gt;Instead, you must create your pm.yml.storage file under&amp;nbsp;&lt;a href="https://github.com/nrfconnect/sdk-nrf/tree/v2.1.0/subsys/partition_manager"&gt;nrf/subsys/partition_manager&lt;/a&gt;, and then add your partition manager configuration file in partition manager&amp;#39;s CMakeLists.txt as is done for other subsystems. See&amp;nbsp;&lt;a href="https://github.com/nrfconnect/sdk-nrf/blob/v2.1.0/subsys/partition_manager/CMakeLists.txt#L49"&gt;https://github.com/nrfconnect/sdk-nrf/blob/v2.1.0/subsys/partition_manager/CMakeLists.txt#L49&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Marte&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/thread/390085?ContentTypeID=1</link><pubDate>Mon, 10 Oct 2022 15:45:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:34aea9a5-18fc-40d6-84b4-fd592f2a1d96</guid><dc:creator>denis</dc:creator><description>&lt;p&gt;Use case is to have a storage subsystem (in subsys/storage) that when enabled via Kconfig will reserve the wynd_storage area.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/thread/390065?ContentTypeID=1</link><pubDate>Mon, 10 Oct 2022 14:19:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ed8aacc3-c78a-4a9d-bd5e-32e6a2496949</guid><dc:creator>Marte Myrvold</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;It depends on your use case. What is the end goal of this?&lt;/p&gt;
&lt;p&gt;If all you want to do is to create a&amp;nbsp;wynd_storage partition, you should use pm_static.yml.&lt;/p&gt;
&lt;p&gt;If instead wynd_storage is a child image then you can use&amp;nbsp;ncs_add_partition_manager_config(), but for this it would be easier to just rename&amp;nbsp;pm.yml.storage to pm.yml and it will be added automatically, without having to use&amp;nbsp;ncs_add_partition_manager_config(). For this you can look at the&amp;nbsp;&lt;a href="https://github.com/nrfconnect/sdk-nrf/tree/main/samples/nrf5340/multicore"&gt;nRF5340: Multicore application&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Marte&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/thread/390006?ContentTypeID=1</link><pubDate>Mon, 10 Oct 2022 11:57:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b619e8db-1aa8-4293-ab27-53db9f711186</guid><dc:creator>Marte Myrvold</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I have asked the developers about clarification, and I will get back to you.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Marte&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/thread/389447?ContentTypeID=1</link><pubDate>Wed, 05 Oct 2022 14:11:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:adad6fa4-d4a1-4331-aa6f-eb5e13b70421</guid><dc:creator>denis</dc:creator><description>&lt;p&gt;I assume this is a bug that will be fixed in a future release?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ncs_add_partition_manager_config not working</title><link>https://devzone.nordicsemi.com/thread/389411?ContentTypeID=1</link><pubDate>Wed, 05 Oct 2022 12:40:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:eb3e3d21-ff7d-4bb5-be49-fc4b4135304c</guid><dc:creator>Marte Myrvold</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;The issue is that partition_manager.cmake is called before ncs_add_partition_manager_config. The way ncs_add_partition_manager_config works is that it adds partition manager configurations defined by subsystems to PM_SUBSYS_PATHS, which is used by partition_manager.cmake to create the partitions. So the wynd_storage partition will not be configured, since it is added to PM_SUBSYS_PATHS after partition_manager.cmake has already run,&lt;/p&gt;
&lt;p&gt;I would recommend using pm_static.yml and adding wynd_storage there instead.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Marte&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>