~boringcactus/vidslice

5d62b37fb4ec9d205422d87900a10bf2b41c8ac5 — Melody Horn 1 year, 9 months ago 3364694
make sure the build actually works (#1)

* get ready to wrestle with build infra for three hours

* put some things back where they came from

* juggle more dependency stuff

* it's always something

* use correct python

* look harder for the correct DLLs fml

* correctly disable sh -x

* i swear to fuckin christ

* bdg voice i am going to throw myself into the sea
5 files changed, 25 insertions(+), 26 deletions(-)

M .travis.yml
M scripts/setup_linux.sh
M scripts/setup_osx.sh
M scripts/setup_windows.sh
M setup.py
M .travis.yml => .travis.yml +16 -5
@@ 1,21 1,32 @@
language: shell
if: tag IS present
dist: xenial
if: tag IS present OR branch = build-fuckery
dist: bionic
os:
  - linux
  - osx
  - windows
addons:
  apt:
    packages:
      - python3.7
      - python3.7-dev
      - python3-pip
      - python3-setuptools
      - python3-tk
  homebrew:
    packages:
      - python
      - python@3.7
before_install:
  - chmod +x scripts/setup_${TRAVIS_OS_NAME}.sh
  - . scripts/setup_${TRAVIS_OS_NAME}.sh
install:
  - which python3 && export PYTHON=python3 || export PYTHON=python
  - which python && export PYTHON=python || echo whatever
  - which python3 && export PYTHON=python3 || echo whatever
  - which python3.7 && export PYTHON=python3.7 || echo whatever
  - echo ${PYTHON}
  - ${PYTHON} -m pip install -f https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-16.04/ -r requirements.txt
  - ${PYTHON} -m pip install -r requirements.txt
script:
  - ${PYTHON} setup.py build
before_deploy:
  - ${PYTHON} setup.py build
  - pushd build

M scripts/setup_linux.sh => scripts/setup_linux.sh +0 -6
@@ 1,7 1,1 @@
#!/usr/bin/env bash
set -x

sudo apt-get update
sudo apt-get install -y python3 python3-dev python3-pip python3-setuptools libgtk2.0-dev libgtk-3-dev libjpeg-dev libtiff-dev libsdl1.2-dev libgstreamer-plugins-base0.10-dev libnotify-dev freeglut3 freeglut3-dev libsm-dev libwebkitgtk-dev libwebkitgtk-3.0-dev

set +x

M scripts/setup_osx.sh => scripts/setup_osx.sh +0 -3
@@ 1,4 1,1 @@
#!/usr/bin/env bash
set -x

set +x

M scripts/setup_windows.sh => scripts/setup_windows.sh +1 -8
@@ 1,12 1,5 @@
#!/usr/bin/env bash
set -x

choco install python
choco install python --version 3.7.9 -y
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
echo $PATH
export PATH=/C/Python37:$PATH
which python
python get-pip.py
python -m pip install --upgrade git+https://github.com/anthony-tuininga/cx_Freeze.git@master

set +x

M setup.py => setup.py +8 -4
@@ 11,10 11,14 @@ buildOptions = dict(packages=[], excludes=[])

PYTHON_INSTALL_DIR = os.path.dirname(os.path.dirname(os.__file__))
if sys.platform == "win32":
    buildOptions['include_files'] = [
        os.path.join(PYTHON_INSTALL_DIR, 'DLLs', 'libcrypto-1_1-x64.dll'),
        os.path.join(PYTHON_INSTALL_DIR, 'DLLs', 'libssl-1_1-x64.dll'),
    ]
    dlls_folder = os.path.join(PYTHON_INSTALL_DIR, 'DLLs')
    targets = ['libcrypto', 'libssl']
    include_files = []
    for dll in os.listdir(dlls_folder):
        for target in targets:
            if target.startswith(target):
                include_files.append(os.path.join(dlls_folder, dll))
    buildOptions['include_files'] = include_files

base = 'Win32GUI' if sys.platform == 'win32' else None