RApache seems not to work properly in combination with ggplot2 (while working properly with plot) on my Linux SuSE 12.2 server
When one does http://claree.univ-lille1.fr/R/brew/rapacheggplot which executes :
<%
require(ggplot2)
fp <- file.path("/home/calciu/public_html/rapacheggplot/images", "test.png") # set file path
furl <- paste("http://claree.univ-lille1.fr/~calciu/rapacheggplot/images/","test.png", sep="")
png(fp)
#plot(1:10, runif(10))
qp <- qplot(1:10, runif(10), geom=c("line", "smooth"), main="rapacheggplot")
ggsave(filename = fp, plot = qp)
dev.off()
%>
<html>
<head></head>
<body>
<img src="<%= furl %>" width="1000" height="500"/>
</body>
</html>
This source in brew produces an empty png file while, when replacing the two ggplot2 commands with a simple plot, the png file is correctly generated (see http://claree.univ-lille1.fr/R/brew/rapacheplot)
in apache2 error_log I get:
[Thu Nov 01 13:47:31 2012] [error] [client 192.168.134.122] rApache Notice!
[Thu Nov 01 13:47:32 2012] [notice] child pid 13538 exit signal Segmentation fault (11)
ggplot2 was compiled from source with R CMD INSTALL and RApache too When executing that program with R 1.15.1 and not RApache everything works well. This problem seems to be specific to the SuSE distribution, as with equivalent rapache and ggplot2 version everything works correctly from localhost on my Mountain Lion Os X Mac Air computer.
Does anyone have a clue how to solve this problem ?