Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation for %{expr:..} and %[...] is missing from rpm.org/user_doc/macros.html #1519

Closed
hroncok opened this issue Jan 27, 2021 · 9 comments

Comments

@hroncok
Copy link
Contributor

hroncok commented Jan 27, 2021

I was searching for it in https://rpm.org/user_doc/macros.html but found nothing.

@pmatilai
Copy link
Member

Try the in-tree documentation instead: https://github.com/rpm-software-management/rpm/blob/master/doc/manual/macros.md

We'll need to have the rpm.org content pointing to the in-tree documenation sooner than later...

@pmatilai
Copy link
Member

The expression section could also use some more concrete examples...

@pmatilai
Copy link
Member

...such as those in the release notes (expressions section): https://rpm.org/wiki/Releases/4.16.0

@hroncok
Copy link
Contributor Author

hroncok commented Jan 27, 2021

Thanks for the pointers.

@hroncok hroncok changed the title Documentation for %{expr:..} and %[...] is missing Documentation for %{expr:..} and %[...] is missing from rpm.org/user_doc/macros.html Jan 27, 2021
@hroncok
Copy link
Contributor Author

hroncok commented Jan 27, 2021

Related question: There is no %ifarch expression, right? E.g. %{arch:a b c d}/%{narch:a b c d} to evaluate to 0/1.

@pmatilai
Copy link
Member

No, %if is strictly a spec construct. You can evaluate against the arch macros though, eg
%[ "%{_target_cpu}" == "x86_64" ? 1 : 0]

@hroncok
Copy link
Contributor Author

hroncok commented Jan 27, 2021

Thanks.

@hroncok
Copy link
Contributor Author

hroncok commented Jan 27, 2021

Feel free to close or repurpose this issue, but note that the docs situation is confusing.

@dmnks
Copy link
Contributor

dmnks commented Feb 12, 2021

Thanks, closing in lieu of rpm-software-management/rpm-web#19.

@dmnks dmnks closed this as completed Feb 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants