Skip to content

Commit

Permalink
Update python, pyside, pyinstaller, numpy, and gclib
Browse files Browse the repository at this point in the history
  • Loading branch information
LagoLunatic committed Dec 10, 2023
1 parent 47a055d commit 4b8b92a
Show file tree
Hide file tree
Showing 19 changed files with 31 additions and 32 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/python-app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,11 @@ jobs:
- uses: actions/checkout@v3
with:
submodules: recursive
- name: Set up Python 3.11
- name: Set up Python
id: setup-py
uses: actions/setup-python@v4
with:
python-version: '3.11'
python-version: '3.12'
architecture: ${{ matrix.architecture }}
cache: 'pip' # Cache all pip dependency downloads
- name: Get PyJ3DUltra submodule status for cache
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,12 @@ Download and install git from here: https://git-scm.com/downloads
Then clone this repository with git by running this in a command prompt:
`git clone https://github.com/LagoLunatic/GCFT.git --recurse-submodules=":(exclude)PyJ3DUltra"`

Download and install Python 3.11.5 from here: https://www.python.org/downloads/release/python-3115/
Download and install Python 3.12 from here: https://www.python.org/downloads/release/python-3121/
"Windows installer (64-bit)" is the one you want if you're on Windows, "macOS 64-bit universal2 installer" if you're on Mac.
If you're on Linux, run this command instead: `sudo apt-get install python3.11`
If you're on Linux, run this command instead: `sudo apt-get install python3.12`

Open the GCFT folder in a command prompt and install dependencies by running:
`py -3.11 -m pip install -r requirements.txt` (on Windows)
`py -3.12 -m pip install -r requirements.txt` (on Windows)
`python3 -m pip install -r requirements.txt` (on Mac)
`python3 -m pip install $(cat requirements.txt) --user` (on Linux)

Expand All @@ -66,7 +66,7 @@ Then run GCFT with:

