LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 10-28-2015, 07:11 AM   #1
pjgm
LQ Newbie
 
Registered: Jul 2011
Posts: 25

Rep: Reputation: Disabled
Question Installing Firefox Sync Server 1.5


Hi All.

I'm trying to install the firefox sync server on my qnap server but i'm getting some problems... Yes, I'm a Newbie

( https://docs.services.mozilla.com/ho...-sync-1.5.html )

I've already installed "Virtualenv" ... (I Think... )

Code:
[admin@Qnap syncserver]# cd /opt/local/bin
[admin@Qnap bin]# ls
virtualenv* virtualenv-2.6* virtualenv-2.7*
and "make"...

but when I try to build the server I'm getting:

Code:
[admin@Qnap syncserver]# make build
virtualenv --python=`which python2 python | head -n 1` --no-site-packages ./local
/bin/sh: virtualenv: command not found
make: *** [local/COMPLETE] Error 127
Any ideas?

Many Thanks
pjgm
 
Old 10-28-2015, 07:59 AM   #2
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
Why does virtualenv* have an asteriks at the end? What alias of ls do you have. If i recall correctly * means a symlink to something. Check out with ls -l.
Is /opt/local/bin in your $PATH? I'd vote for no so make is not able to find virtualenv.
Can you ./configure with an explisit path to virtualenv?

What distribution your working on?
 
1 members found this post helpful.
Old 10-28-2015, 10:47 AM   #3
pjgm
LQ Newbie
 
Registered: Jul 2011
Posts: 25

Original Poster
Rep: Reputation: Disabled
Hi zhjim,

First of all many thanks for helping me...

I'm working on TS-239 Pro II+ x86 processor with a Embedded Linux ... with QTS 4.2 firmware



Code:
[admin@Qnap ~]# cd /opt/local/bin                                                                                                                                                             
[admin@Qnap bin]# ls                                                                                                                                                                          
virtualenv*     virtualenv-2.6* virtualenv-2.7*
[admin@Qnap bin]# ls -l                                                                                                                                                                       
-rwxr-xr-x    1 admin    administ       282 Oct 26 16:59 virtualenv*
-rwxr-xr-x    1 admin    administ        57 Oct 25 15:58 virtualenv-2.6*
-rwxr-xr-x    1 admin    administ       290 Oct 26 16:59 virtualenv-2.7*
[admin@Qnap bin]#
Quote:
Is /opt/local/bin in your $PATH? I'd vote for no so make is not able to find virtualenv.
Can you ./configure with an explisit path to virtualenv?
sorry but as I said I am a linux noob
How can I do it?

Thanks again!
pjgm
 
Old 10-29-2015, 02:45 AM   #4
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
Okay the ls -l did not show any symlinks. So the * at the end of the filenames puzzle me even more. What happens if you run virutalenv* (outside of make).

Quote:
cd /opt/local/bin
./virtualenv*
To add to a variable

Quote:
PATH="$PATH:/opt/local/bin"
The : is the path seperator and needs to be included. check out your PATH var before and after with echo $PATH

configure should have an --help option. Try ./configure --help in the source code path.
 
1 members found this post helpful.
Old 10-29-2015, 03:35 AM   #5
pjgm
LQ Newbie
 
Registered: Jul 2011
Posts: 25

Original Poster
Rep: Reputation: Disabled
Hi zhjim,

Here we go...

Code:
[admin@Qnap bin]# ./virtualenv*
There must be only one argument: DEST_DIR (you gave ./virtualenv-2.6 ./virtualenv-2.7)
Usage: virtualenv [OPTIONS] DEST_DIR
Options:
--version show program's version number and exit
-h, --help show this help message and exit
-v, --verbose Increase verbosity.
-q, --quiet Decrease verbosity.
-p PYTHON_EXE, --python=PYTHON_EXE
The Python interpreter to use, e.g.,
--python=python2.5 will use the python2.5 interpreter
to create the new environment. The default is the
interpreter that virtualenv was installed with
(/opt/bin/python2.7)
--clear Clear out the non-root install and start from scratch.
--no-site-packages DEPRECATED. Retained only for backward compatibility.
Not having access to global site-packages is now the
default behavior.
--system-site-packages
Give the virtual environment access to the global
site-packages.
--always-copy Always copy files rather than symlinking.
--unzip-setuptools Unzip Setuptools when installing it.
--relocatable Make an EXISTING virtualenv environment relocatable.
This fixes up scripts and makes all .pth files
relative.
--no-setuptools Do not install setuptools (or pip) in the new
virtualenv.
--no-pip Do not install pip in the new virtualenv.
--no-wheel Do not install wheel in the new virtualenv.
--extra-search-dir=DIR
Directory to look for setuptools/pip distributions in.
This option can be used multiple times.
--never-download DEPRECATED. Retained only for backward compatibility.
This option has no effect. Virtualenv never downloads
pip or setuptools.
--prompt=PROMPT Provides an alternative prompt prefix for this
environment.
--setuptools DEPRECATED. Retained only for backward compatibility.
This option has no effect.
--distribute DEPRECATED. Retained only for backward compatibility.
This option has no effect.
and...

Code:
[admin@Qnap bin]# echo $PATH
/bin:/sbin:/usr/bin:/usr/sbin:/usr/bin/X11:/usr/local/sbin:/usr/local/bin:/usr/local/jre/bin:/opt/bin:/opt/sbin:/Apps/bin:/Apps/sbin
[admin@Qnap bin]#
and...

Code:
[admin@Qnap bin]# ./configure --help
-sh: ./configure: No such file or directory
cheers
pjgm
 
Old 10-29-2015, 05:18 AM   #6
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
Okay virtualenv is working. Now we need the make to get it.
I'm not that strong when it comes to make but lets try to get virtualenv inside your $PATH. As you have /opt/bin already in there lets create a symlink.

Quote:
ln -s /opt/local/virtualenv* /opt/bin
then do make again.
 
Old 10-29-2015, 07:24 AM   #7
pjgm
LQ Newbie
 
Registered: Jul 2011
Posts: 25

Original Poster
Rep: Reputation: Disabled
no luck

Code:
[admin@Qnap syncserver]# ln -s /opt/local/virtualenv* /opt/bin
[admin@Qnap syncserver]# make build
virtualenv --python=`which python2 python | head -n 1` --no-site-packages ./local
/bin/sh: virtualenv: command not found
make: *** [local/COMPLETE] Error 127
EDIT: make is searching on /local/bin/sh right?

Why are we pointing to /opt/local/virtualenv* ?

Last edited by pjgm; 10-29-2015 at 09:50 AM.
 
Old 10-29-2015, 10:12 AM   #8
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
Actually I have no clue where make is searching. the line
Quote:
/bin/sh: virtualenv: command not found
tells that the programm /bin/sh tries to run virtualenv. Which it does not find.

I spotted an error on my side. The ln command should not have worked propably. Instead of /opt/bin it should have bin /opt/bin/virtualenv. So try this please

Quote:
ln -s /opt/local/virtualenv* /opt/bin/virtualenv
After that check with ls -l that the symlink got created.

You could also symlink virtualenv* to the source code directory or /bin or /sbin. I just don't know where make is searching for it. Might want to check the makefile with grep. Something like this

Quote:
grep virtualenv -A 5 -B 5./Makefile
 
Old 10-29-2015, 10:33 AM   #9
pjgm
LQ Newbie
 
Registered: Jul 2011
Posts: 25

Original Poster
Rep: Reputation: Disabled
ls -l

Code:
lrwxrwxrwx 1 admin administ 22 Oct 29 15:25 virtualenv -> /opt/local/virtualenv*@
and...

Code:
[admin@Qnap bin]# grep virtualenv -A 5 -B 5./Makefile
grep: invalid context length argument
 
Old 10-29-2015, 02:49 PM   #10
pjgm
LQ Newbie
 
Registered: Jul 2011
Posts: 25

Original Poster
Rep: Reputation: Disabled
Here you have the Make file content...

Code:
SYSTEMPYTHON = `which python2 python | head -n 1`
VIRTUALENV = virtualenv --python=$(SYSTEMPYTHON)
ENV = ./local
TOOLS := $(addprefix $(ENV)/bin/,flake8 nosetests)

# Hackety-hack around OSX system python bustage.
# The need for this should go away with a future osx/xcode update.
ARCHFLAGS = -Wno-error=unused-command-line-argument-hard-error-in-future

# Hackety-hack around errors duing compile of ultramemcached.
CFLAGS = "-Wno-error -Wno-error=format-security"

INSTALL = CFLAGS=$(CFLAGS) ARCHFLAGS=$(ARCHFLAGS) $(ENV)/bin/pip install


.PHONY: all
all: build

.PHONY: build
build: | $(ENV)/COMPLETE
$(ENV)/COMPLETE: requirements.txt
	$(VIRTUALENV) --no-site-packages $(ENV)
	$(INSTALL) -r requirements.txt
	$(ENV)/bin/python ./setup.py develop
	touch $(ENV)/COMPLETE

.PHONY: test
test: | $(TOOLS)
	$(ENV)/bin/flake8 ./syncserver
	$(ENV)/bin/nosetests -s syncstorage.tests
	# Tokenserver tests currently broken due to incorrect file paths
	# $(ENV)/bin/nosetests -s tokenserver.tests
	
	# Test against a running server
	$(ENV)/bin/gunicorn --paste syncserver/tests.ini 2> /dev/null & SERVER_PID=$$!; \
	sleep 2; \
	$(ENV)/bin/python -m syncstorage.tests.functional.test_storage \
		--use-token-server http://localhost:5000/token/1.0/sync/1.5; \
	kill $$SERVER_PID

$(TOOLS): | $(ENV)/COMPLETE
	$(INSTALL) nose flake8

.PHONY: serve
serve: | $(ENV)/COMPLETE
	$(ENV)/bin/gunicorn --paste ./syncserver.ini

.PHONY: clean
clean:
	rm -rf $(ENV)
one more thing...

This was the steps to install virtualenv:

Code:
[admin@Qnap syncserver]# easy_install-2.7 --site-dirs /opt/local/lib/python2.7/site-packages virtualenv
Searching for virtualenv
Reading http://pypi.python.org/simple/virtualenv/                                                                                                                                             
Best match: virtualenv 13.1.2
Downloading https://pypi.python.org/packages/source/v/virtualenv/virtualenv-13.1.2.tar.gz#md5=b989598f068d64b32dead530eb25589a                                                               
Processing virtualenv-13.1.2.tar.gz
Running virtualenv-13.1.2/setup.py -q bdist_egg --dist-dir /tmp/easy_install-A6i_J0/virtualenv-13.1.2/egg-dist-tmp-hxSADJ
warning: no previously-included files matching '*' found under directory 'docs/_templates'
warning: no previously-included files matching '*' found under directory 'docs/_build'
Adding virtualenv 13.1.2 to easy-install.pth file
Installing virtualenv script to /opt/local/bin
Installing virtualenv-2.7 script to /opt/local/bin
Installed /share/MD0_DATA/.qpkg/Optware/local/lib/python2.7/site-packages/virtualenv-13.1.2-py2.7.egg
Processing dependencies for virtualenv
Finished processing dependencies for virtualenv
Note that..

Code:
Installed /share/MD0_DATA/.qpkg/Optware/local/lib/python2.7/site-packages/virtualenv-13.1.2-py2.7.egg
So... now I've got good news and bad news...

Code:
[/share/Web/syncserver] # make build
virtualenv --python=`which python2 python | head -n 1` --no-site-packages ./local
Traceback (most recent call last):
  File "/opt/bin/virtualenv", line 14, in <module>
    import shutil
  File "/share/MD0_DATA/.qpkg/Optware/local/lib/python2.7/site-packages/virtualenv-13.1.2-py2.7.egg/shutil.py", line 12, in <module>
    import collections
  File "/share/MD0_DATA/.qpkg/Optware/local/lib/python2.7/site-packages/virtualenv-13.1.2-py2.7.egg/collections.py", line 8, in <module>
    from _collections import deque, defaultdict
  File "/share/MD0_DATA/.qpkg/Optware/local/lib/python2.7/site-packages/virtualenv-13.1.2-py2.7.egg/_collections.py", line 13, in <module>
    from .compat import threading, itertools_filterfalse, string_types
ValueError: Attempted relative import in non-package
make: *** [local/COMPLETE] Error 1
Symlink problem solved but now I've got this error above...

I've picked several python modules from git to get here... but I think:

- I need Python-dev (and I don't know how to install it)
- Maybe collections.py it's not the right one (version)...

any ideas?

Last edited by pjgm; 10-29-2015 at 08:46 PM. Reason: new data...
 
Old 10-30-2015, 03:21 AM   #11
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
Getting closer. I finally read up the install page you linked in you #1 post. You definitely need phyton-dev as its listed as prerequisites. Also the virtualenv link goes to version 13.*. You have 2.7... Thats a wide gap and might be a problem as well.

I can't find anything specific about the OS your using, so i can't help you with installing. But most distributions have some kind of package manager. Lets see if we can find out the distribution. Please provide the output from the following

Quote:
uname -a
find /etc -iname '*version*'
 
Old 10-30-2015, 03:43 AM   #12
pjgm
LQ Newbie
 
Registered: Jul 2011
Posts: 25

Original Poster
Rep: Reputation: Disabled
Hi zhjim,

Code:
[admin@Qnap ~]# uname -a
Linux Qnap 3.4.6 #1 SMP Fri Oct 23 09:38:52 CST 2015 i686 unknown
 
Old 11-03-2015, 05:16 AM   #13
pjgm
LQ Newbie
 
Registered: Jul 2011
Posts: 25

Original Poster
Rep: Reputation: Disabled
HI zhjim,

I really want to thank you for your help...

...Stphane Gurithault (QoolBox) did it:

thank you both!

http://www.forum-nas.fr/viewtopic.php?f=21&t=2677

Great work!

[Solved]
 
Old 11-09-2015, 03:32 AM   #14
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
Glad you got it solved.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Firefox Sync safety wagscat123 Linux - Software 6 02-17-2015 11:14 PM
LXer: Firefox Set to Get a New Look, Better Sync LXer Syndicated Linux News 0 02-03-2014 06:12 PM
Firefox Sync, How secure is it? Zyblin Linux - General 8 12-14-2013 06:16 AM
Firefox ESR on 13.37 won't sync kfritz Slackware 1 06-30-2013 09:50 AM
Firefox 1.4: server error on google after installing new engine Simon Bridge Linux - Networking 1 05-29-2005 02:47 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 12:50 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration