<?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>Can&amp;#39;t compile section variables in unit test framework</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/53579/can-t-compile-section-variables-in-unit-test-framework</link><description>I am using the Ceedling framework for unit testing my firmware. This has qorked quite well. But now I wanted to use the section variables to decouple my code a bit more. And I could not compile them on windows, using gcc. The problem is that I can&amp;#39;t use</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 23 Nov 2021 08:20:50 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/53579/can-t-compile-section-variables-in-unit-test-framework" /><item><title>RE: Can't compile section variables in unit test framework</title><link>https://devzone.nordicsemi.com/thread/340255?ContentTypeID=1</link><pubDate>Tue, 23 Nov 2021 08:20:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:aab98c9a-5877-4b31-bbe0-5fe9c38db80a</guid><dc:creator>andy</dc:creator><description>&lt;p&gt;../send_rf.c:70:33: error: section attribute cannot be specified for local variables&lt;br /&gt; 70 | NRF_QUEUE_DEF(queue_data_t, my_data_queue, 5, NRF_QUEUE_MODE_NO_OVERFLOW);&lt;br /&gt; | ^~~~~~~~~~~~~&lt;br /&gt;../../sdk_nordic/components/libraries/experimental_section_vars/nrf_section.h:149:5: note: in definition of macro &amp;#39;NRF_SECTION_ITEM_REGISTER&amp;#39;&lt;br /&gt; 149 | section_var __attribute__ ((section(&amp;quot;.&amp;quot; STRINGIFY(section_name)))) __attribute__((used))&lt;br /&gt; | ^~~~~~~~~~~&lt;br /&gt;../send_rf.c:70:5: note: in expansion of macro &amp;#39;NRF_QUEUE_DEF&amp;#39;&lt;br /&gt; 70 | NRF_QUEUE_DEF(queue_data_t, my_data_queue, 5, NRF_QUEUE_MODE_NO_OVERFLOW);&lt;br /&gt; | ^~~~~~~~~~~~~&lt;br /&gt;../send_rf.c:70:5: error: &amp;#39;used&amp;#39; attribute ignored [-Werror=attributes]&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Can't compile section variables in unit test framework</title><link>https://devzone.nordicsemi.com/thread/340233?ContentTypeID=1</link><pubDate>Tue, 23 Nov 2021 07:15:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:449d24e8-1f73-44ff-b6cc-e9f46b3bcb79</guid><dc:creator>andy</dc:creator><description>&lt;p&gt;when use the nrf_queue_def, &amp;quot;section attribute cannot be specified for local variables&amp;quot;,i donot konw why,i have declear the &amp;quot;.nrf_queue&amp;quot; in the ld file.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Can't compile section variables in unit test framework</title><link>https://devzone.nordicsemi.com/thread/216611?ContentTypeID=1</link><pubDate>Thu, 24 Oct 2019 12:12:03 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:693be1d8-7bb7-4e8d-8b80-6b2b86eeef5f</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;I can check with the test team if they may have some pointers.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>