LINUX SUPPORT IS HERE

Talk about general things concerning Forged Alliance Forever.

Moderators: FtXCommando, Ze Dogfather

Re: LINUX SUPPORT IS HERE

Postby tatsu » 18 Aug 2017, 19:16

Herby wrote:First, thanks to tatsu for his nice work. I had a close look at the script you created and at the video. It looks pretty nice but I didn't dare to use it as I was afraid to mess up my install

Hey man!

Thank YOU !

I'm doubfull that could be possible as the wine universe and the linux universe are very intentionally separate and what me and my script (which doesn't work right now, use this: http://wiki.faforever.com/index.php?title=Setting_Up_FAF_Linux#Debian.2FUbuntu instead) are doing is running a native linux FAF .

obviously the Forged Alliance part can't be native so that stays in wine/playonlinux but that doesn't cause native FAF an issue at all.

Why would one run FAF native? well for dat sweet linux start time and snappiness. the app launch and every other aspect of FAF native is very much faster and more responsive.

you can have both solutions installed and plugging into the same FA at a time so if you feel up to it you're free to do so without any risk to your current install.

Glad you got it working for you! woop woop!
User avatar
tatsu
Supreme Commander
 
Posts: 1553
Joined: 02 Jul 2012, 21:26
Has liked: 1952 times
Been liked: 171 times
FAF User Name: tatsu

Re: LINUX SUPPORT IS HERE

Postby Herby » 19 Aug 2017, 09:50

Hi,

