CrossOver Support - Community Forums

Important Information These are community forums and not official technical support. If you need official support: Contact Us



CrossOver Games
Archived Discussion about CrossOver Games, Forum closed.

The following comments are owned by whoever posted them. We are not responsible for them in any way.


Crossover python3
ying
ying
Posted 2010-10-26 00:47
Hi all.
I am using Arch Linux with Crossover Games. Before 1 week Arch Linux changed to python3. Since /usr/bin/python will now point to the 3.x binary, any program requiring 2.x needs to point to /usr/bin/python2 instead.
Problem: I can't recompile the python guis, because there is no source. ;)  Is there any way to use my crossover again?
Ken Thomases
Ken Thomases  Staff Member
Posted 2010-10-26 00:58
Check your package system for a tool to let you switch which Python is the default.  For example, in MacPorts, there's a python_select package to install a tool to let you switch it.

If there's no such package, you can do the switch manually by replacing /usr/bin/python with a symlink to /usr/bin/python2.  I have no idea what that might break, though.  (Similar to how Arch Linux's decision to switch to Python 3 breaks CrossOver and any other Python 2.x software.)

If changing /usr/bin/python isn't an option, you can edit the Python scripts installed as part of CrossOver.  Replace each instance of "/usr/bin/python" with "/usr/bin/python2".  Tedious, but should work.

I know none of these is an ideal solution.  They're just possible interim workarounds.  We're aware of the issue and have a bug entered into our bug tracker about it.
ying
ying
Posted 2010-10-26 01:13
Thx. I managed it with a sed command... (http://allanmcrae.com/2010/10/big-python-transition-in-arch-linux/).
Now Crossover is running, but i can't install the new CrossOver Games 9.2. Where does Crossover Installer extract his files. So I can run the sed command again.
ying
ying
Posted 2010-10-26 01:18
K. I managed it. I made a link for python2 to python. Then I installed CrossOver. After that I made the old link python3 to python. Now i am running the sed command. ;)
xSubZer0x
Posted 2010-10-26 08:09
ying Posted:
K. I managed it. I made a link for python2 to python. Then I installed CrossOver. After that I made the old link python3 to python. Now i am running the sed command. ;)


Can you share how you "made a system link" I'm facing the same issue sadly.
ying
ying
Posted 2010-10-27 02:26
Thats easy.

sudo ln -sf /usr/bin/python2 /usr/bin/python


Then install CrossOver. Now don't forgett to relink the new python3:

sudo ln -sf /usr/bin/python3 /usr/bin/python


Now go into /opt/cxgames/bin and run this 2 commands with root access:

sed -i -e "s|#![ ]*/usr/bin/python$|#!/usr/bin/python2|" *
sed -i -e "s|#![ ]*/usr/bin/env python$|#!/usr/bin/env python2|" *


No go into  /opt/cxgames/lib/python and run this 2 commands:

sed -i -e "s|#![ ]*/usr/bin/python$|#!/usr/bin/python2|" *.py
sed -i -e "s|#![ ]*/usr/bin/env python$|#!/usr/bin/env python2|" *.py


Everything is working for me. ;)
Adriano Moura
Posted 2010-10-27 18:55
You should find the de-packaged files of the installer in /tmp/<something> dir. No need to do symlinks, just apply the sed commands!
Diego Xirinachs
Diego Xirinachs
Posted 2010-11-02 18:47
Adriano Moura Posted:
You should find the de-packaged files of the installer in /tmp/<something> dir. No need to do symlinks, just apply the sed commands!


Everytime a new crossover version comes out do I have to apply this sed commands?
Ken Thomases
Ken Thomases  Staff Member
Posted 2010-11-03 10:27
Assuming the new version of CrossOver doesn't include a fix for the issue, then yes, you'd have to reapply the changes.
Alex Lennon
Posted 2011-01-28 04:13
Hi,

I put together the commands from rmhz into a bash script as there was no fix for this issue in the latest upgrade.

Hopefully it's of some help to someone.
Alex


