jpackage Are the RPM Requires necessary?

Sverre Moe sverre.moe at gmail.com
Thu Mar 26 22:23:08 UTC 2020


tor. 26. mar. 2020 kl. 23:21 skrev Sverre Moe <sverre.moe at gmail.com>:

> tor. 26. mar. 2020 kl. 21:29 skrev Alexey Semenyuk <
> alexey.semenyuk at oracle.com>:
>
>>
>>
>> On 3/26/2020 4:13 PM, Sverre Moe wrote:
>>
>> tor. 26. mar. 2020 kl. 20:41 skrev Alexey Semenyuk <
>> alexey.semenyuk at oracle.com>:
>>
>>>
>>>
>>> On 3/26/2020 11:17 AM, Sverre Moe wrote:
>>> > Running jpackage to build an RPM will add some Requires to the package.
>>> >
>>> > It comes from the Template file:
>>> >
>>> https://github.com/openjdk/jdk/blob/jdk-14%2B36/src/jdk.incubator.jpackage/linux/classes/jdk/incubator/jpackage/internal/resources/template.spec
>>> <https://urldefense.com/v3/__https://github.com/openjdk/jdk/blob/jdk-14*2B36/src/jdk.incubator.jpackage/linux/classes/jdk/incubator/jpackage/internal/resources/template.spec__;JQ!!GqivPVa7Brio!M9XkBzPXiKm1ZIWttGJG4VL4Wf0-KGz9x6MXZQGaSDqz64B9k-Uh1JtNLScPm0aHPUWS$>
>>> >
>>> > Autoprov: 0
>>> > Autoreq: 0
>>> > %if "xPACKAGE_DEFAULT_DEPENDENCIES" != x ||
>>> "xPACKAGE_CUSTOM_DEPENDENCIES"
>>> > != x
>>> > Requires: PACKAGE_DEFAULT_DEPENDENCIES PACKAGE_CUSTOM_DEPENDENCIES
>>> > %endif
>>> >
>>> > Building on OpenSUSE will give us these Requires:
>>> > +%if "xglibc, libX11-6, libXau6, libXext6, libXi6, libXrender1,
>>> libXtst6,
>>> > libasound2, libxcb1, libz1" != x || "x" != x
>>> > +Requires: glibc, libX11-6, libXau6, libXext6, libXi6, libXrender1,
>>> > libXtst6, libasound2, libxcb1, libz1
>>> > +%endif
>>> > +
>>> > +#avoid ARCH subfolder
>>> >
>>> > We override the RPM spec file with resource directory. I copied the RPM
>>> > spec file content from the one jpackage generated and added something
>>> extra
>>> > to it.
>>> >
>>> > Unfortunately this RPM will not install on Fedora, but installs fine on
>>> > OpenSUSE where I built it.
>>> >
>>> > Installing on Fedora will spew out this line for all these Requires.
>>> > nothing provides libX11-6
>>> >
>>> > Are these Requires needed by Java?
>>> Yes. The list of required packages is built automatically by jpackage by
>>> analyzing dependencies of dynamic libraries of JRE bundled with the
>>> application being packed.
>>> On different distributes the same package can have different names.
>>> Seems like the package that is named on OpenSuSE as ' libX11-6' is named
>>> as 'libX11' on Fedora.
>>>
>>
>> Not all Requires for OpenSUSE had an equivalent Fedoroa Requires
>>
>> Requires for OpenSUSE from jpackage
>> Requires: glibc, libX11-6, libXau6, libXext6, libXi6, libXrender1,
>> libXtst6, libasound2, libxcb1, libz1
>>
>> Requires for Fedora from jpackage:
>> Requires: glibc, libX11, libXau, libXext, libXi, libXrender, libXtst,
>> libxcb
>>
>> The RPM spec for Fedora does not get any Requires with libasound and libz.
>>
>> Probably this is because these packages are not installed on Fedora host
>> where you run jpackage.
>>
>> Actually, the "missing" packages from Fedora RPM Spec generated by
> jpackage, the libasound and libz does not exist on Fedora 30.
> Makes me wonder, because the RPM installs fine on Fedora without these.
>
> /Sverre
>

Though there could be a different package that provides these two on
Fedora, but then jpackage should have mention that package.

/Sverre


More information about the core-libs-dev mailing list