diff --git a/README.md b/README.md index 5175223..c8e0781 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,7 @@ Windows and MAC OS X should be equally feasible. Note that the below instructions are written from a Linux/Ubuntu perspective, and probably need modifications for other platforms. -Scyther is written partly in Python 2 (for the GUI, using wxPython) and +Scyther is written partly in Python 3 (for the GUI, using wxPython) and partly in C (for the backend). In order to run the tool from a repository checkout, it is required to diff --git a/gui/INSTALL.md b/gui/INSTALL.md index 41f49be..8b52c43 100644 --- a/gui/INSTALL.md +++ b/gui/INSTALL.md @@ -41,35 +41,20 @@ from the command line) then you need only the first. 3. ### wxPython libraries ### The GUI user interface uses the wxPython libraries. + The recommended way of installing is through `pip` and described this page: - http://www.wxpython.org/download.php + https://www.wxpython.org/download.php - There are many different wxPython packages. You should choose a 32-bit - package that matches your Python version (e.g., 2.7). It is - recommended to select the unicode version from the stable releases. + This version of Scyther requires at least **wxPython 4.0**. Note that older versions of Scyther did not work with wxPython 4. - As of writing (May 2013) the following links lead to the appropriate - wxPython packages for Python 2.7: - - * **Windows** - - http://downloads.sourceforge.net/wxpython/wxPython2.8-win32-unicode-2.8.12.1-py27.exe - - * **Mac OS X** - - http://downloads.sourceforge.net/wxpython/wxPython2.8-osx-unicode-2.8.12.1-universal-py2.7.dmg - - Note that this package is in an old format and you will probably - get a warning "Package is damaged". This can be resolved by: - - ``` - $ sudo installer -pkg /Volume/.../wxPython2.8-osx-unicode-universal-py2.7.pkg/ -target / - ``` - - * **Ubuntu/Debian Linux** - - http://wiki.wxpython.org/InstallingOnUbuntuOrDebian + For Ubuntu users, it is important to add an additional parameter, e.g., for Ubuntu 20.04, the recommended pip install is: + ``` + $ sudo apt install python-pip + $ pip install -U \ + -f https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-20.04 \ + wxPython + ``` Running Scyther --------------- @@ -78,13 +63,13 @@ Extract the Scyther archive and navigate to the extracted directory. Start Scyther by executing the file - scyther-gui.py + `scyther-gui.py` in the main directory of the extracted archive. * **Mac OS X** - Right-click the file 'scyther-gui.py' and select "Open with" and + Right-click the file `scyther-gui.py` and select "Open with" and then "Python Launcher". diff --git a/gui/Scyther/Scyther.py b/gui/Scyther/Scyther.py index ba88f74..485bdf8 100755 --- a/gui/Scyther/Scyther.py +++ b/gui/Scyther/Scyther.py @@ -396,7 +396,6 @@ class Scyther(object): self.guessFileNames(spdl=spdl) # Generate temporary files for the output. - # Requires Python 2.3 though. (fde,fne) = tempfile.mkstemp() # errors (fdo,fno) = tempfile.mkstemp() # output if spdl: diff --git a/gui/Scyther/XMLReader.py b/gui/Scyther/XMLReader.py index 12514fc..b000957 100644 --- a/gui/Scyther/XMLReader.py +++ b/gui/Scyther/XMLReader.py @@ -37,7 +37,7 @@ import sys # Check for cElementTree presence. Otherwise use ElementTree. useiter = True try: - # python 2.5 has cElementTree in the core + # cElementTree is in Python since version 2.5 import xml.etree.cElementTree as cElementTree except: # try the old way diff --git a/gui/scyther-gui.py b/gui/scyther-gui.py index 4edc894..6616ab2 100755 --- a/gui/scyther-gui.py +++ b/gui/scyther-gui.py @@ -35,7 +35,7 @@ interface of Scyther. The [wxPython] packages can be found at http://www.wxpython.org/ Ubuntu users: the wxPython packages are called 'python-wxgtk' followed by the -version number.""" +version number. This version of Scyther requires at least wxPython version 4.0.""" elif ('32-bit mode' in str(err)) or ('no matching architecture' in str(err)): import os @@ -92,7 +92,6 @@ The exact error was: """ % (errmsg,err)) - #--------------------------------------------------------------------------- global WXPYTHON4 global WXPYTHONINFREQ