harelba / q

q - Run SQL directly on delimited files and multi-file sqlite databases

Home Page:http://harelba.github.io/q/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cannot run WIndows build

sryze opened this issue · comments

When I run q.exe:

The code execution cannot proceed because python38.dll was not found. Reinstalling the program may fix this problem. 

I expected it to run without requiring any DLLs as mentioend on the website:

q is packaged as a compiled standalone-executable that has no dependencies, not even python itself

Could you please look into linking with Python statically in the Windows build?

Thanks.

The windows build also uses static linking, so this is very odd.

Can you send some details about your windows? Perhaps it will provide a clue as to why it's not working.

Windows 10 x64
Version of q: 3.1.6

It looks like python38.dll was dynamically linked:

image

Accoding to https://pyoxidizer.readthedocs.io/en/stable/pyoxidizer_packaging_static_linking.html#building-statically-linked-binaries-on-windows to produce a statically linked .exe on Windows, it's necessary to add flavor="standalone_static" to this line in pyoxidizer.bzl:

dist = default_python_distribution(python_version=PYTHON_VERSION)

I just tried this and it appears to indeed link with Python statically.

image

The executable is huge though.... about 50 MB now vs 34 MB before.

yes, i remember now... There was an issue with github actions' Windows support which prevent this from working well.

Perhaps now github actions improved their support for this. I'll take a look.

Thanks a lot for checking this out.