Southclaws/pawn-requests

Docker on 32bit system

b4ll opened this issue · 2 comments

b4ll commented

Hi, I try to run pawn-requests plugin on my server, but it fails

[21.10.2019 10:20:47]  Loading plugin: requests.so
[21.10.2019 10:20:47]   Failed (/usr/lib/i386-linux-gnu/libstdc++.so.6: version `CXXABI_1.3.9' not found (required by plugins/requests.so))

So I try to compile the plugin on my virtual machine (debian 8, 32bit). The problem is docker, can it be installed on 32bit system? I've done some research and found this, although after sudo bash build-image.sh command, I get errors

Package docker.io is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'docker.io' has no installation candidate
build-image.sh: linia 16: debootstrap: not found
build-image.sh: linia 19: /var/chroot/jessie/etc/apt/sources.list: not found
chroot: cannot change directory root na /var/chroot/jessie: not found

tar: /var/chroot/jessie: Nie można open: not found
tar: Error is not recoverable: exiting now

Is the docker a must-have or there is other option to build the plugin without docker?

Docker isn't a requirement at all, it's just a tool to make it simpler. It wouldn't solve your problem anyway since the point of the Docker build environment is to provide an isolated environment to build a binary that targets most operating systems. However, it seems your system is missing newer libraries so the Docker build wouldn't work as it would use the latest dependencies.

Side note: docker.io is an ancient version, I don't know why no one has removed those packages or why Docker felt the need to rename their packages (twice). But anyway, if you want to use Docker you should follow the instructions for your distro here: https://docs.docker.com/install/linux/docker-ce/ubuntu/#install-docker-engine---community

To build yourself, you have to install a ton of extra stuff first (the stuff listed in the Dockerfile) and then use CMake to build. This is why I use Docker to build distributions. And also why I've rewritten the plugin in Rust so I don't have to deal with all of this any more!

b4ll commented

I tried to compile one by one from the Dockerfile, but got stuck at cpprestsdk. Compilation throws out errors

/usr/local/include/boost/function/function_template.hpp:158:11: error: expression cannot be used as a function
           BOOST_FUNCTION_RETURN((*f)(BOOST_FUNCTION_ARGS));
           ^
src/CMakeFiles/cpprest.dir/build.make:322: recipe for target 'src/CMakeFiles/cpprest.dir/websockets/client/ws_client_wspp.cpp.o' failed
make[2]: *** [src/CMakeFiles/cpprest.dir/websockets/client/ws_client_wspp.cpp.o] error 1
CMakeFiles/Makefile2:93: recipe for target 'src/CMakeFiles/cpprest.dir/all' failed
make[1]: *** [src/CMakeFiles/cpprest.dir/all] error 2
Makefile:140: recipe for target 'all' failed
make: *** [all] error 2

There are full logs.

console-log.txt
CMakeOutput.log

Is this related to boost or websocket? I have version 1.69 of boost. I run dpkg-query -s libwebsocketpp-dev | grep Version command and it shows a 0.3.0-2 version.