[Fedora-r-devel-list] R-java and R-java-devel

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Pierre asked me on irc this afternoon to help him get R-rJava building,
and when I looked at it, I discovered what was wrong.

The Fedora R-core package (the minimum bits needed to get R working)
does not require java. This is intentional, as java is not needed to use
R, and it would be a notable increase in default footprint if we made it
a strict dependency. In the %post for R-core, we run R CMD javareconf,
but that only does something useful if you have a java environment present.

When Pierre was trying to build rJava, R-devel and R-core were being
installed before java-devel and java, thus, the R CMD javareconf run was
happening with no java environment present in the buildroot.

Initially, I tried to resolve this by having the R-rJava package run R
CMD javareconf again during %prep, but this doesn't work, because the
package isn't built as root, and R couldn't update the system configs.
So, as a workaround, I added two new "subpackages" to the main R package:

R-java : A metapackage with no files that simply Requires(post): R-core,
java
R-java-devel: A metapackage with no files that simple Requires(post):
R-devel, java-devel

Both metapackages call R CMD javareconf in their %post (its the same
invocation that we use for R-core). There is some redundancy (it gets
called when we install R-core, then again when we install R-java, for
example), but it isn't harmful.

By then changing the BuildRequires in the R-rJava package from R-devel
to R-java-devel, I was able to get that package to build properly.

There are several advantages to these metapackages:

1. Users who want an R install that comes with the Fedora OpenJDK
preconfigured can yum install R-java.
2. Developers who want an R development environment that has the Fedora
OpenJDK preconfigured can yum install R-java-devel.
3. It does not change the default behavior of the R-core, R-devel (and
R) packages.
4. Any addon R modules that require java to be present and configured
can now use BuildRequires: R-java-devel and be built for Fedora in koji.

If you have any questions about this change, please feel free to ask! :)

Thanks,

~spot

_______________________________________________
Fedora-r-devel-list mailing list
Fedora-r-devel-list@xxxxxxxxxx
http://www.redhat.com/mailman/listinfo/fedora-r-devel-list

[Index of Archives]     [Fedora Users]     [Fedora Development]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux