Not sure if you were planning on fixing this, but I note that there has been an update since I last posted. Nevertheless, I still have problems when trying to run the demos:
> fit1 <- stan_demo(68)
Do you want to download the example models?
1: Download to include directory of the rstan package
2: Download to the temporary directory
3: Do not download
Selection: 2
trying URL 'https://github.com/stan-dev/example-models/archive/master.zip'
downloaded 27.8 MB
> "N" <- 8
> "sigma_y" <- c(15,10,16,11,9,11,10,18)
> "y" <- c(28,8,-3,7,-1,1,18,12)
Error in compileCode(f, code, language = language, verbose = verbose) :
Compilation ERROR, function(s)/method(s) not created! /usr/bin/ld.gold: error: filecab2dc710.o:1:3: invalid character
/usr/bin/ld.gold: error: filecab2dc710.o:1:3: syntax error, unexpected $end
/usr/bin/ld.gold: error: filecab2dc710.o: not an object or archive
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [filecab2dc710.so] Error 1
In addition: Warning message:
In system(cmd, intern = !verbose) :
running command '/opt/R/3.5.2/lib/R/bin/R CMD SHLIB filecab2dc710.cpp 2> filecab2dc710.cpp.err.txt' had status 1
Error in sink(type = "output") : invalid connection
> fit1 <- stan_demo(1)
> "score1" <-
+ c(0.446, 0.334, -0.233, -0.304, -0.256, 0.515, -0.652, 0.271, -0.556,
+ 0.955, 0.307, -0.434, -0.272, -0.404, 0.415, 0.39, -0.755, 0. .... [TRUNCATED]
> "party" <-
+ c(1, 1, 0, 0, 0, 1, 0, 1, 0, 1, 1, 0, 0, 0, 1, 1, 0, 1,
+ 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1,
+ 1, 0, 1, 0, 1, 1, 0 .... [TRUNCATED]
> "x" <-
+ c(0.62073, 0.50803, 0.38243, 0.29769, 0.32751, 0.53766, 0.20003, 0.52211,
+ 0.31267, 0.64143, 0.69113, 0.4386, 0.30166, 0.25836, 0.51547, .... [TRUNCATED]
> "N" <- 357
Error in compileCode(f, code, language = language, verbose = verbose) :
Compilation ERROR, function(s)/method(s) not created! clang: error: unable to execute command: Killed
clang: error: clang frontend command failed due to signal (use -v to see invocation)
clang version 5.0.0-3~16.04.1 (tags/RELEASE_500/final)
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/bin
clang: note: diagnostic msg: PLEASE submit a bug report to http://llvm.org/bugs/ and include the crash backtrace, preprocessed source, and associated run script.
clang: note: diagnostic msg:
********************
PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang: note: diagnostic msg: /tmp/fileca40943554-1385b3.cpp
clang: note: diagnostic msg: /tmp/fileca40943554-1385b3.sh
clang: note: diagnostic msg:
********************
make: *** [fileca40943554.o] Error 254
In addition: Warning message:
In system(cmd, intern = !verbose) :
running command '/opt/R/3.5.2/lib/R/bin/R CMD SHLIB fileca40943554.cpp 2> fileca40943554.cpp.err.txt' had status 1
Error in sink(type = "output") : invalid connection