Skip to content

ENT-4664: Added sys.policy_release_id#5866

Merged
larsewi merged 3 commits intocfengine:masterfrom
victormlg:policy_release_id
Sep 8, 2025
Merged

ENT-4664: Added sys.policy_release_id#5866
larsewi merged 3 commits intocfengine:masterfrom
victormlg:policy_release_id

Conversation

@victormlg
Copy link
Contributor

No description provided.

@victormlg victormlg requested a review from larsewi August 27, 2025 12:52
@victormlg victormlg requested a review from larsewi August 29, 2025 08:08
@larsewi
Copy link
Contributor

larsewi commented Aug 29, 2025

Could you add an acceptance test to check that this variable is defined?

@larsewi
Copy link
Contributor

larsewi commented Aug 29, 2025

@cf-bottom Jenkins please :)

@cf-bottom
Copy link

@larsewi
Copy link
Contributor

larsewi commented Sep 2, 2025

logging.c:651:28: error: 'strchrnul' is only available on macOS 15.4 or newer [-Werror,-Wunguarded-availability-new]
651 | char *next_token = strchrnul(token, ',');
| ^~~~~~~~~

This is unrelated to you PR, but you can fix it by doing what I did in this PR NorthernTechHQ/libntech#255

@victormlg victormlg force-pushed the policy_release_id branch 2 times, most recently from df278e3 to d638c03 Compare September 2, 2025 09:53
@victormlg victormlg requested a review from larsewi September 2, 2025 10:25
Copy link
Contributor

@larsewi larsewi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The libntech should already updated on the master branch (see #5867). Try to fetch all and rebase with upstream master. In the third commit, please explain why you specified the deployment target in the commit message. Otherwise the commit message is not very useful.

Ticket: ENT-4664
Signed-off-by: Victor Moene <victor.moene@northern.tech>
Signed-off-by: Victor Moene <victor.moene@northern.tech>
The function 'strchrnul' has been marked as being introduced in macOS
15.4, although it seems to have been working for as long as we have been
testing on macOS. Since warnings are treated as errors, the build will
fail. Hence, the simplest way to silence the warning is, it to specify
the deployment target to be a minimum of macOS 15.4.

```
logging.c:651:28: error: 'strchrnul' is only available on macOS 15.4 or newer [-Werror,-Wunguarded-availability-new]
  651 |         char *next_token = strchrnul(token, ',');
  CC       queue.lo
      |                            ^~~~~~~~~
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_string.h:198:9: note: 'strchrnul' has been marked as being introduced in macOS 15.4 here, but the deployment target is macOS 15.0.0
  198 |         strchrnul(const char *__s, int __c);
  CC       rb-tree.lo
      |         ^
logging.c:651:28: note: enclose 'strchrnul' in a __builtin_available check to silence this warning
  651 |         char *next_token = strchrnul(token, ',');
      |                            ^~~~~~~~~
1 error generated.
```

It has been done similarly here: NorthernTechHQ/libntech#255

Signed-off-by: Victor Moene <victor.moene@northern.tech>
@larsewi
Copy link
Contributor

larsewi commented Sep 2, 2025

@cf-bottom Jenkins please :)

@cfengine cfengine deleted a comment from cf-bottom Sep 3, 2025
@cfengine cfengine deleted a comment from cf-bottom Sep 4, 2025
@cf-bottom
Copy link

@larsewi larsewi merged commit d3c0488 into cfengine:master Sep 8, 2025
39 of 41 checks passed
@craigcomstock
Copy link
Contributor

@victormlg @larsewi this is the kind of thing we need to backport. I will back port it to 3.24.x here: #5780 to get that PR green. 👍 I will do it also for 3.21 separately as I am not back-porting my other change to 3.21.

@craigcomstock
Copy link
Contributor

3.21 looks good after this is cherry-picked... #5892

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

4 participants