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

How to customize dokan1.dll dependencies? #4

Open
834772509 opened this issue Apr 8, 2022 · 3 comments
Open

How to customize dokan1.dll dependencies? #4

834772509 opened this issue Apr 8, 2022 · 3 comments

Comments

@834772509
Copy link

I tried to embed Dokany into my application, but after importing "dokan-rust", the program will forcefully request "dokan1.dll", and the main() entry is not executed, so the dll cannot be released in the main() function, is there any How to customize the dependencies of "dokan1.dll"?

@Liryna
Copy link
Member

Liryna commented Apr 8, 2022

dokan1.dll dependence cannot be customized but you could dynamically import dokan-rust when needed so that dokan1.dll is only requested when you know it is available to your app.

@834772509
Copy link
Author

How to dynamically import dokan-rust? I tried to extract the relevant code using dokan to a location other than main, but it still doesn't work, it seems that as long as the relevant code using dokan is used in the program, dokan1.dll will be requested.

@Liryna
Copy link
Member

Liryna commented Apr 8, 2022

I don't have rust knowledge to provide guidance sorry but I imagine you will need to dynamically load dokan-rust library by using rust standard API and therefore not directly link with it. There must be some examples on stackoverflow to do that.

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