Skip to content
Prev 369 / 919 Next

httpuv not installing on fedora 19

just to close this thread. tom callaway kindly spent a lot of time on my
problem and figured out the following: ( it's easier for me to quote john ).

"QUOTE"

So, I looked at this again when I'm not sitting in an airport on my phone,
and the error seems to be that a "[1]" is being passed to the g++
commandline.

I tested running a install.packages("httpuv") on my end, and it did not
have this failure when running with the default .Rprofile setup. The output
looks like this for me (with stock profile):

g++ -m64 -shared -L/usr/lib64/R/lib -Wl,-z,relro -o httpuv.so RcppExports.o
filedatasource-unix.o filedatasource-win.o http.o httpuv.o md5.o
set_invalid_parameter.o uvutil.o websockets-base.o websockets-hixie76.o
websockets-hybi03.o websockets-ietf.o websockets.o ./libuv/libuv.a
./http-parser/http_parser.o ./sha1/sha1.o ./base64/base64.o
-L/usr/lib64/R/lib -lR

Now, when I look at how httpuv generates that compiler invocation, I see in
httpuv/src/Makevars this line:

PKG_LIBS = `$(R_HOME)/bin/Rscript -e "Rcpp:::LdFlags()"` ./libuv/libuv.a
./http-parser/http_parser.o ./sha1/sha1.o ./base64/base64.o $(FRAMEWORK)

PKG_LIBS is where your "[1]" is being picked up, along with all the LC_*
environment variables. This is not correct. You should be able to confirm
this by running:

Rscript -e "Rcpp:::LdFlags()"

On my default profile, this returns nothing. I'm betting for you, it will
return:

[1]
"LC_CTYPE=C;LC_NUMERIC=C;LC_TIME=C;LC_COLLATE=C;LC_MONETARY=C;LC_MESSAGES=en_US.utf8;LC_PAPER=en_US.utf8;LC_NAME=C;LC_ADDRESS=C;LC_TELEPHONE=C;LC_MEASUREMENT=en_US.utf8;LC_IDENTIFICATION=C"

END "QUOTE":

Tom was correct in that it did return that and he recommended fixing it by
changing my  dotRprofile command from Sys.setlocale(locale = "C") to
Sys.setenv(LANG  = "C").

I did that and then httpuv installed groovily without any glitches. The
great thing is that installing httpuv ended up solving a different problem
that I was having for about 3 days so John was a tremendous help as he
always is. The morale of this story is "DO NOT include the Sys.setlocale
command in your dotRprofile file". Thanks again to Tom.
On Tue, Apr 14, 2015 at 8:30 AM, Mark Leeds <markleeds2 at gmail.com> wrote: