Skip to content

rjulia on Windows/RStudio #16

@dgromer

Description

@dgromer

Building rjulia on Windows 7 64-bit with R 3.2.0 and Julia 0.3.9 (using devtools::install_github("armgong/RJulia", args = "--no-multiarch") fails with the following error:

* installing *source* package 'rjulia' ...
** libs
gcc -m64 -I"C:/R/R-32~1.0/include" -DNDEBUG -I"C:\\Julia-0.3.9\\bin"/../../src -I"C:\\Julia-0.3.9\\bin"/../../src/support -I"C:\\Julia-0.3.9\\bin"/../include -I"C:\\Julia-0.3.9\\bin"/../include/julia    -I"d:/RCompile/r-compiling/local/local320/include"     -O2 -Wall  -std=gnu99 -mtune=core2 -c Julia_R.c -o Julia_R.o
In file included from C:\Julia-0.3.9\bin/../include/julia/uv.h:59:0,
                 from C:\Julia-0.3.9\bin/../include/julia/ios.h:5,
                 from C:\Julia-0.3.9\bin/../include/julia/libsupport.h:11,
                 from C:\Julia-0.3.9\bin/../include/julia/julia.h:10,
                 from Julia_R.c:11:
C:\Julia-0.3.9\bin/../include/julia/uv-win.h:241:3: error: unknown type name 'SRWLOCK'
make: *** [Julia_R.o] Error 1
Warning: Ausführung von Kommando 'make -f "Makevars" -f "C:/R/R-32~1.0/etc/x64/Makeconf" -f "C:/R/R-32~1.0/share/make/winshlib.mk" SHLIB="rjulia.dll" WIN=64 TCLBIN=64 OBJECTS="Julia_R.o R_Julia.o dataframe.o embedding.o"' ergab Status 2
ERROR: compilation failed for package 'rjulia'
* removing 'C:/R/R-3.2.0/library/rjulia'
* restoring previous 'C:/R/R-3.2.0/library/rjulia'
Error: Command failed (1)

However, after adding a Makevars.win with the contents of the Makevars plus PKG_CPPFLAGS+= -D_WIN32_WINNT=0x0600 (see JuliaLang/julia#9973) solved this problem.

Now when loading the package from within RStudio, the R session crashes. When loading rjulia in a R session in cmd.exe everything works fine. Any ideas?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions