Skip to content

Instantly share code, notes, and snippets.

@suizokukan
Last active February 12, 2020 10:20
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save suizokukan/8abb8437561048c63080575b54dce70a to your computer and use it in GitHub Desktop.
Save suizokukan/8abb8437561048c63080575b54dce70a to your computer and use it in GitHub Desktop.
pyqtdeploy : demo build (target : linux_64)
# ############################################################################
# step by step : compile pyqt-demo for linux-64 architecture
#
# v. 5
#
# pyqtdeploy : www.riverbankcomputing.com/software/pyqtdeploy/
# mercurial : www.riverbankcomputing.com/hg/pyqtdeploy
# mailing list : http://python.6.x6.nabble.com/PyQt-f1792048.html
#
# ############################################################################
#
# NB : pyqt-demo is in the demo/ subdirectory of https://files.pythonhosted.org/packages/4b/d7/14954c622d1810c80a6e206c496504e0b44f847c5c697aa2e8ff0b048a52/pyqtdeploy-2.3.tar.gz
#
# ############################################################################
# disk space : ~ 6 Go
# build duration : ~ 3 hours.
# #############################################################################
# ======================================================================================
# === (step 0/3) start with an Ubuntu 18.04 (fresh installation, up-to-date, rebooted) =
# ======================================================================================
# ============================================
# === (step 1/3) download the dependencies ===
# ============================================
# general dependencies
echo "######### (1) general dependencies #########"
sudo apt-get update
sudo apt-get -y install python3-pip
sudo -H pip3 install pyqt5
#$ sudo -H pip3 install pyqtdeploy
# snapshots: see https://www.riverbankcomputing.com/software/pyqtdeploy/download
echo "######### (2) pyqtdeploy #########"
sudo -H pip3 install https://www.riverbankcomputing.com/static/Downloads/pyqtdeploy/pyqtdeploy-2.3.1.dev1811241346.tar.gz
# required by qmake:
echo "######### (3) dependencies required by qmake #########"
sudo apt -y install python
sudo apt -y install libssl1.0-dev
sudo apt -y install libudev-dev
sudo apt -y install libx11-xcb-dev
sudo apt -y install libjpeg-dev
sudo apt -y install libts-dev
sudo apt -y install libvulkan-dev
sudo apt -y install libcups2-dev
sudo apt -y install libmysqlclient-dev libdrm-dev libharfbuzz-dev libsqlite-dev
# opengl : https://medium.com/@Plimsky/how-to-install-a-opengl-environment-on-ubuntu-e3918cf5ab6c
echo "######### (4) dependencies required by qmake : opengl #########"
sudo apt-get -y install cmake libx11-dev xorg-dev libglu1-mesa-dev freeglut3-dev libglew1.5 libglew1.5-dev libglu1-mesa libglu1-mesa-dev libgl1-mesa-glx libgl1-mesa-dev
# required by qmake : python 3.7
# https://tecadmin.net/install-python-3-7-on-ubuntu-linuxmint/
# ... improved by : https://stackoverflow.com/questions/27022373/python3-importerror-no-module-named-ctypes-when-using-value-from-module-mul
echo "######### (5) dependencies required by qmake : python 3.7 #########"
sudo apt-get update
sudo apt-get upgrade
sudo apt-get dist-upgrade
sudo apt-get -y install build-essential python-dev python-setuptools python-pip python-smbus
sudo apt-get -y install libncursesw5-dev libgdbm-dev libc6-dev
sudo apt-get -y install zlib1g-dev libsqlite3-dev tk-dev
sudo apt-get -y install libssl-dev openssl
sudo apt-get -y install libffi-dev
sudo wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz
sudo tar xzf Python-3.7.0.tgz
cd Python-3.7.0
sudo ./configure --enable-optimizations
sudo make altinstall
# ==================================================
# === (step 2/3) download every required tarball ===
# ==================================================
# python : https://www.python.org/ftp/python/3.7.1/Python-3.7.1.tar.xz at https://www.python.org/downloads/release/python-371/
# qt : https://download.qt.io/archive/qt/5.11/5.11.1/single/qt-everywhere-src-5.11.1.tar.xz at https://download.qt.io/archive/qt/5.11/5.11.1/single/
# openssl : https://www.openssl.org/source/openssl-1.1.1.tar.gz at https://www.openssl.org/source/
# zlib : https://zlib.net/zlib-1.2.11.tar.gz at https://zlib.net/
# sip : https://sourceforge.net/projects/pyqt/files/sip/sip-4.19.13/sip-4.19.13.tar.gz at https://riverbankcomputing.com/software/sip/download
# PyQt5 : https://sourceforge.net/projects/pyqt/files/PyQt5/PyQt-5.11.3/PyQt5_gpl-5.11.3.tar.gz at https://www.riverbankcomputing.com/software/pyqt/download5
# PyQt3D : https://sourceforge.net/projects/pyqt/files/PyQt3D/PyQt3D-5.11.3/PyQt3D_gpl-5.11.3.tar.gz at https://www.riverbankcomputing.com/software/pyqt3d/download
# PyQtChart : https://sourceforge.net/projects/pyqt/files/PyQtChart/PyQtChart-5.11.3/PyQtChart_gpl-5.11.3.tar.gz at https://www.riverbankcomputing.com/software/pyqtchart/download
# PyQtDataVisualization : https://sourceforge.net/projects/pyqt/files/PyQtDataVisualization/PyQtDataVisualization-5.11.3/PyQtDataVisualization_gpl-5.11.3.tar.gz at https://www.riverbankcomputing.com/software/pyqtdatavisualization/download
# PyQtPurchasing : https://sourceforge.net/projects/pyqt/files/PyQtPurchasing/PyQtPurchasing-5.11.3/PyQtPurchasing_gpl-5.11.3.tar.gz at https://www.riverbankcomputing.com/software/pyqtpurchasing/download
# QScintilla : https://sourceforge.net/projects/pyqt/files/QScintilla2/QScintilla-2.10.8/QScintilla_gpl-2.10.8.tar.gz at https://www.riverbankcomputing.com/software/qscintilla/download
# =============================================
# === (step 3/3) build the demo application ===
# =============================================
# build in the demo/ directory :
# $ python3 build-demo.py --verbose --source-dir=/home/sui/Desktop/induperator/induperator_qt_pyqtdeploy/buildstuff/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment