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

python3.9: has_function not working for Visual Studio 2017 build #165

Open
joachimmetz opened this issue Jan 31, 2021 · 1 comment
Open

Comments

@joachimmetz
Copy link
Contributor

joachimmetz commented Jan 31, 2021

Mainly informational

Tested with yara-python 4.0.4 and Python 3.9 on Windows 10 with Visual Studio 2017

Running: python.exe setup.py build fails with error: [WinError 1] Incorrect function

Unfortunately this appears to be a very generic error. Seeing the previous line reference memmem%RANDOM%.c this is likely related to the use of memmem. The same applies to strlcpy.

Removing memmem and strlcpy detection from setup.py

if has_function('memmem'):
resolves the issue.

@joachimmetz
Copy link
Contributor Author

joachimmetz commented Jan 31, 2021

This also applies to more functions it looks like has_function is not working for this build environment. I've removed with muted from has_function which allowed the module to build.

@joachimmetz joachimmetz changed the title python3.9: memmem and strlcpy fail to build with Visual Studio 2017 python3.9: has_function not working for Visual Studio 2017 build Jan 31, 2021
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

1 participant