Optionally, if you want J3D model previews to display while running from source, you must also clone and build PyJ3DUltra.
A script that automates this process is provided. Simply run the following command:
`py -3.11 build_pyj3dultra.py`
`py -3.12 build_pyj3dultra.py`
On Windows, you must first [install vcpkg](https://vcpkg.io/en/getting-started) before running that command.

If the script ran successfully with no errors, then the next time you load a J3D model in GCFT you should see a 3D preview.
4 changes: 2 additions & 2 deletions build.bat
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
py -3.11 -m PyInstaller gcft.spec
py -3.12 -m PyInstaller gcft.spec
if %errorlevel% neq 0 exit /b %errorlevel%
py -3.11 build.py
py -3.12 build.py
if %errorlevel% neq 0 exit /b %errorlevel%
1 change: 1 addition & 0 deletions build.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/usr/bin/python3

import os
import platform
Expand Down
2 changes: 1 addition & 1 deletion build_pyj3dultra.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/python3.11
#!/usr/bin/python3

import os
import sys
Expand Down
2 changes: 1 addition & 1 deletion gcft.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/python3.11
#!/usr/bin/python3

import traceback
from PySide6.QtGui import *
Expand Down
2 changes: 1 addition & 1 deletion gcft_ui/#build_ui.bat
Original file line number Diff line number Diff line change
@@ -1 +1 @@
py #build_ui.py
py -3.12 #build_ui.py
12 changes: 5 additions & 7 deletions gcft_ui/#build_ui.py
Original file line number Diff line number Diff line change
@@ -1,18 +1,16 @@
#!/usr/bin/python3.11
#!/usr/bin/python3

from subprocess import call
import glob
import os

if not os.path.isdir("uic"):
os.makedirs("uic")
for input_path in glob.glob('*.ui'):
base_name = os.path.splitext(input_path)[0]
output_path = "uic/ui_%s.py" % base_name
ui_dir = os.path.dirname(__file__)
for input_path in glob.glob(glob.escape(ui_dir) + "/*.ui"):
base_name = os.path.splitext(os.path.basename(input_path))[0]

command = [
"pyside6-uic",
input_path,
"-o", output_path
"-o", os.path.join(ui_dir, "uic", "ui_%s.py" % base_name)
]
result = call(command)
2 changes: 1 addition & 1 deletion gcft_ui/uic/ui_bti_tab.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
################################################################################
## Form generated from reading UI file 'bti_tab.ui'
##
## Created by: Qt User Interface Compiler version 6.5.2
## Created by: Qt User Interface Compiler version 6.6.1
##
## WARNING! All changes made in this file will be lost when recompiling UI file!
################################################################################
Expand Down
2 changes: 1 addition & 1 deletion gcft_ui/uic/ui_dol_tab.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
################################################################################
## Form generated from reading UI file 'dol_tab.ui'
##
## Created by: Qt User Interface Compiler version 6.4.0
## Created by: Qt User Interface Compiler version 6.6.1
##
## WARNING! All changes made in this file will be lost when recompiling UI file!
################################################################################
Expand Down
2 changes: 1 addition & 1 deletion gcft_ui/uic/ui_gcm_tab.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
################################################################################
## Form generated from reading UI file 'gcm_tab.ui'
##
## Created by: Qt User Interface Compiler version 6.5.2
## Created by: Qt User Interface Compiler version 6.6.1
##
## WARNING! All changes made in this file will be lost when recompiling UI file!
################################################################################
Expand Down
2 changes: 1 addition & 1 deletion gcft_ui/uic/ui_j3d_tab.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
################################################################################
## Form generated from reading UI file 'j3d_tab.ui'
##
## Created by: Qt User Interface Compiler version 6.5.2
## Created by: Qt User Interface Compiler version 6.6.1
##
## WARNING! All changes made in this file will be lost when recompiling UI file!
################################################################################
Expand Down
2 changes: 1 addition & 1 deletion gcft_ui/uic/ui_jpc_tab.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
################################################################################
## Form generated from reading UI file 'jpc_tab.ui'
##
## Created by: Qt User Interface Compiler version 6.5.2
## Created by: Qt User Interface Compiler version 6.6.1
##
## WARNING! All changes made in this file will be lost when recompiling UI file!
################################################################################
Expand Down
2 changes: 1 addition & 1 deletion gcft_ui/uic/ui_main.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
################################################################################
## Form generated from reading UI file 'main.ui'
##
## Created by: Qt User Interface Compiler version 6.5.2
## Created by: Qt User Interface Compiler version 6.6.1
##
## WARNING! All changes made in this file will be lost when recompiling UI file!
################################################################################
Expand Down
2 changes: 1 addition & 1 deletion gcft_ui/uic/ui_rarc_tab.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
################################################################################
## Form generated from reading UI file 'rarc_tab.ui'
##
## Created by: Qt User Interface Compiler version 6.5.2
## Created by: Qt User Interface Compiler version 6.6.1
##
## WARNING! All changes made in this file will be lost when recompiling UI file!
################################################################################
Expand Down
2 changes: 1 addition & 1 deletion gcft_ui/uic/ui_yaz0_tab.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
################################################################################
## Form generated from reading UI file 'yaz0_tab.ui'
##
## Created by: Qt User Interface Compiler version 6.4.0
## Created by: Qt User Interface Compiler version 6.6.1
##
## WARNING! All changes made in this file will be lost when recompiling UI file!
################################################################################
Expand Down
2 changes: 1 addition & 1 deletion gclib
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
PySide6==6.5.2
PySide6~=6.6.0
PyYAML==6.0.1
Pillow==10.0.1
appdirs==1.4.4
-r ./gclib/requirements.txt
numpy==1.25.2
numpy~=1.26.0
PyOpenGL>=3.1.0,<3.1.7
pyrr==0.10.3
6 changes: 3 additions & 3 deletions requirements_full.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
PySide6==6.5.2
PySide6~=6.6.0
PyYAML==6.0.1
Pillow==10.0.1
appdirs==1.4.4
-r ./gclib/requirements_full.txt
numpy==1.25.2
numpy~=1.26.0
PyOpenGL>=3.1.0,<3.1.7
pyrr==0.10.3
PyInstaller==5.13.0
PyInstaller~=6.2.0

0 comments on commit 4b8b92a

Please sign in to comment.