#######################################################
# MUST BE ROOT WITH X_WINDOWS ACCESS (E.G. USING "sux")
# TO RUN THIS INSTALL SCRIPT FOR A SYSTEM-WIDE INSTALL
#######################################################

#! /bin/sh

# temporaily switch from default python3 install to pythin2
ln -sf /usr/bin/python2 /usr/bin/python

# install crossover (the .bin package will need to be changed for a different version)
# the rest of the script assumes your are installing in "/opt/cxoffice"
sh install-crossover-pro-10.0.0.bin

# make sure to re-link back to python3 as default python or you will
# banjax your system (or at least those parts that depend on python)
sudo ln -sf /usr/bin/python3 /usr/bin/python

# make all references to python in "bin" and "lib/python" 
# directories be explicit to python2
cd /opt/cxoffice/bin
sed -i -e "s|#![ ]*/usr/bin/python$|#!/usr/bin/python2|" *
sed -i -e "s|#![ ]*/usr/bin/env python$|#!/usr/bin/env python2|" *
cd /opt/cxoffice/lib/python
sed -i -e "s|#![ ]*/usr/bin/python$|#!/usr/bin/python2|" *.py
sed -i -e "s|#![ ]*/usr/bin/env python$|#!/usr/bin/env python2|" *.py

# That should be it. Hope it works! (It does on my system at least)
Diego Xirinachs
Diego Xirinachs
Posted 2011-02-13 13:07
Thanks for the script, If I have it installed elsewere (my home folder) all I have to do is change the cd paths, right?
Diego Xirinachs
Diego Xirinachs
Posted 2011-03-22 17:28
Still no fix for this issue on 10.1.0 release?

thanks in advance
Randal Rioux
Randal Rioux
Posted 2011-04-19 23:33
Alex and Ying - just wanted to say thank you for posting the hack-trick. Worked great on my Arch64 desktop!

Randy
ying
ying
Posted 2011-05-22 12:44
Hmm, seams that version 10.1 doesn't want to run on my Arch machine. Somebody some hints?

Edit: Suddenly it runs. I will make a PKGBUILD.
ying
ying
Posted 2011-05-23 05:13
K. here are the PKGBUIDs for Arch Linux:

Crossover Games

Crossover Standart

Crossover Pro - Got it now ;)

And here are some wiki pages:

Crossover Office Wiki
Crossover Games Wiki

Enjoy;)
Pascal Sprei
Posted 2011-10-03 07:00
ying Posted:
K. here are the PKGBUIDs for Arch Linux:

Crossover Games

Crossover Standart

Crossover Pro - Got it now ;)

And here are some wiki pages:

Crossover Office Wiki
Crossover Games Wiki

Enjoy;)



Can you tell me how to use this PKGBUILDs ? ;)

Thanks very much ^^
ying
ying
Posted 2011-11-06 04:38
Pascal Sprei Posted:
ying Posted:
K. here are the PKGBUIDs for Arch Linux:

Crossover Games

Crossover Standart

Crossover Pro - Got it now ;)

And here are some wiki pages:

Crossover Office Wiki
Crossover Games Wiki

Enjoy;)



Can you tell me how to use this PKGBUILDs ? ;)

Thanks very much ^^



https://wiki.archlinux.org/index.php/Creating_Packages

or just use an aur helper like yaourt:


yaourt -S crossover-games

Please Note: This Forum is for non-application specific questions relating to installation/configuration of CrossOver. All application-specific posts to this Forum will be moved to their appropriate Compatibility Center Forum.

CrossOver Forums: the place to discuss running Windows applications on Mac and Linux

Please Wait...
eyJjYXJ0IjowLCJ0enMiOi01LCJjZG4iOiJodHRwczpcL1wvbWVkaWEuY29kZXdlYXZlcnMuY29tXC9wdWJcL2Nyb3Nzb3Zlclwvd2Vic2l0ZSIsImNkbnRzIjoxNTAwNDkwNTYzfQ==