Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

api-ms-win-crt-multibyte-l1-1-0.dll not found #5

Closed
fredrikaverpil opened this issue Jan 3, 2018 · 6 comments
Closed

api-ms-win-crt-multibyte-l1-1-0.dll not found #5

fredrikaverpil opened this issue Jan 3, 2018 · 6 comments

Comments

@fredrikaverpil
Copy link
Contributor

fredrikaverpil commented Jan 3, 2018

My freeze fail on Windows 10 since the api-ms-win-crt-multibyte-l1-1-0.dll file is not found:

(pyqt5_py35) C:\Users\iruser\code\repos\fbs-tutorial>python -m fbs freeze
Could not remove file: [WinError 2] The system cannot find the file specified: 'C:\\Users\\iruser\\code\\repos\\fbs-tutorial\\target\\Tutorial\\python3.dll'
Traceback (most recent call last):
  File "C:\Users\iruser\AppData\Local\conda\conda\envs\pyqt5_py35\lib\runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "C:\Users\iruser\AppData\Local\conda\conda\envs\pyqt5_py35\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Users\iruser\AppData\Local\conda\conda\envs\pyqt5_py35\lib\site-packages\fbs\__main__.py", line 4, in <module>
    main()
  File "C:\Users\iruser\AppData\Local\conda\conda\envs\pyqt5_py35\lib\site-packages\fbs\cmdline.py", line 17, in main
    args.cmd()
  File "C:\Users\iruser\AppData\Local\conda\conda\envs\pyqt5_py35\lib\site-packages\fbs\builtin_commands.py", line 35, in freeze
    freeze_windows()
  File "C:\Users\iruser\AppData\Local\conda\conda\envs\pyqt5_py35\lib\site-packages\fbs\freeze\windows.py", line 29, in freeze_windows
    _add_missing_dlls()
  File "C:\Users\iruser\AppData\Local\conda\conda\envs\pyqt5_py35\lib\site-packages\fbs\freeze\windows.py", line 37, in _add_missing_dlls
    copy(join(r'c:\Windows\System32', dll), path('${freeze_dir}'))
  File "C:\Users\iruser\AppData\Local\conda\conda\envs\pyqt5_py35\lib\shutil.py", line 241, in copy
    copyfile(src, dst, follow_symlinks=follow_symlinks)
  File "C:\Users\iruser\AppData\Local\conda\conda\envs\pyqt5_py35\lib\shutil.py", line 120, in copyfile
    with open(src, 'rb') as fsrc:
FileNotFoundError: [Errno 2] No such file or directory: 'c:\\Windows\\System32\\api-ms-win-crt-multibyte-l1-1-0.dll'

I can see that the file indeed exists within the target\Tutorial folder.

@fredrikaverpil
Copy link
Contributor Author

Can we just print the error instead of halting?

		try:
			copy(join(r'c:\Windows\System32', dll), path('${freeze_dir}'))
		except FileNotFoundError as error:
			print('Could not copy file:', error)

@fredrikaverpil fredrikaverpil changed the title api-ms-win-crt-multibyte-l1-1-0.dll missing api-ms-win-crt-multibyte-l1-1-0.dll not found Jan 3, 2018
@mherrmann
Copy link
Owner

By "I can see that the file indeed exists within the target\Tutorial folder." you mean that target\Tutorial\api-ms-win-crt-multibyte-l1-1-0.dll exists for you even though you apparently don't have it in C:\Windows\System32?

The file is needed to avoid fman-users/fman/issues/126 on some users' system.

@fredrikaverpil
Copy link
Contributor Author

fredrikaverpil commented Jan 3, 2018

you mean that target\Tutorial\api-ms-win-crt-multibyte-l1-1-0.dll exists

Correct. It exists in the target\Tutorial folder.

The copy command fails as the file is not found in C:\Windows\System32, hence the error:

FileNotFoundError: [Errno 2] No such file or directory: 'c:\\Windows\\System32\\api-ms-win-crt-multibyte-l1-1-0.dll'

Something else is copying that file into the target dir...?

@mherrmann
Copy link
Owner

PyInstaller probably! I just committed 30d284c. Can you let me know whether it fixes the problem?

@fredrikaverpil
Copy link
Contributor Author

Yes, thanks - works great!

@mherrmann
Copy link
Owner

Cool!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants