**Describe the bug**
The docs say:
> `if` - requires the first operand to be fulfilled if the second is (reverse 
> implication)
> `if else` - same as above but requires the third operand to be fulfilled if 
> the second is not

I added the following to `redhat-rpm-macros`:
> `Requires: (add-determinism if python3-libs else add-determinism-nopython)`

When I install the package I get:
```console
$ mock -r fedora-rawhide-x86_64 --uniqueext=a -i 
/var/tmp/redhat-rpm-config-289-1.fc41.noarch.rpm
...
Upgrading:                                                                 
 redhat-rpm-config             noarch 289-1.fc41     @commandline 183.5 KiB
   replacing redhat-rpm-config noarch 288-1.fc41     fedora       183.3 KiB
Installing dependencies:                                                   
 add-determinism               x86_64 0.2.0-1.fc41   fedora         2.6 MiB
 expat                         x86_64 2.6.2-1.fc41   fedora       280.8 KiB
 libb2                         x86_64 0.98.1-11.fc40 fedora        42.2 KiB
 mpdecimal                     x86_64 2.5.1-9.fc40   fedora       200.9 KiB
 python-pip-wheel              noarch 24.0-2.fc41    fedora         1.5 MiB
 python3-libs                  x86_64 3.12.3-2.fc41  fedora        40.9 MiB
 tzdata                        noarch 2024a-5.fc41   fedora         1.6 MiB
```

`python3-libs` is being installed, which means that was *not* installed 
previously. I expected `add-determinism-nopython` would be installed instead.

(When changed to
> `Requires: (add-determinism if python3-libs)`

then `add-determinism` is not installed:
```console
$ mock -r fedora-rawhide-x86_64 --uniqueext=a -i 
/var/lib/mock/fedora-rawhide-x86_64-a/result/redhat-rpm-config-289-1.fc41.noarch.rpm
...
Upgrading:                                                             
 redhat-rpm-config             noarch 289-1.fc41 @commandline 183.5 KiB
   replacing redhat-rpm-config noarch 288-1.fc41 fedora       183.3 KiB
Transaction Summary:
 Upgrading:         1 packages
 Replacing:         1 packages
```
)


-- 
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/3082
You are receiving this because you are subscribed to this thread.

Message ID: <rpm-software-management/rpm/issues/3...@github.com>
_______________________________________________
Rpm-maint mailing list
Rpm-maint@lists.rpm.org
http://lists.rpm.org/mailman/listinfo/rpm-maint

Reply via email to