Changeset 976:69bc5891e14d


Ignore:
Timestamp:
05/24/19 18:31:43 (6 years ago)
Author:
István Váradi <ivaradi@…>
Branch:
python3
Phase:
public
Message:

Reworked Windows Docker image and MSYS building (re #347)

Files:
3 added
3 edited
1 copied

Legend:

Unmodified
Added
Removed
  • .hgignore

    r758 r976  
    1212debug.log
    1313moodlesetup.txt
     14docker/msys/id_rsa
  • docker/msys/Dockerfile

    r920 r976  
    1414    Remove-Item 7z.msi
    1515
    16 RUN $env:MSYSTEM='MINGW32' ; `
    17     Start-Process C:\msys64\usr\bin\pacman.exe -ArgumentList '-Syu --noconfirm' -Wait -PassThru -Verbose -WorkingDirectory 'C:\msys64' ; `
    18     Start-Process C:\msys64\usr\bin\pacman.exe -ArgumentList '-Su --noconfirm' -Wait -PassThru -Verbose -WorkingDirectory 'C:\msys64' ; `
    19     Start-Process C:\msys64\usr\bin\bash.exe -ArgumentList '--login -c /usr/bin/true.exe' -Wait -PassThru -Verbose -WorkingDirectory 'C:\msys64'; `
    20     mkdir C:\msys64\build
     16RUN $env:MSYSTEM='MINGW32'  ; `
     17    C:\msys64\usr\bin\bash.exe --login -c /usr/bin/true.exe ; `
     18    C:\msys64\usr\bin\pacman.exe -Syu --noconfirm ; `
     19    C:\msys64\usr\bin\pacman.exe -Su --noconfirm ; `
     20    C:\msys64\usr\bin\pacman.exe -Scc --noconfirm
    2121
    22 COPY setup.sh pywin32.patch pywin32git.patch cef_binary_3.3359.1774.gd49d25f_windows32.patch cefpython-66.0.patch py2exe.patch C:\msys64\build\
     22COPY setup.sh C:\msys64\build\
    2323
    2424RUN $env:MSYSTEM='MINGW32'; `
    25     C:\msys64\usr\bin\bash.exe --login  C:\msys64\build\setup.sh ;
     25    C:\msys64\usr\bin\bash.exe --login -c /build/setup.sh
     26
     27COPY build.bat build.sh pywin32.patch pywin32git.patch cef_binary_3.3359.1774.gd49d25f_windows32.patch cefpython-66.0.patch py2exe.patch id_rsa C:\msys64\build\
     28
     29CMD ["powershell.exe"]
  • docker/msys/build.sh

    r920 r976  
    22
    33set -e -u
    4 
    5 pacman -S --noconfirm mc patch unzip mingw-w64-i686-python3 mingw-w64-i686-python3-setuptools mingw-w64-i686-gcc  mingw-w64-i686-gtk3 mingw-w64-i686-python3-lxml mingw-w64-i686-cmake mingw-w64-i686-make mingw-w64-i686-python3-pip mingw-w64-i686-python3-pillow mingw-w64-i686-python3-gobject mingw-w64-i686-python3-cffi
    6 pacman -Scc --noconfirm
    7 
    8 pip3 install jsonrpclib-pelix
    94
    105echo "Building PyWin32"
     
    6661python3 setup.py install
    6762
    68 cd /
    69 rm -rf /build
     63echo "Archiving msys64 directory"
     64cd /c
     65tar czf - msys64 | ssh -i /c/msys64/build/id_rsa -o StrictHostKeyChecking=no ivaradi@mises.varadiistvan.hu mlx/www/update/msys64.sh
  • docker/msys/setup.sh

    r920 r976  
    33set -e -u
    44
    5 pacman -S --noconfirm mc patch unzip mingw-w64-i686-python3 mingw-w64-i686-python3-setuptools mingw-w64-i686-gcc  mingw-w64-i686-gtk3 mingw-w64-i686-python3-lxml mingw-w64-i686-cmake mingw-w64-i686-make mingw-w64-i686-python3-pip mingw-w64-i686-python3-pillow mingw-w64-i686-python3-gobject mingw-w64-i686-python3-cffi
     5echo "Installing extra packages..."
     6
     7pacman -S --noconfirm mc patch unzip openssh ca-certificates mingw-w64-i686-python3 mingw-w64-i686-python3-setuptools mingw-w64-i686-gcc  mingw-w64-i686-gtk3 mingw-w64-i686-python3-lxml mingw-w64-i686-cmake mingw-w64-i686-make mingw-w64-i686-python3-pip mingw-w64-i686-python3-pillow mingw-w64-i686-python3-gobject mingw-w64-i686-python3-cffi
    68pacman -Scc --noconfirm
    79
    810pip3 install jsonrpclib-pelix
    9 
    10 echo "Building PyWin32"
    11 
    12 cd /build
    13 
    14 wget -O - https://github.com/mhammond/pywin32/archive/b224.tar.gz | gzip -dc | tar xf -
    15 cd pywin32-b224
    16 patch -p1 < ../pywin32git.patch
    17 patch -p1 < ../pywin32.patch
    18 python3 setup.py build
    19 python3 setup.py install
    20 
    21 echo "Building CEFPython"
    22 
    23 cd /build
    24 
    25 wget -O - http://opensource.spotify.com/cefbuilds/cef_binary_3.3359.1774.gd49d25f_windows32.tar.bz2 | bzip2 -dc | tar xf -
    26 cd cef_binary_3.3359.1774.gd49d25f_windows32
    27 
    28 patch -p1 < ../cef_binary_3.3359.1774.gd49d25f_windows32.patch
    29 mv tests tests.orig
    30 
    31 mkdir build
    32 cd build
    33 /usr/bin/env PATH=/mingw32/bin:/usr/local/bin::/c/Windows/System32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0 cmake  -G "MinGW Makefiles" ..
    34 cd libcef_dll_wrapper
    35 mingw32-make
    36 
    37 cd /build
    38 
    39 wget -O - https://github.com/cztomczak/cefpython/archive/v66.0.tar.gz | gzip -dc | tar xf -
    40 cd cefpython-66.0
    41 
    42 patch -p1 < ../cefpython-66.0.patch
    43 
    44 mkdir -p build
    45 cd build
    46 
    47 wget https://github.com/cztomczak/cefpython/releases/download/v66-upstream/cef66_3.3359.1774.gd49d25f_win32.zip
    48 unzip cef66_3.3359.1774.gd49d25f_win32.zip
    49 rm cef66_3.3359.1774.gd49d25f_win32.zip
    50 
    51 cp /build/cef_binary_3.3359.1774.gd49d25f_windows32/build/libcef_dll_wrapper/libcef_dll_wrapper.a cef66_3.3359.1774.gd49d25f_win32/lib
    52 
    53 pip3 install -r ../tools/requirements.txt
    54 
    55 python3 ../tools/build.py --no-run-tests --no-run-examples 66.0  || true
    56 python3 ../tools/build.py --no-run-tests --no-run-examples 66.0
    57 
    58 echo "Building Py2EXE"
    59 
    60 cd /build
    61 
    62 wget -O - https://github.com/albertosottile/py2exe/archive/v0.9.3.0.tar.gz | gzip -dc | tar xf -
    63 cd py2exe-0.9.3.0
    64 patch -p1 < ../py2exe.patch
    65 python3 setup.py build
    66 python3 setup.py install
    67 
    68 cd /
    69 rm -rf /build
Note: See TracChangeset for help on using the changeset viewer.