cx_Freeze - The appdirs package is required

I was having the same problem.. Add options parameter to the setup.py file like this:

setup (name="MyAPP",
       version="0.1",
       description = "My GUI application!",
       options = {'build_exe': {'packages':packages}},
       .
       .
       .)

under packages put(packages should come before the setup):

packages = ['pkg_resources._vendor']

(you can add more packages if you have similar problems like this one..)

you can read more on the options here: http://cx-freeze.readthedocs.io/en/latest/distutils.html#build-exe

This solved the problem for me!



I had the same problem. Just add the packages to the options

additional_mods = ['appdirs', 'packaging.version']
additional_packages = ['scipy', 'numpy', 'appdirs', 'packaging']

options = {
        'build_exe': {
                      'packages': additional_packages,
                      'includes': additional_mods,
        }