Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation and installation issues #12

Open
gilesc opened this issue Jan 15, 2015 · 2 comments
Open

Compilation and installation issues #12

gilesc opened this issue Jan 15, 2015 · 2 comments

Comments

@gilesc
Copy link

gilesc commented Jan 15, 2015

I'm on Arch Linux, whose default Python is Python 3. To compile, I had to edit "prepare.sh" in a few places to refer to "pip2" and "python2" instead of "pip" and "python" respectively. I think this change would also work on other platforms as to my knowledge these are also installed as aliases for python even on platforms with a default of Python 2. Or some line could be added like:
PYTHON=$(which python2 || which python).

Secondly, I think the compilation process should support (and probably default) to not requiring root. This is a requirement on many distros in order to create packages, as it is generally known to be a bad idea to compile or run random code from the internet as root, and generally autobuilders that build .deb or .pkg or whatever type of package do not run as root. I think the only places that currently require root are the lines containing "python setup.py install" and "pip install". This could be fixed just by adding the "--user" flag to those lines. Or even better, the prepare.sh can detect if it is being run as root or not ("whoami" or $USER) and add the --user flag accordingly.

Finally, it would be nice if the installation process would default to using the platform's libraries when they are already installed (protobuf, gtest, etc). This is also necessary to create packages unless the package maintainer wants to build static binaries. This is not such a big problem, but dynamic linking is the custom and saves a little space.

@gilesc
Copy link
Author

gilesc commented Jan 15, 2015

Also, a "make PREFIX=/my/install/prefix install" command would be nice.

I think it would be as simple as:

for bin in $(find src/ -executable | grep rs_ | grep -v test); do cp $bin $PREFIX/bin; done

but I don't know if that's everything that needs to be installed or not.

@pimentel
Copy link

+1 to all of the comments stated above

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants