You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
rJava/jri compilation fails with parallel make (-j) #1
Run ./configure in the root directory of the extracted archive
Run make -j2 in the jri subdirectory
This fails with the above error, but using make -j1 works.
To be able to use install.packages("rJava") in R, I temporarily set MAKE=make -j1 in my ~/.R/Makevars.
Since it took quiet some time to track down the error, I thought I should write about it here as a reference for other affected users. Maybe it would also be worth mentioning this potential error in the installation notes on http://www.rforge.net/rJava/.
Parallel make is in general not supported, so by changing MAKE your'e entirely on your own (btw that should never be used to set make flags - it defines the make program, not its flags - those are separate). I'll flag this as an enhancement in case someone wants to contribute a pull request.
Up to now I did not have any problems installing contributed R packages using parallel make, I only recognized that I am "entirely on my own" when installing rJava.
Thanks for pointing me to MAKEFLAGS (I now set MAKEFLAGS=-j in my ~/.R/Makevars).
You can also set MAKEFLAGS in a makefile, to specify additional flags
that should also be in effect for that makefile
Telling make that way that the makefile infrastructure of rJava's jri is incompatible with parallelization works on my system (Ubuntu Linux, GNU make).
I'm not an expert, but it seems to me that this is no portable solution since the -j argument is not declared in POSIX make. So I have no idea what happens in other implementations of make...
Activity
s-u commentedon Jan 24, 2014
Parallel make is in general not supported, so by changing
MAKEyour'e entirely on your own (btw that should never be used to set make flags - it defines the make program, not its flags - those are separate). I'll flag this as an enhancement in case someone wants to contribute a pull request.bastistician commentedon Jan 24, 2014
Up to now I did not have any problems installing contributed R packages using parallel make, I only recognized that I am "entirely on my own" when installing rJava.
Thanks for pointing me to
MAKEFLAGS(I now setMAKEFLAGS=-jin my ~/.R/Makevars).It might be an idea to set
MAKEFLAGS=-j1in rJava'sjri/Makefile.allsince https://www.gnu.org/software/make/manual/html_node/Options_002fRecursion.html says:Telling make that way that the makefile infrastructure of rJava's jri is incompatible with parallelization works on my system (Ubuntu Linux, GNU make).
I'm not an expert, but it seems to me that this is no portable solution since the -j argument is not declared in POSIX make. So I have no idea what happens in other implementations of make...
rJava does not support parallel make
rJava does not support parallel make