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

Changes to support linking dokany 2 DLL #8

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

herosi
Copy link

@herosi herosi commented May 16, 2024

Recent dokany repository creates dokan2.lib instead of dokan1.lib. Therefore, even if I use the --with-dokany option, the compilation failed with the link error (LNK1181) like below.

The command I used.

powershell -exec bypass .\build.ps1 -PythonPath "$env:localappdata\Programs\Python\Python312" -VSToolsOptions "--extend-with-x64` --with-dokany` --python-path` $env:localappdata\Programs\Python\Python312" -Platform x64

The failed log related to linking dokan1.lib.

LINK : fatal error LNK1181: cannot open input file '..\..\..\dokany\dokan\x64\Release\dokan1.lib' [E:\devel\libyal\libewf_test\libewf\vs2022\ewfmount\ewfmount.vcxproj]

So I modified vstools to support dokany v2 by changing the variable type bool to int for the --with-dokany option.
If you want to use the latest dokany repository, which is taken by syncdokan.ps1, you can add the option with a version number like "--with-dokany 2".

powershell -exec bypass .\build.ps1 -PythonPath "$env:localappdata\Programs\Python\Python312" -VSToolsOptions "--extend-with-x64` --with-dokany` 2` --python-path` $env:localappdata\Programs\Python\Python312" -Platform x64

@herosi
Copy link
Author

herosi commented May 16, 2024

dokan2

@herosi
Copy link
Author

herosi commented May 16, 2024

By the way, I used libewf for the compilation above with build.ps1 with VS2022.

@joachimmetz
Copy link
Member

Thanks for the suggested changes, I'll have a look when time permits.

Note that both DokanY version 2 support and build.ps1 are WIP.

@joachimmetz joachimmetz changed the title Supported DokanY v2 Changes to support linking dokany 2 DLL May 17, 2024
@herosi
Copy link
Author

herosi commented May 19, 2024

I got it. Thank you for your effort!

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

Successfully merging this pull request may close these issues.

2 participants