After yesterday's update, my FAF client under playonlinux doesn't start anymore :(...
So, following your advices, I tried to install the native linux FAF but didn't go very far. "python3-semantic-version" & "python3-virtualenv" cannot be installed. It looks that those packages are not available any more. I installed "python3.4-venv" and "python-virtualenv" instead.
For info, virtualenv --version gives me 1.11.4. I'm on Kubuntu 14.04/3.13.0-128-generic
Then:
Code: Select all
herby@PC:/media/DATA/jeux/fafclient$ virtualenv ./faf-client-venv --system-site-packages
New python executable in ./faf-client-venv/bin/python
Installing setuptools, pip...done.
herby@PC:/media/DATA/jeux/fafclient$ source ./venv/bin/activate
(faf-client-venv)herby@PC:/media/DATA/jeux/fafclient$ pip install ipaddress lupa trueskill marshmallow-jsonapi pyqt5
Downloading/unpacking ipaddress
  Downloading ipaddress-1.0.18-py2-none-any.whl
Downloading/unpacking lupa
  Downloading lupa-1.4.tar.gz (217kB): 217kB downloaded
  Running setup.py (path:/tmp/pip_build_herby/lupa/setup.py) egg_info for package lupa
    No local build of LuaJIT2 found in lupa directory
    Checking for installed luajit library using pkg-config
    Did not find luajit using pkg-config: pkg-config cannot find an installed luajit
    Checking for installed lua5.2 library using pkg-config
    Did not find lua5.2 using pkg-config: pkg-config cannot find an installed lua5.2
    Checking for installed lua-5.2 library using pkg-config
    Did not find lua-5.2 using pkg-config: pkg-config cannot find an installed lua-5.2
    Checking for installed lua library using pkg-config
    Did not find lua using pkg-config: pkg-config cannot find an installed lua
    Checking for installed lua5.1 library using pkg-config
    pkg-config found lua5.1 version 5.1.5
   
    building without Cython
   
Downloading/unpacking trueskill
  Downloading trueskill-0.4.4.tar.gz
  Running setup.py (path:/tmp/pip_build_herby/trueskill/setup.py) egg_info for package trueskill
   
Downloading/unpacking marshmallow-jsonapi
  Downloading marshmallow-jsonapi-0.15.0.tar.gz
  Running setup.py (path:/tmp/pip_build_herby/marshmallow-jsonapi/setup.py) egg_info for package marshmallow-jsonapi
   
    warning: no previously-included files matching '*.pyc' found under directory 'docs'
    warning: no previously-included files matching '*.pyo' found under directory 'docs'
    warning: no previously-included files matching '*.pyc' found under directory 'tests'
    warning: no previously-included files matching '*.pyo' found under directory 'tests'
    warning: no previously-included files matching '*.pyc' found under directory 'examples'
    warning: no previously-included files matching '*.pyo' found under directory 'examples'
    no previously-included directories found matching 'docs/_build'
Downloading/unpacking pyqt5
  Could not find any downloads that satisfy the requirement pyqt5
Cleaning up...
No distributions at all found for pyqt5
Storing debug log for failure in /home/herby/.pip/pip.log
(faf-client-venv)herby@PC:/media/DATA/jeux/fafclient$ wget https://github.com/FAForever/uid/releases/download/v3.0.0/faf-uid -O ./faf-client/lib/faf-uid
./faf-client/lib/faf-uid: Aucun fichier ou dossier de ce type
(faf-client-venv)herby@PC:/media/DATA/jeux/fafclient$ sudo wget https://github.com/FAForever/uid/releases/download/v4.0.5/faf-uid -O /usr/bin/faf-uid
[sudo] password for herby:
--2017-08-19 13:04:52--  https://github.com/FAForever/uid/releases/download/v4.0.5/faf-uid
Résolution de github.com (github.com)… 192.30.255.112, 192.30.255.113
Connexion à github.com (github.com)|192.30.255.112|:443… connecté.
requête HTTP transmise, en attente de la réponse… 302 Found
Emplacement : https://github-production-release-asset-2e65be.s3.amazonaws.com/56635802/ef53dbac-6167-11e7-8786-9399c17721e5?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20170819%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20170819T060453Z&X-Amz-Expires=300&X-Amz-Signature=099eca314ad1eb5cf12775715593d9a3328cf38cbd384ff07decf6382f1774d6&X-Amz-SignedHeaders=host&actor_id=0&response-content-disposition=attachment%3B%20filename%3Dfaf-uid&response-content-type=application%2Foctet-stream [suivant]
--2017-08-19 13:04:53--  https://github-production-release-asset-2e65be.s3.amazonaws.com/56635802/ef53dbac-6167-11e7-8786-9399c17721e5?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20170819%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20170819T060453Z&X-Amz-Expires=300&X-Amz-Signature=099eca314ad1eb5cf12775715593d9a3328cf38cbd384ff07decf6382f1774d6&X-Amz-SignedHeaders=host&actor_id=0&response-content-disposition=attachment%3B%20filename%3Dfaf-uid&response-content-type=application%2Foctet-stream
Résolution de github-production-release-asset-2e65be.s3.amazonaws.com (github-production-release-asset-2e65be.s3.amazonaws.com)… 52.216.228.128
Connexion à github-production-release-asset-2e65be.s3.amazonaws.com (github-production-release-asset-2e65be.s3.amazonaws.com)|52.216.228.128|:443… connecté.
requête HTTP transmise, en attente de la réponse… 200 OK
Taille : 3099576 (3,0M) [application/octet-stream]
Enregistre : «/usr/bin/faf-uid»

100%[=======================================================================================================================>] 3 099 576    445KB/s   ds 7,2s   

2017-08-19 13:05:02 (420 KB/s) - «/usr/bin/faf-uid» enregistré [3099576/3099576]

(faf-client-venv)herby@PC:/media/DATA/jeux/fafclient$ sudo chmod +x /usr/bin/faf-uid
(faf-client-venv)herby@PC:/media/DATA/jeux/fafclient$ git clone https://github.com/FAForever/client.git
Clonage dans 'client'...
remote: Counting objects: 15667, done.
remote: Total 15667 (delta 0), reused 0 (delta 0), pack-reused 15667
Réception d'objets: 100% (15667/15667), 12.99 MiB | 1.67 MiB/s, done.
Résolution des deltas: 100% (9695/9695), done.
Vérification de la connectivité... fait.
(faf-client-venv)herby@PC:/media/DATA/jeux/fafclient$ python ./client/src
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 162, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/media/DATA/jeux/fafclient/client/src/__main__.py", line 33, in <module>
    from PyQt5 import QtWidgets, uic
ImportError: No module named PyQt5

So it looks like I reach the same problem than here. I've installed python3-pyqt5 but this doesn't help and I'm stuck there. Any idea on how to solve this?
Herby
Crusader
 
Posts: 16
Joined: 18 Aug 2017, 13:36
Has liked: 0 time
Been liked: 5 times
FAF User Name: Herby

Re: LINUX SUPPORT IS HERE

Postby tatsu » 19 Aug 2017, 21:45

Herby wrote:Hi,

So it looks like I reach the same problem than here. I've installed python3-pyqt5 but this doesn't help and I'm stuck there. Any idea on how to solve this?

Oh salut ! un compatriote français!

damned straight you have!

I needed confirmation of this issue :

try uninstalling python3-pyqt5
Code: Select all
sudo apt remove python3-pyqt5

then run this :
http://download.qt.io/official_releases ... online.run

it's a .run file. a better installer format for linux that's cross distro. just make it executable by right clicking on it and going into properties and ticking "Allow executing file as program" under permissions

then double click it

and skip the account step and at the software to install part add a couple like qtwebkit and qtwebengine.

after that and a reboot runnig the same thing
Code: Select all
cd fafclient
source ./venv/bin/activate
python ./client/src
should work. if it does not add python3-pyqt5 back in.
User avatar
tatsu
Supreme Commander
 
Posts: 1553
Joined: 02 Jul 2012, 21:26
Has liked: 1952 times
Been liked: 171 times
FAF User Name: tatsu

Re: LINUX SUPPORT IS HERE

Postby Herby » 19 Aug 2017, 22:35

Salut ;)

