diff --git a/.appveyor.yml b/.appveyor.yml index e7208c6d1..dbc390fb0 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -19,10 +19,11 @@ for: - sh: curl -sflL 'https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-ssh.sh' | bash -e - install: - sh: git fetch --prune --unshallow # to fix the version dump issues - - sh: sudo DEBIAN_FRONTEND=noninteractive apt-get -y update - - sh: sudo DEBIAN_FRONTEND=noninteractive apt-get -y install python3.11-dev libgtk-3-dev python3-pip libwebkit2gtk-4.0-dev + - sh: sudo add-apt-repository ppa:deadsnakes/ppa + - sh: sudo DEBIAN_FRONTEND=noninteractive apt -y update + - sh: sudo DEBIAN_FRONTEND=noninteractive apt -y install python3.11-dev libgtk-3-dev python3-pip libwebkit2gtk-4.0-dev # Needed to build binary distribution of wx - - sh: sudo DEBIAN_FRONTEND=noninteractive apt-get -y install libnotify4 libsdl2-2.0-0 libfuse2 + - sh: sudo DEBIAN_FRONTEND=noninteractive apt -y install libnotify4 libsdl2-2.0-0 libfuse2 before_build: - sh: mkdir build - sh: curl -o build/$APPIMAGE_TOOL -L https://github.com/AppImageCrafters/appimage-builder/releases/download/v1.1.0/appimage-builder-1.1.0-x86_64.AppImage diff --git a/dist_assets/linux/AppImageBuilder.yml b/dist_assets/linux/AppImageBuilder.yml index 2a043c445..d98dacdd7 100644 --- a/dist_assets/linux/AppImageBuilder.yml +++ b/dist_assets/linux/AppImageBuilder.yml @@ -8,32 +8,37 @@ AppDir: name: pyfa icon: pyfa version: $PYFA_VERSION - exec: ${APPDIR}/bin/python3 + exec: ${APPDIR}/bin/python3.11 exec_args: "-s ${APPDIR}/opt/pyfa/pyfa.py $@" + before_bundle: + + apt: arch: [ amd64 ] sources: - - sourceline: 'deb [arch=amd64] http://archive.ubuntu.com/ubuntu/ bionic main restricted universe multiverse' - key_url: 'http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x3b4fe6acc0b21f32' + - sourceline: 'deb http://us.archive.ubuntu.com/ubuntu jammy main restricted universe multiverse' +# - sourceline: 'deb http://us.archive.ubuntu.com/ubuntu jammy-updates main restricted universe multiverse' +# - sourceline: 'deb http://us.archive.ubuntu.com/ubuntu jammy-backports main restricted universe multiverse' + - sourceline: 'deb http://us.archive.ubuntu.com/ubuntu jammy-security main restricted universe multiverse' + - sourceline: 'deb https://ppa.launchpadcontent.net/deadsnakes/ppa/ubuntu jammy main' + key_url: 'keyserver.ubuntu.com/pks/lookup?op=get&search=0xf23c5a6cf475977595c89f51ba6932366a755776' include: - - libc6 + - python3.11 exclude: [] after_bundle: - # Detect location of python using venv config and copy it over to our app directory - - cp -r `~/venv3.11/bin/python scripts/getConfigVal.py ~/venv3.11/pyvenv.cfg base-prefix`/* $AppDir # Install python dependencies - - $AppDir/bin/python3 -s -m pip install -U pip setuptools wheel - - $AppDir/bin/python3 -s -m pip install -f https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-22.04 -r requirements.txt + - python3.11 -s -m pip install -U pip setuptools wheel + - python3.11 -s -m pip install -f https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-22.04 -r requirements.txt # Compile app data - find locale/ -type f -name "*.po" -exec msgen "{}" -o "{}" \; - - $AppDir/bin/python3 scripts/compile_lang.py - - $AppDir/bin/python3 scripts/dump_crowdin_progress.py - - $AppDir/bin/python3 db_update.py + - python3.11 scripts/compile_lang.py + - python3.11 scripts/dump_crowdin_progress.py + - python3.11 db_update.py # Calculate app version - - export PYFA_VERSION="$($AppDir/bin/python3 scripts/dump_version.py)" + - export PYFA_VERSION="$(python3.11 scripts/dump_version.py)" # Copy app and clean it up - mkdir -p $AppDir/usr/src - cp -r eos graphs gui imgs locale service utils eve.db config.py pyfa.py db_update.py README.md LICENSE version.yml $AppDir/usr/src diff --git a/scripts/getConfigVal.py b/scripts/getConfigVal.py deleted file mode 100644 index 5e27c8e24..000000000 --- a/scripts/getConfigVal.py +++ /dev/null @@ -1,22 +0,0 @@ -""" -Script used to extract values from section-less configs. - -Used in linux image build process. -""" - -import argparse -import configparser -import os - - -parser = argparse.ArgumentParser(description='Extract values from section-less configs') -parser.add_argument('path', help='path to config file') -parser.add_argument('variable', help='variable name') -args = parser.parse_args() - -with open(os.path.expanduser(args.path), 'r') as file: - text = file.read() - -config = configparser.ConfigParser() -config.read_string(f'[root]\n{text}') -print(config.get('root', args.variable))