How to build Windows Tryton Client?

For me, it is just a matter of changing python2 by python3 and we can use last version of cx_Freeze from pacman.

Thanks ced,

I’m able to build the new windows client.
Apparently, pygtk2 is not needed anymore.

once i run

sh make-win32-installer.sh
``` on my msys2 i get this error
usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
   or: setup.py --help [cmd1 cmd2 ...]
   or: setup.py --help-commands
   or: setup.py cmd --help

error: invalid command 'compile_catalog'

You are missing Babel.

new error
running compile_catalog
compiling catalog tryton/data/locale/bg/LC_MESSAGES/tryton.po to tryton/data/locale/bg/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ca/LC_MESSAGES/tryton.po to tryton/data/locale/ca/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/cs/LC_MESSAGES/tryton.po to tryton/data/locale/cs/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/de/LC_MESSAGES/tryton.po to tryton/data/locale/de/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/es/LC_MESSAGES/tryton.po to tryton/data/locale/es/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/es_419/LC_MESSAGES/tryton.po to tryton/data/locale/es_419/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/fa/LC_MESSAGES/tryton.po to tryton/data/locale/fa/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/fr/LC_MESSAGES/tryton.po to tryton/data/locale/fr/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/hu_HU/LC_MESSAGES/tryton.po to tryton/data/locale/hu_HU/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/it_IT/LC_MESSAGES/tryton.po to tryton/data/locale/it_IT/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ja_JP/LC_MESSAGES/tryton.po to tryton/data/locale/ja_JP/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/lo/LC_MESSAGES/tryton.po to tryton/data/locale/lo/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/lt/LC_MESSAGES/tryton.po to tryton/data/locale/lt/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/nl/LC_MESSAGES/tryton.po to tryton/data/locale/nl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/pl/LC_MESSAGES/tryton.po to tryton/data/locale/pl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/pt_BR/LC_MESSAGES/tryton.po to tryton/data/locale/pt_BR/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ru/LC_MESSAGES/tryton.po to tryton/data/locale/ru/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/sl/LC_MESSAGES/tryton.po to tryton/data/locale/sl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/zh_CN/LC_MESSAGES/tryton.po to tryton/data/locale/zh_CN/LC_MESSAGES/tryton.mo
Traceback (most recent call last):
File “setup-freeze.py”, line 5, in
import user
ModuleNotFoundError: No module named ‘user’

It looks like you are building with Python3 a version prior to 5.0 which does not support without tryton: ab5658e40e22
The user module was used to load ~/.pythonrc.py to setup custom environment variables.

now this
running compile_catalog
compiling catalog tryton/data/locale/bg/LC_MESSAGES/tryton.po to tryton/data/locale/bg/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ca/LC_MESSAGES/tryton.po to tryton/data/locale/ca/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/cs/LC_MESSAGES/tryton.po to tryton/data/locale/cs/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/de/LC_MESSAGES/tryton.po to tryton/data/locale/de/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/es/LC_MESSAGES/tryton.po to tryton/data/locale/es/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/es_419/LC_MESSAGES/tryton.po to tryton/data/locale/es_419/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/fa/LC_MESSAGES/tryton.po to tryton/data/locale/fa/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/fr/LC_MESSAGES/tryton.po to tryton/data/locale/fr/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/hu_HU/LC_MESSAGES/tryton.po to tryton/data/locale/hu_HU/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/it_IT/LC_MESSAGES/tryton.po to tryton/data/locale/it_IT/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ja_JP/LC_MESSAGES/tryton.po to tryton/data/locale/ja_JP/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/lo/LC_MESSAGES/tryton.po to tryton/data/locale/lo/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/lt/LC_MESSAGES/tryton.po to tryton/data/locale/lt/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/nl/LC_MESSAGES/tryton.po to tryton/data/locale/nl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/pl/LC_MESSAGES/tryton.po to tryton/data/locale/pl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/pt_BR/LC_MESSAGES/tryton.po to tryton/data/locale/pt_BR/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ru/LC_MESSAGES/tryton.po to tryton/data/locale/ru/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/sl/LC_MESSAGES/tryton.po to tryton/data/locale/sl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/zh_CN/LC_MESSAGES/tryton.po to tryton/data/locale/zh_CN/LC_MESSAGES/tryton.mo
Traceback (most recent call last):
File “setup-freeze.py”, line 8, in
from cx_Freeze import setup, Executable
ModuleNotFoundError: No module named ‘cx_Freeze’

Well the error message is pretty obvious, isn’t it?

no cx_freeze i think

Traceback (most recent call last):
File “setup-freeze.py”, line 37, in
raise Exception(’%s not found’ % dll)
Exception: librsvg-2-2.dll not found

Added to How to build Windows Tryton Client? librsvg.

after building i tried to build with 5.0.4
i got this
$ sh make-win32-installer.sh
running compile_catalog
compiling catalog tryton/data/locale/bg/LC_MESSAGES/tryton.po to tryton/data/locale/bg/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ca/LC_MESSAGES/tryton.po to tryton/data/locale/ca/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/cs/LC_MESSAGES/tryton.po to tryton/data/locale/cs/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/de/LC_MESSAGES/tryton.po to tryton/data/locale/de/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/es/LC_MESSAGES/tryton.po to tryton/data/locale/es/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/es_419/LC_MESSAGES/tryton.po to tryton/data/locale/es_419/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/fa/LC_MESSAGES/tryton.po to tryton/data/locale/fa/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/fr/LC_MESSAGES/tryton.po to tryton/data/locale/fr/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/hu_HU/LC_MESSAGES/tryton.po to tryton/data/locale/hu_HU/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/it_IT/LC_MESSAGES/tryton.po to tryton/data/locale/it_IT/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ja_JP/LC_MESSAGES/tryton.po to tryton/data/locale/ja_JP/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/lo/LC_MESSAGES/tryton.po to tryton/data/locale/lo/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/lt/LC_MESSAGES/tryton.po to tryton/data/locale/lt/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/nl/LC_MESSAGES/tryton.po to tryton/data/locale/nl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/pl/LC_MESSAGES/tryton.po to tryton/data/locale/pl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/pt_BR/LC_MESSAGES/tryton.po to tryton/data/locale/pt_BR/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ru/LC_MESSAGES/tryton.po to tryton/data/locale/ru/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/sl/LC_MESSAGES/tryton.po to tryton/data/locale/sl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/zh_CN/LC_MESSAGES/tryton.po to tryton/data/locale/zh_CN/LC_MESSAGES/tryton.mo
Traceback (most recent call last):
File “./setup-freeze.py”, line 75, in
with open(gir_file, ‘r’, encoding=‘utf-8’) as src:
FileNotFoundError: [Errno 2] No such file or directory: ‘/usr/share/gir-1.0/Atk-1.0.gir’

Looks like you did not install mingw-w64-i686-atk

ok thanks i have compile it and working sorry to ask again can i use a trytond server of 4.6 to run 5.0 client

A post was split to a new topic: Can I use a trytond server of 4.6 to run 5.0 client

This currently  fails with  the error tlib\scripts.py", line 245, in _write_script
    launcher = self._get_launcher('t')
  File "WindowsUser\AppData\Local\Temp\tmpikvxt9i4\pip.zip\pip\_vendor\distlib\scripts.py", line 384, in _get_launcher
    result = finder(distlib_package).find(name).bytes
AttributeError: 'NoneType' object has no attribute 'bytes'

Solution was to use pacman -S python3-pip which installs python 3.7 and pip Note this is if you are building for the 5.0 and above

running compile_catalog
compiling catalog tryton/data/locale/bg/LC_MESSAGES/tryton.po to tryton/data/locale/bg/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ca/LC_MESSAGES/tryton.po to tryton/data/locale/ca/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/cs/LC_MESSAGES/tryton.po to tryton/data/locale/cs/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/de/LC_MESSAGES/tryton.po to tryton/data/locale/de/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/es/LC_MESSAGES/tryton.po to tryton/data/locale/es/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/es_419/LC_MESSAGES/tryton.po to tryton/data/locale/es_419/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/fa/LC_MESSAGES/tryton.po to tryton/data/locale/fa/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/fr/LC_MESSAGES/tryton.po to tryton/data/locale/fr/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/hu_HU/LC_MESSAGES/tryton.po to tryton/data/locale/hu_HU/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/it_IT/LC_MESSAGES/tryton.po to tryton/data/locale/it_IT/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ja_JP/LC_MESSAGES/tryton.po to tryton/data/locale/ja_JP/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/lo/LC_MESSAGES/tryton.po to tryton/data/locale/lo/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/lt/LC_MESSAGES/tryton.po to tryton/data/locale/lt/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/nl/LC_MESSAGES/tryton.po to tryton/data/locale/nl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/pl/LC_MESSAGES/tryton.po to tryton/data/locale/pl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/pt_BR/LC_MESSAGES/tryton.po to tryton/data/locale/pt_BR/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/ru/LC_MESSAGES/tryton.po to tryton/data/locale/ru/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/sl/LC_MESSAGES/tryton.po to tryton/data/locale/sl/LC_MESSAGES/tryton.mo
compiling catalog tryton/data/locale/zh_CN/LC_MESSAGES/tryton.po to tryton/data/locale/zh_CN/LC_MESSAGES/tryton.mo
Traceback (most recent call last):
File “./setup-freeze.py”, line 82, in
check_call([‘g-ir-compiler’, ‘–output=’ + typefile_tmp, gir_tmp])
File “/usr/lib/python3.7/subprocess.py”, line 342, in check_call
retcode = call(*popenargs, **kwargs)
File “/usr/lib/python3.7/subprocess.py”, line 323, in call
with Popen(*popenargs, **kwargs) as p:
File “/usr/lib/python3.7/subprocess.py”, line 775, in init
restore_signals, start_new_session)
File “/usr/lib/python3.7/subprocess.py”, line 1522, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: ‘g-ir-compiler’: ‘g-ir-compiler’

You must have g-ir-compiler in your $PATH. It comes with gobject-introspection.

you mean at my windows environment path

We use msys32 so it is in the msys32 shell PATH.