Commit 6c9e6854 authored by Philipp Hörist's avatar Philipp Hörist
Browse files

Switch to using MSYS2 for Windows build

parent 94be050a
......@@ -19,6 +19,7 @@ stamp-h1
Makefile
__pycache__/
src/gtk/
win/_build_root
syntax: regexp
^config\.*
......
environment:
matrix:
- PYTHON: "C:\\Python34"
- MSYS: "C:\\msys64\\mingw32.exe"
branches:
only:
......@@ -10,49 +9,36 @@ branches:
clone_depth: 1
install:
- git clone --depth=1 --branch=gtk3 https://dev.gajim.org/gajim/gajim-plugins.git c:\projects\gajim-plugins
# Download & Install Dependencys
- ps: c:\\projects\\gajim\\dependencys.ps1
- set PATH=C:\\MinGW\\bin;%PATH%
- "%PYTHON%\\python.exe -m pip install --upgrade pip"
- "%PYTHON%\\python.exe -m pip install -r c:\\projects\\gajim\\requirements.txt"
# init:
# - ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
- ps: Add-Content C:\Python34\Lib\site-packages\google\__init__.py " "
- "%PYTHON%\\python.exe -m pip install --no-dependencies python-axolotl"
- "%PYTHON%\\python.exe -m pip install --global-option=build_ext --global-option --compiler=mingw32 python-axolotl-curve25519"
# Prepare Build Dir
- cd c:\\projects\\gajim\\
- xcopy . ..\gajim_built /e /i
- cd ..\gajim_built
# Copy Shipped Plugins
- xcopy ..\gajim-plugins\plugin_installer plugins\plugin_installer /e /i
# Compile Translation Strings
- cmd: for %%l in (po\*.po) do mkdir po\%%~nl & mkdir po\%%~nl\LC_MESSAGES & msgfmt -o po\%%~nl\LC_MESSAGES\gajim.mo %%l
install:
# Make Gajim.exe
- "%PYTHON%\\python.exe setup_win32.py build_exe"
- ps: |
function bash($command) {
Write-Host $command -NoNewline
cmd /c start /wait C:\msys64\usr\bin\sh.exe --login -c $command
Write-Host " - OK" -ForegroundColor Green
}
- move build\exe.win32-3.4 .
- rmdir build
- rename exe.win32-3.4 build
bash 'pacman -Sy --noconfirm git'
bash 'git clone https://dev.gajim.org/lovetox/gajim.git'
# Make Installer
- ps: '& "C:\Program Files (x86)\NSIS\makensis.exe" gajim.nsi'
- ps: '& "C:\Program Files (x86)\NSIS\makensis.exe" gajim-portable.nsi'
- cmd: '%MSYS% C:/msys64/home/appveyor/gajim/win/build.sh'
# Ugly workaround, because i found no way to tell when mingw32.exe returns
- cmd: timeout 900
# Push Installer Exe
- ps: $env:TIME_STRING=(get-date -UFormat "%Y-%m-%d").ToString()
- ps: Push-AppveyorArtifact Gajim.exe -FileName "Gajim-default-$($env:TIME_STRING).exe"
- ps: Push-AppveyorArtifact Gajim-Portable.exe -FileName "Gajim-portable-default-$($env:TIME_STRING).exe"
- ps: $env:BUILDROOT="C:\msys64\home\appveyor\gajim\win\_build_root"
- ps: Push-AppveyorArtifact "$($env:BUILDROOT)/Gajim.exe" -FileName "Gajim-Master-$($env:TIME_STRING).exe"
- ps: Push-AppveyorArtifact "$($env:BUILDROOT)/Gajim-Portable.exe" -FileName "Gajim-Portable-Master-$($env:TIME_STRING).exe"
build: off
# on_finish:
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
deploy:
# FTP deployment provider settings
- provider: FTP
......
rmdir /S /Q ..\gajim_built
xcopy . ..\gajim_built /e /i
cd ..
cd gajim_built
xcopy ..\gajim-plugins\plugin_installer plugins\plugin_installer /e /i
rem copy C:\Python34\Lib\site-packages\gnome\msgfmt.exe gajim_built
rem copy C:\Windows\System32\msvcr100.dll gajim_built
for %%l in (po\*.po) do mkdir po\%%~nl & mkdir po\%%~nl\LC_MESSAGES & msgfmt -o po\%%~nl\LC_MESSAGES\gajim.mo %%l
"c:\python34\python.exe" setup_win32.py build_exe
move build\exe.win32-3.4 .
rmdir build
rename exe.win32-3.4 build
rem xcopy ..\win32com build\win32com /e /i
"C:\Program Files (x86)\NSIS\makensis" gajim.nsi
cd ..
pause
\ No newline at end of file
# Download the file to a specific location
$clnt = new-object System.Net.WebClient
$url = "https://gajim.org/downloads/snap/win/build/site-packages.zip"
$file = "c:\site-packages.zip"
$clnt.DownloadFile($url,$file)
# Unzip the file to specified location
$shell_app=new-object -com shell.application
$zip_file = $shell_app.namespace($file)
$destination = $shell_app.namespace("C:\Python34\Lib\site-packages")
$destination.Copyhere($zip_file.items())
cd src
python gajim.py
cd ..
# setup_win32.py (run me as python setup_win32.py py2exe -O2)
#
# Copyright (C) 2003-2014 Yann Leboulanger <asterix AT lagaule.org>
# Copyright (C) 2005-2006 Nikos Kouremenos <kourem AT gmail.com>
# Copyright (C) 2008 Jonathan Schleifer <js-gajim AT webkeks.org>
#
# This file is part of Gajim.
#
# Gajim is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published
# by the Free Software Foundation; version 3 only.
#
# Gajim is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Gajim. If not, see <http://www.gnu.org/licenses/>.
#
import sys
import os
import site
from cx_Freeze import setup, Executable
SITEDIR = site.getsitepackages()[1]
INCLUDE_DLL_PATH = os.path.join(SITEDIR, "gnome")
sys.path.append('src')
# Collect the list of missing dll when cx_freeze builds the app
MISSING_DLL = ['libgtk-3-0.dll',
'libgdk-3-0.dll',
'libatk-1.0-0.dll',
'libgdk_pixbuf-2.0-0.dll',
'libjpeg-8.dll',
'libpango-1.0-0.dll',
'libpangocairo-1.0-0.dll',
'libpangoft2-1.0-0.dll',
'libpangowin32-1.0-0.dll',
'libgnutls-28.dll',
'libp11-kit-0.dll',
'libgstrtp-1.0-0.dll',
'libgstrtsp-1.0-0.dll',
'libgstrtspserver-1.0-0.dll',
'libfarstream-0.2-5.dll',
'libgstsdp-1.0-0.dll',
'libgsttag-1.0-0.dll',
'libgssdp-1.0-3.dll',
'libgstvideo-1.0-0.dll',
'libgstapp-1.0-0.dll',
'libgupnp-1.0-4.dll',
'libgstaudio-1.0-0.dll',
'libgupnp-igd-1.0-4.dll',
'libgstbase-1.0-0.dll',
'libnice-10.dll',
'librsvg-2-2.dll',
'libvisual-0.4-0.dll',
'libwebp-5.dll',
'libgstriff-1.0-0.dll',
'libepoxy-0.dll',
'libharfbuzz-0.dll',
'libtiff-5.dll',
'libjasper-1.dll',
'libgstpbutils-1.0-0.dll',
'liborc-0.4-0.dll',
'libgstnet-1.0-0.dll',
'libsoup-2.4-1.dll',
'liborc-test-0.4-0.dll',
'libavcodec-57.dll',
'libavutil-55.dll',
'libswresample-2.dll',
'libavformat-57.dll',
'libavfilter-6.dll',
'libgssapi-3.dll',
'libopenssl.dll',
'libsqlite3-0.dll',
'libproxy.dll',
'libstdc++.dll',
'libgstfft-1.0-0.dll']
# We need to add all the libraries too (for themes, etc..)
GTK_LIBS = {
'etc': ['dbus-1', 'fonts', 'gtk-3.0', 'pango'],
'lib': ['farstream-0.2', 'gdbus-2.0',
'gdk-pixbuf-2.0', 'gio', 'girepository-1.0',
'gstreamer-1.0', 'gtk-3.0'],
'share': ['dbus-1', 'farstream', 'fonts',
'glib-2.0',
'gst-plugins-base', 'gstreamer-1.0', 'gupnp-av',
'gupnp-dlna-2.0', 'icons', 'ssl', 'themes', 'xml']
}
# Create the list of includes as cx_freeze likes
INCLUDE_FILES = []
for dll in MISSING_DLL:
INCLUDE_FILES.append((os.path.join(INCLUDE_DLL_PATH, dll), dll))
# Let's add gtk libraries folders and files
for folder in GTK_LIBS:
for lib in GTK_LIBS[folder]:
folder_lib = os.path.join(folder, lib)
INCLUDE_FILES.append((os.path.join(INCLUDE_DLL_PATH, folder_lib),
folder_lib))
#Let's add gtk locales that we support in Gajim
for language in next(os.walk('po'))[1]:
target_dir = os.path.join('share', 'locale', language)
language_dir = os.path.join(INCLUDE_DLL_PATH, target_dir)
if os.path.isdir(language_dir):
INCLUDE_FILES.append((language_dir, target_dir))
OPTIONS = {
'build_exe': {
'includes': ['gi', 'numbers', 'win32com.client', 'win32com.server'],
'packages': ['gi', 'cffi', 'cryptography', 'google', 'axolotl',
'pkg_resources', 'Crypto', 'pycparser', 'keyring',
'PIL', 'idna', 'qrcode', 'certifi'],
'include_files': INCLUDE_FILES,
}
}
setup(
name='Gajim',
version='0.16.10',
description='A full featured Jabber client',
author='Gajim Development Team',
url='http://gajim.org/',
download_url='http://gajim.org/downloads.php',
license='GPL',
options=OPTIONS,
executables=[Executable('src/gajim.py', icon='data/pixmaps/gajim.ico',
base='Win32GUI')],
)
# Windows Installer
We use [msys2](http://www.msys2.org/) for creating the Windows installer
and development on Windows.
### Development
-----------
Download [msys2](http://www.msys2.org/) (msys2-x86_64-xxx.exe) and follow the install instructions on the [msys2](http://www.msys2.org/) startpage (**Important!**)
* Fork the master branch on dev.gajim.org
* Execute ``C:\msys64\mingw32.exe``
* Run ``pacman -S git`` to install git
* Run ``git clone https://dev.gajim.org/USERNAME/gajim.git``
* Run ``cd gajim/win`` to end up where this README exists.
* Execute ``./dev_env.sh`` to install all the needed dependencies.
* Now go to the git root dir ``cd ..``
* Launch Gajim ``./launch.sh``
### Build Gajim / Creating an Installer
---------------------
Follow the steps in the Development section, but instead of ``./dev_env.sh`` execute ``./build.sh``.
You can supply a git tag ``./build.sh [git-tag]``.
Or dont supply it, then current HEAD is build.
Both the installer and the portable installer should appear in ``C:\msys64\home\USER\gajim\win\_build_root``.
#!/usr/bin/env bash
# Copyright 2016 Christoph Reiter
# Copyright 2017 Philipp Hörist
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
set -e
DIR="$( cd "$( dirname "$0" )" && pwd )"
cd "${DIR}"
# CONFIG START
ARCH="i686"
PYTHON_VERSION="3"
BUILD_VERSION="0"
# CONFIG END
MISC="${DIR}"/misc
PYTHON_ID="python${PYTHON_VERSION}"
MINGW="mingw32"
QL_VERSION="0.0.0"
QL_VERSION_DESC="UNKNOWN"
function set_build_root {
BUILD_ROOT="$1"
REPO_CLONE="${BUILD_ROOT}/${MINGW}"/gajim
MINGW_ROOT="${BUILD_ROOT}/${MINGW}"
}
set_build_root "${DIR}/_build_root"
function build_pacman {
pacman --root "${BUILD_ROOT}" "$@"
}
function build_pip {
"${BUILD_ROOT}"/"${MINGW}"/bin/"${PYTHON_ID}".exe -m pip "$@"
}
function build_python {
"${BUILD_ROOT}"/"${MINGW}"/bin/"${PYTHON_ID}".exe "$@"
}
function build_compileall {
build_python -m compileall -b "$@"
}
function install_pre_deps {
pacman -S --needed --noconfirm p7zip git \
mingw-w64-"${ARCH}"-nsis wget intltool mingw-w64-"${ARCH}"-toolchain \
mingw-w64-i686-python3
}
function create_root {
mkdir -p "${BUILD_ROOT}"
mkdir -p "${BUILD_ROOT}"/var/lib/pacman
mkdir -p "${BUILD_ROOT}"/var/log
mkdir -p "${BUILD_ROOT}"/tmp
build_pacman -Syu
build_pacman --noconfirm -S base
}
function install_deps {
build_pacman --noconfirm -S mingw-w64-"${ARCH}"-gtk3 mingw-w64-"${ARCH}"-"${PYTHON_ID}" \
mingw-w64-"${ARCH}"-"${PYTHON_ID}"-gobject \
mingw-w64-"${ARCH}"-"${PYTHON_ID}"-pip \
mingw-w64-"${ARCH}"-gstreamer \
mingw-w64-"${ARCH}"-adwaita-icon-theme
build_pip install setuptools_scm
PIP_REQUIREMENTS="\
pyasn1
certifi
git+https://dev.gajim.org/gajim/python-nbxmpp.git
protobuf
git+https://github.com/dlitz/pycrypto.git
cryptography
pyopenssl
python-gnupg
docutils
qrcode
keyring
"
build_pip install --no-binary ":all:" \
--force-reinstall $(echo "$PIP_REQUIREMENTS" | tr ["\\n"] [" "])
build_pip install python-axolotl
build_pacman --noconfirm -Rdd mingw-w64-"${ARCH}"-shared-mime-info \
mingw-w64-"${ARCH}"-"${PYTHON_ID}"-pip mingw-w64-"${ARCH}"-ncurses || true
build_pacman --noconfirm -Rdd mingw-w64-"${ARCH}"-tk || true
build_pacman --noconfirm -Rdd mingw-w64-"${ARCH}"-tcl || true
build_pacman --noconfirm -Rdd mingw-w64-"${ARCH}"-gnome-common || true
build_pacman --noconfirm -Rdd mingw-w64-"${ARCH}"-gsl || true
build_pacman --noconfirm -Rdd mingw-w64-"${ARCH}"-libvpx || true
# remove the large png icons, they should be used rarely and svg works fine
rm -Rf "${MINGW_ROOT}/share/icons/Adwaita/512x512"
rm -Rf "${MINGW_ROOT}/share/icons/Adwaita/256x256"
rm -Rf "${MINGW_ROOT}/share/icons/Adwaita/96x96"
rm -Rf "${MINGW_ROOT}/share/icons/Adwaita/64x64"
rm -Rf "${MINGW_ROOT}/share/icons/Adwaita/48x48"
"${MINGW_ROOT}"/bin/gtk-update-icon-cache-3.0.exe --force \
"${MINGW_ROOT}/share/icons/Adwaita"
}
function install_gajim {
[ -z "$1" ] && (echo "Missing arg"; exit 1)
rm -Rf "${REPO_CLONE}"
git clone "${DIR}"/.. "${REPO_CLONE}"
(cd "${REPO_CLONE}" && git checkout "$1") || exit 1
if [ "$1" = "master" ]
then
local GIT_REV=$(git rev-list --count HEAD)
local GIT_HASH=$(git rev-parse --short HEAD)
QL_VERSION_DESC="QL_VERSION-rev$GIT_REV-$GIT_HASH"
else
QL_VERSION_DESC=$1
QL_VERSION=$1
fi
# Create launchers
build_python "${MISC}"/create-launcher.py \
"${QL_VERSION}" "${MINGW_ROOT}"/bin
# Install plugin installer
wget -P "${REPO_CLONE}/plugins" -c https://ftp.gajim.org/plugins_1/plugin_installer.zip
7z x -o"${REPO_CLONE}"/plugins "${REPO_CLONE}"/plugins/plugin_installer.zip
rm -f "${REPO_CLONE}"/plugins/plugin_installer.zip
# Install themes
rm -Rf "${MINGW_ROOT}"/etc
rm -Rf "${MINGW_ROOT}"/share/themes
mv "${REPO_CLONE}"/win/etc "${MINGW_ROOT}"
mv "${REPO_CLONE}"/win/themes "${MINGW_ROOT}"/share
# Install our own icons
rm -Rf "${MINGW_ROOT}/share/icons/hicolor"
mv "${REPO_CLONE}"/icons/hicolor "${MINGW_ROOT}"/share/icons
# we installed our app icons into hicolor
"${MINGW_ROOT}"/bin/gtk-update-icon-cache-3.0.exe --force \
"${MINGW_ROOT}/share/icons/hicolor"
# Create translation files
for f in "${REPO_CLONE}"/po/*.po; do
fullfilename=$(basename "$f")
filename="${fullfilename%.*}"
directory="${MINGW_ROOT}"/share/locale/"$filename"
if [ ! -d "$directory" ]; then
printf "create dir\n"
mkdir -p "${directory}"/LC_MESSAGES
fi
printf "compile $filename\n"
msgfmt -o "${directory}"/LC_MESSAGES/gajim.mo "$f"
done
}
function cleanup_install {
#delete translations we don't support
for d in "${MINGW_ROOT}"/share/locale/*/LC_MESSAGES; do
if [ ! -f "${d}"/gajim.mo ]; then
rm -Rf "${d}"
fi
done
find "${MINGW_ROOT}" -regextype "posix-extended" -name "*.exe" -a ! \
-iregex ".*/(gajim|python|history_manager)[^/]*\\.exe" \
-exec rm -f {} \;
rm -Rf "${REPO_CLONE}"/.git
rm -Rf "${REPO_CLONE}"/debian
rm -Rf "${REPO_CLONE}"/doc
rm -Rf "${REPO_CLONE}"/m4
rm -Rf "${REPO_CLONE}"/scripts
rm -Rf "${REPO_CLONE}"/test
rm -Rf "${REPO_CLONE}"/win
rm -Rf "${REPO_CLONE}"/icons
rm -Rf "${REPO_CLONE}"/po
rm -Rf "${REPO_CLONE}"/plugins/acronyms_expander
rm -Rf "${REPO_CLONE}"/plugins/dbus_plugin
rm -Rf "${REPO_CLONE}"/plugins/events_dump
rm -Rf "${REPO_CLONE}"/plugins/new_events_example
rm -Rf "${REPO_CLONE}"/plugins/roster_buttons
find "${REPO_CLONE}"/* -maxdepth 0 -type f ! -regex ".*/\(AUTHORS\|COPYING\|THANKS\|THANKS.artists\)" -exec rm -f {} \;
find "${REPO_CLONE}"/data/* -maxdepth 0 -type f -exec rm -f {} \;
rm -Rf "${MINGW_ROOT}"/libexec
rm -Rf "${MINGW_ROOT}"/share/gtk-doc
rm -Rf "${MINGW_ROOT}"/include
rm -Rf "${MINGW_ROOT}"/var
rm -Rf "${MINGW_ROOT}"/share/zsh
rm -Rf "${MINGW_ROOT}"/share/pixmaps
rm -Rf "${MINGW_ROOT}"/share/gnome-shell
rm -Rf "${MINGW_ROOT}"/share/dbus-1
rm -Rf "${MINGW_ROOT}"/share/gir-1.0
rm -Rf "${MINGW_ROOT}"/share/doc
rm -Rf "${MINGW_ROOT}"/share/man
rm -Rf "${MINGW_ROOT}"/share/info
rm -Rf "${MINGW_ROOT}"/share/mime
rm -Rf "${MINGW_ROOT}"/share/gettext
rm -Rf "${MINGW_ROOT}"/share/libtool
rm -Rf "${MINGW_ROOT}"/share/licenses
rm -Rf "${MINGW_ROOT}"/share/appdata
rm -Rf "${MINGW_ROOT}"/share/aclocal
rm -Rf "${MINGW_ROOT}"/share/ffmpeg
rm -Rf "${MINGW_ROOT}"/share/vala
rm -Rf "${MINGW_ROOT}"/share/readline
rm -Rf "${MINGW_ROOT}"/share/xml
rm -Rf "${MINGW_ROOT}"/share/bash-completion
rm -Rf "${MINGW_ROOT}"/share/common-lisp
rm -Rf "${MINGW_ROOT}"/share/emacs
rm -Rf "${MINGW_ROOT}"/share/gdb
rm -Rf "${MINGW_ROOT}"/share/libcaca
rm -Rf "${MINGW_ROOT}"/share/gettext
rm -Rf "${MINGW_ROOT}"/share/gst-plugins-base
rm -Rf "${MINGW_ROOT}"/share/gtk-3.0
rm -Rf "${MINGW_ROOT}"/share/nghttp2
rm -Rf "${MINGW_ROOT}"/share/fontconfig
rm -Rf "${MINGW_ROOT}"/share/gettext-*
rm -Rf "${MINGW_ROOT}"/share/gstreamer-1.0
find "${MINGW_ROOT}"/share/glib-2.0 -type f ! \
-name "*.compiled" -exec rm -f {} \;
rm -Rf "${MINGW_ROOT}"/lib/"${PYTHON_ID}".*/test
rm -Rf "${MINGW_ROOT}"/lib/cmake
rm -Rf "${MINGW_ROOT}"/lib/gettext
rm -Rf "${MINGW_ROOT}"/lib/gtk-3.0
rm -Rf "${MINGW_ROOT}"/lib/mpg123
rm -Rf "${MINGW_ROOT}"/lib/p11-kit
rm -Rf "${MINGW_ROOT}"/lib/ruby
rm -Rf "${MINGW_ROOT}"/lib/tcl8
rm -Rf "${MINGW_ROOT}"/lib/tcl8.6
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstvpx.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstdaala.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstdvdread.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstopenal.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstopenexr.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstopenh264.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstresindvd.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstassrender.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstx265.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstwebp.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstopengl.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstmxf.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstfaac.dll
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstschro.dll
rm -f "${MINGW_ROOT}"/bin/libharfbuzz-icu-0.dll
rm -f "${MINGW_ROOT}"/lib/"${PYTHON_ID}".*/lib-dynload/_tkinter*
rm -f "${MINGW_ROOT}"/lib/gstreamer-1.0/libgstcacasink.dll
rm -Rf "${MINGW_ROOT}"/lib/python2.*
find "${MINGW_ROOT}" -name "*.a" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.whl" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.h" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.la" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.sh" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.jar" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.def" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.cmd" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.cmake" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.pc" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.desktop" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.manifest" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.pyo" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "*.am" -exec rm -f {} \;
find "${MINGW_ROOT}" -name ".gitignore" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "pylint.rc" -exec rm -f {} \;
find "${MINGW_ROOT}"/bin -name "*-config" -exec rm -f {} \;
find "${MINGW_ROOT}"/bin -name "easy_install*" -exec rm -f {} \;
find "${MINGW_ROOT}" -regex ".*/bin/[^.]+" -exec rm -f {} \;
find "${MINGW_ROOT}" -regex ".*/bin/[^.]+\\.[0-9]+" -exec rm -f {} \;
find "${MINGW_ROOT}" -name "gtk30-properties.mo" -exec rm -rf {} \;