diff --git a/ci/build_dist_rpi4.sh b/ci/build_dist_rpi4.sh new file mode 100755 index 00000000..44332376 --- /dev/null +++ b/ci/build_dist_rpi4.sh @@ -0,0 +1,35 @@ +# this script builds a full dsitribution on a RPI4 +# +# BEWARE : this is still experimental +# +# USAGE : MUST be called from the top of als sources dir +# +####################################################################### +set -e + +if [ ! -d venv ] +then + python3 -m venv --system-site-packages venv +fi + +. venv/bin/activate + +pip install --upgrade pip +pip install --upgrade wheel + +patch < ci/rpi4_requirements.patch +pip install -I -r requirements.txt + +python setup.py develop + +VERSION=$(grep __version__ src/als/__init__.py | tail -n1 | cut -d'"' -f2) + +if [ -z "${VERSION##*"dev"*}" ] ;then + VERSION=${VERSION}-$(git rev-parse --short HEAD) +fi + +pyinstaller -n als-${VERSION} --windowed --hidden-import='pkg_resources.py2_warn' src/als/main.py + +cd dist + +tar zcf als-${VERSION}.tgz als-${VERSION} \ No newline at end of file diff --git a/ci/rpi4_requirements.patch b/ci/rpi4_requirements.patch new file mode 100644 index 00000000..5ea0fe9b --- /dev/null +++ b/ci/rpi4_requirements.patch @@ -0,0 +1,13 @@ +diff --git a/requirements.txt b/requirements.txt +index 0096989..ad5d1fd 100644 +--- a/requirements.txt ++++ b/requirements.txt +@@ -2,8 +2,6 @@ astroalign==1.0.4 + astropy==4.0.1.post1 + dtcwt==0.12.0 + numpy==1.16.4 +-opencv-python==4.1.0.25 +-PyQt5==5.13.0 + pywi==0.3.dev12 + qimage2ndarray==1.8 + rawpy==0.13.1