Giter VIP home page Giter VIP logo

Comments (11)

artemklevtsov avatar artemklevtsov commented on August 10, 2024 3

I found solution: add -D__USE_MISC flag to the CFLAGS.

from httpuv.

jcheng5 avatar jcheng5 commented on August 10, 2024 3

@jeroen Actually it looks like most of the Linux distributions have libuv packages now, at least 0.10 if not 1.x. Would it be better to start linking to the distro-provided versions? (For Mac and Windows I would continue bundling)

from httpuv.

jcheng5 avatar jcheng5 commented on August 10, 2024 1

I couldn't get it to build off master just now. This seems to be because Alpine uses musl.

However, the rstudio/[email protected] branch does work. You have to install these dependencies first:

apk add automake libtool m4 autoconf linux-headers

(I am way overdue on finishing and merging that branch, sorry.)

from httpuv.

alex88 avatar alex88 commented on August 10, 2024

Hi @artemklevtsov I think I've the same issue

* installing *source* package ‘httpuv’ ...
** package ‘httpuv’ successfully unpacked and MD5 sums checked
** libs
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c RcppExports.cpp -o RcppExports.o
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c filedatasource-unix.cpp -o filedatasource-unix.o
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c filedatasource-win.cpp -o filedatasource-win.o
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c http.cpp -o http.o
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c httpuv.cpp -o httpuv.o
gcc -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer  -c md5.c -o md5.o
gcc -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer  -c set_invalid_parameter.c -o set_invalid_parameter.o
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c uvutil.cpp -o uvutil.o
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c websockets-base.cpp -o websockets-base.o
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c websockets-hixie76.cpp -o websockets-hixie76.o
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c websockets-hybi03.cpp -o websockets-hybi03.o
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c websockets-ietf.cpp -o websockets-ietf.o
g++ -I/usr/include/R -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -Os -fomit-frame-pointer -I"/usr/lib/R/library/Rcpp/include"   -fpic  -Os -fomit-frame-pointer -D__MUSL__  -c websockets.cpp -o websockets.o
websockets.cpp: In member function 'bool WebSocketConnection::accept(const RequestHeaders&, const char*, size_t)':
websockets.cpp:217:8: warning: 'template<class> class std::auto_ptr' is deprecated [-Wdeprecated-declarations]
   std::auto_ptr<WebSocketProto_IETF> ietf(new WebSocketProto_IETF());
        ^~~~~~~~
In file included from /usr/include/c++/6.2.1/bits/locale_conv.h:41:0,
                 from /usr/include/c++/6.2.1/locale:43,
                 from /usr/include/c++/6.2.1/iomanip:43,
                 from websockets.cpp:6:
/usr/include/c++/6.2.1/bits/unique_ptr.h:49:28: note: declared here
   template<typename> class auto_ptr;
                            ^~~~~~~~
websockets.cpp:223:8: warning: 'template<class> class std::auto_ptr' is deprecated [-Wdeprecated-declarations]
   std::auto_ptr<WebSocketProto_HyBi03> hybi03(new WebSocketProto_HyBi03());
        ^~~~~~~~
In file included from /usr/include/c++/6.2.1/bits/locale_conv.h:41:0,
                 from /usr/include/c++/6.2.1/locale:43,
                 from /usr/include/c++/6.2.1/iomanip:43,
                 from websockets.cpp:6:
/usr/include/c++/6.2.1/bits/unique_ptr.h:49:28: note: declared here
   template<typename> class auto_ptr;
                            ^~~~~~~~
make --directory=libuv \
	CC="gcc" CFLAGS="-Os -fomit-frame-pointer  -fpic" AR="ar" RANLIB="ranlib" \
    HAVE_DTRACE=0 \
	libuv.a
make[1]: Entering directory '/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv'
mkdir -p src/unix
touch src/unix/.buildstamp
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/async.c -o src/unix/async.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/core.c -o src/unix/core.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/dl.c -o src/unix/dl.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/error.c -o src/unix/error.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/fs.c -o src/unix/fs.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/getaddrinfo.c -o src/unix/getaddrinfo.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/loop.c -o src/unix/loop.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/loop-watcher.c -o src/unix/loop-watcher.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/pipe.c -o src/unix/pipe.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/poll.c -o src/unix/poll.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/process.c -o src/unix/process.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/signal.c -o src/unix/signal.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/stream.c -o src/unix/stream.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/tcp.c -o src/unix/tcp.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/thread.c -o src/unix/thread.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/threadpool.c -o src/unix/threadpool.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/timer.c -o src/unix/timer.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/tty.c -o src/unix/tty.o
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/unix/udp.c -o src/unix/udp.o
mkdir -p src
touch src/.buildstamp
gcc --std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter -D_GNU_SOURCE -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/include/uv-private -I/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fomit-frame-pointer  -fpic -c src/fs-poll.c -o src/fs-poll.o
src/fs-poll.c: In function 'statbuf_eq':
src/fs-poll.c:205:8: error: 'uv_statbuf_t {aka const struct stat}' has no member named 'st_ctimensec'; did you mean 'st_ctim'?
   if (a->st_ctimensec != b->st_ctimensec) return 0;
        ^~
src/fs-poll.c:205:27: error: 'uv_statbuf_t {aka const struct stat}' has no member named 'st_ctimensec'; did you mean 'st_ctim'?
   if (a->st_ctimensec != b->st_ctimensec) return 0;
                           ^~
src/fs-poll.c:206:8: error: 'uv_statbuf_t {aka const struct stat}' has no member named 'st_mtimensec'; did you mean 'st_mtim'?
   if (a->st_mtimensec != b->st_mtimensec) return 0;
        ^~
src/fs-poll.c:206:27: error: 'uv_statbuf_t {aka const struct stat}' has no member named 'st_mtimensec'; did you mean 'st_mtim'?
   if (a->st_mtimensec != b->st_mtimensec) return 0;
                           ^~
make[1]: *** [/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv/config-unix.mk:192: src/fs-poll.o] Error 1
make[1]: Leaving directory '/tmp/RtmpepbcnM/R.INSTALL9fe113be93d/httpuv/src/libuv'
make: *** [Makevars:27: libuv.a] Error 2
ERROR: compilation failed for package ‘httpuv’
* removing ‘/usr/lib/R/library/httpuv’

however I don't see that in CFLAGS, how can I force it?

from httpuv.

artemklevtsov avatar artemklevtsov commented on August 10, 2024

Edit ~/.R/Makefile or Makevars in the package sources.

from httpuv.

alex88 avatar alex88 commented on August 10, 2024

Ok gotcha, thanks

from httpuv.

jeroen avatar jeroen commented on August 10, 2024

Whats the output of cmd uname in your distribution? Then we can add this to the Makevars OS tweaks.

from httpuv.

artemklevtsov avatar artemklevtsov commented on August 10, 2024

@jeroen Linux.

from httpuv.

jeroen avatar jeroen commented on August 10, 2024

Is this still broken in master?

devtools::install_github("rstudio/httpuv")

from httpuv.

commandline-be avatar commandline-be commented on August 10, 2024

this also fails on a Alpine VPS/VM, automake 1.16 installed but there appears a hard coded dependency for automake-1.15

from httpuv.

wch avatar wch commented on August 10, 2024

@commandline-be Can you try installing the development version from github? If it fails, please include the full output, as well as the output of devtools::session_info().

devtools::install_github('rstudio/httpuv')

from httpuv.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.