Thanks you for your help.
Unfortunately, it didn't work. I still have the same error:
Code: Select all
herby@PC:/media/DATA/jeux/fafclient$ source ./venv/bin/activate
(venv)herby@PC:/media/DATA/jeux/fafclient$ python ./client/src
Traceback (most recent call last):
  File "/usr/lib/python3.4/runpy.py", line 170, in _run_module_as_main
    "__main__", mod_spec)
  File "/usr/lib/python3.4/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "./client/src/__main__.py", line 33, in <module>
    from PyQt5 import QtWidgets, uic
ImportError: cannot import name 'QtWidgets'

After checking, I can say that python3-pyqt5 didn't come back.
I've tried to search for a solution on my side and went through this post: https://askubuntu.com/questions/662595/ ... untu-14-04
This problem may be linked to my version of Ubuntu but not sure.
BTW, is it normal that the Qt installer installs everything in the home directory by default (~/Qt)?
Herby
Crusader
 
Posts: 16
Joined: 18 Aug 2017, 13:36
Has liked: 0 time
Been liked: 5 times
FAF User Name: Herby

Re: LINUX SUPPORT IS HERE

Postby Herby » 20 Aug 2017, 11:11

I kept searching for a solution and I tried to install the client on Ubuntu 17.04 in vBox just to end up with a similar error when launching the client:
Code: Select all
(venv) ubuntu1704@1704:~/fafclient$ python ./client/src
Traceback (most recent call last):
  File "/usr/lib/python3.5/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/usr/lib/python3.5/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "./client/src/__main__.py", line 42, in <module>
    import util
  File "./client/src/util/__init__.py", line 15, in <module>
    from config import Settings
  File "./client/src/config/__init__.py", line 5, in <module>
    import trueskill
ImportError: No module named 'trueskill'

BTW, I noticed a few things that might help:
In kubuntu14.04, I don't have the file /usr/lib/python3/dist-packages/virtualenv.py but I can find it in /usr/lib/python2.7/dist-packages/
As a result I've replaced this line from the tutorial
Code: Select all
python3 /usr/lib/python3/dist-packages/virtualenv.py -p python3 --system-site-packages venv
by this:
Code: Select all
virtualenv -p `which python3` venv
However, I don't know if those 2 commands are equivalent.

I've also tried to compile sip4.19.3 & PyQt5 directly in the virtual environment but end up with the same error as in my previous post.
Herby
Crusader
 
Posts: 16
Joined: 18 Aug 2017, 13:36
Has liked: 0 time
Been liked: 5 times
FAF User Name: Herby

Re: LINUX SUPPORT IS HERE

Postby tatsu » 20 Aug 2017, 13:39

Herby wrote:BTW, is it normal that the Qt installer installs everything in the home directory by default (~/Qt)?


yeah seems like it wouldn't affect your system but actually that's not the only place it puts files so yeah normal.

you can try making sim-links to one and then the other :
Code: Select all
alias python=python3
or
Code: Select all
alias python=python2
and try with each to see if there's a difference.

I'm tempted to teamview into your PC and try my hand at the issue. if you're willing PM me on this forum.
User avatar
tatsu
Supreme Commander
 
Posts: 1553
Joined: 02 Jul 2012, 21:26
Has liked: 1952 times
Been liked: 171 times
FAF User Name: tatsu

Re: LINUX SUPPORT IS HERE

Postby Herby » 20 Aug 2017, 14:43

In the meantime, I've installed the 2 things I wasn't able to install by downloading the deb ("python3-semantic-version" & "python3-virtualenv"). So I now have /usr/lib/python3/dist-packages/virtualenv.py. I've recreated the virtual environment with the command line from the tutorial (python3 /usr/lib/python3/dist-packages/virtualenv.py -p python3 --system-site-packages venv) and it worked. But still had the same issue with PyQt5.
You're welcome to jump in through teamviewer, I send you a PM just after this...
Herby
Crusader
 
Posts: 16
Joined: 18 Aug 2017, 13:36
Has liked: 0 time
Been liked: 5 times
FAF User Name: Herby

Re: LINUX SUPPORT IS HERE

Postby tatsu » 21 Aug 2017, 22:58


Herby wrote:...




