source: misc/build-cefpython.sh@ 1097:f2ac841cffec

python3
Last change on this file since 1097:f2ac841cffec was 1092:f3c535a548c2, checked in by István Váradi <ivaradi@…>, 18 months ago

The CEFPytohn build script is updated for Python 3.11

  • Property exe set to *
File size: 1.8 KB
Line 
1#!/bin/bash
2
3# build-cefpython.sh <builddir>
4#
5# Build CEF Python (the latest compatible version with the MAVA Logger X)
6# for Linux in the given build directory.
7
8set -e -u -x
9
10CEF_VERSION_MAJOR="108"
11CEF_VERSION_MINOR="4"
12CEF_VERSION_SHORT="${CEF_VERSION_MAJOR}.${CEF_VERSION_MINOR}"
13CEF_VERSION="${CEF_VERSION_SHORT}.13"
14CEF_FULL_VERSION="${CEF_VERSION}+ga98cd4c+chromium-108.0.5359.125"
15
16CEF_NAME="cef_binary_${CEF_FULL_VERSION}_linux64"
17CEFPYTHON_CEF_DIRNAME="cef${CEF_VERSION_MAJOR}_${CEF_FULL_VERSION}_linux64"
18CEFPYTHON_SHA="dbc68bb401f2163496e2503bb89a7084cd92bd56"
19MAKEJOBS="16"
20
21builddir="${1}"
22
23mkdir -p "${builddir}"
24
25cd "${builddir}"
26rm -rf "${CEF_NAME}"
27wget -O - "https://cef-builds.spotifycdn.com/${CEF_NAME}.tar.bz2" | bzip2 -dc | tar xf -
28
29cd "${CEF_NAME}"
30mv tests tests.orig
31mkdir build
32cd build
33cmake -G "Unix Makefiles" ..
34cd libcef_dll_wrapper
35make -j${MAKEJOBS}
36
37cd "${builddir}"
38rm -rf "cefpython-${CEFPYTHON_SHA}"
39
40wget -O - https://github.com/ivaradi/cefpython/archive/${CEFPYTHON_SHA}.tar.gz | gzip -dc | tar xf -
41
42cd "cefpython-${CEFPYTHON_SHA}"
43mkdir build
44cd build
45
46mkdir -p "${CEFPYTHON_CEF_DIRNAME}/bin"
47mv "${builddir}/${CEF_NAME}/Release/"* "${CEFPYTHON_CEF_DIRNAME}/bin"
48mv "${builddir}/${CEF_NAME}/Resources/"* "${CEFPYTHON_CEF_DIRNAME}/bin"
49
50mkdir -p "${CEFPYTHON_CEF_DIRNAME}/lib"
51mv "${builddir}/${CEF_NAME}/build/libcef_dll_wrapper/libcef_dll_wrapper.a" "${CEFPYTHON_CEF_DIRNAME}/lib"
52
53mv "${builddir}/${CEF_NAME}/LICENSE.txt" "${CEFPYTHON_CEF_DIRNAME}"
54
55pip3 install --break-system-packages -r ../tools/requirements.txt
56
57python3 ../tools/build.py "${CEF_VERSION}" || true
58python3 ../tools/make_installer.py "${CEF_VERSION_SHORT}"
59
60cd "cefpython3_${CEF_VERSION_SHORT}_linux64"
61python3 setup.py bdist_wheel
62mv "dist/cefpython3-${CEF_VERSION_SHORT}-"*".whl" "${builddir}"
Note: See TracBrowser for help on using the repository browser.