Herby mayhaps try this :
Code: Select all
sudo apt-get install python3-pycparser python3-dateutil python3-requests python3-cffi python3-semantic-version python3-virtualenv python3-dev liblua5.1-0-dev xdelta3 git
mkdir fafclient && cd fafclient
python3 /usr/lib/python3/dist-packages/virtualenv.py -p python3 --system-site-packages venv
sudo pip install -U --force-reinstall pip
sudo pip install ipaddress lupa trueskill marshmallow-jsonapi PyQt5
sudo wget https://github.com/FAForever/uid/releases/download/v4.0.5/faf-uid -O /usr/bin/faf-uid
sudo chmod +x /usr/bin/faf-uid
git clone https://github.com/FAForever/client.git
source ./venv/bin/activate
python3 ./client/src
User avatar
tatsu
Supreme Commander
 
Posts: 1553
Joined: 02 Jul 2012, 21:26
Has liked: 1952 times
Been liked: 171 times
FAF User Name: tatsu

Re: LINUX SUPPORT IS HERE

Postby Herby » 22 Aug 2017, 08:22

Just gave it a try but no luck, I still have this bloody problem with pyqt5:
Code: Select all
herby@PC:~/fafclient$ sudo pip install ipaddress lupa trueskill marshmallow-jsonapi PyQt5                       
The directory '/home/herby/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.                                                             
The directory '/home/herby/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.                                                                     
Collecting ipaddress
/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:318: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#snimissingwarning.
  SNIMissingWarning
/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
  InsecurePlatformWarning
  Downloading ipaddress-1.0.18-py2-none-any.whl
Collecting lupa
  Downloading lupa-1.4.tar.gz (217kB)
    100% |████████████████████████████████| 225kB 2.0MB/s
Collecting trueskill
  Downloading trueskill-0.4.4.tar.gz
Collecting marshmallow-jsonapi
  Downloading marshmallow-jsonapi-0.15.0.tar.gz
Collecting PyQt5
  Could not find a version that satisfies the requirement PyQt5 (from versions: )
No matching distribution found for PyQt5

For info, I've tried a second time after running the command "alias python=python3" but the outcome is exactly the same. And, in the end, I have the same error than here when trying to start the client.

While I'm here, I can show you how things go when I compile SIP & pyqt5 inside the virtual env. I'm doing this with the help of this tuto. As it is quite long, I've uploaded the output in pastebin: https://pastebin.com/hyMRxdap
I have a few errors during pyqt configure but I don't know if it is really an issue.

Which version of python should be used in the venv? I noticed that I always end up with python3.4 but the client I've successfully installed in a VM uses python 3.5. But here again, I'm not sure if it is a problem.

On the POL side, can you tell me which components are needed to have the latest update of the client? I remember that those components only work in a 32bit environment so I wanted to try to reinstall the whole thing in 32bit to see if it helps.
Herby
Crusader
 
Posts: 16
Joined: 18 Aug 2017, 13:36
Has liked: 0 time
Been liked: 5 times
FAF User Name: Herby

Re: LINUX SUPPORT IS HERE

Postby tatsu » 22 Aug 2017, 21:22

Herby wrote:Just gave it a try but no luck, I still have this bloody problem with pyqt5:
Code: Select all
herby@PC:~/fafclient$ sudo pip install ipaddress lupa trueskill marshmallow-jsonapi PyQt5                       
The directory '/home/herby/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.   


well see this in and of itself is not normal (E.G.: not the same as me on my computer)

We don't seem to have anything in common between my ubuntu and your kubuntu xD I never knew the two distros were so different xD

Code: Select all
sudo apt-get install python3-pycparser python3-dateutil python3-requests python3-cffi python3-semantic-version python3-virtualenv python3-dev liblua5.1-0-dev xdelta3 git
mkdir fafclient && cd fafclient
python3 /usr/lib/python3/dist-packages/virtualenv.py -p python3 --system-site-packages venv
sudo pip install -U --force-reinstall pip
sudo pip install PyQt5
pip install ipaddress lupa trueskill marshmallow-jsonapi
sudo wget https://github.com/FAForever/uid/releases/download/v4.0.5/faf-uid -O /usr/bin/faf-uid
sudo chmod +x /usr/bin/faf-uid
git clone https://github.com/FAForever/client.git
source ./venv/bin/activate
python3 ./client/src


Herby wrote:Which version of python should be used in the venv?


for me both python 2 and 3 work the same.

I've done the sip and pyqt compile before it ain't worth the hassle...

Herby wrote:so I wanted to try to reinstall the whole thing in 32bit to see if it helps.
irrelevant but regardless the components are compiled on pip install and all those are 32bit as for the rest it all comes with the git clone and is the latest version and I think it runs 32 bit regardless.
User avatar
tatsu
Supreme Commander
 
Posts: 1553
Joined: 02 Jul 2012, 21:26
Has liked: 1952 times
Been liked: 171 times
FAF User Name: tatsu

PreviousNext

Return to General Discussions

Who is online

Users browsing this forum: No registered users and 1 guest