mirror of
https://github.com/fuse-friends/fuse-native
synced 2024-10-27 18:34:01 +00:00
use getenv() instead of node -e stuff
This commit is contained in:
parent
cb731824ce
commit
cad433382d
@ -38,8 +38,11 @@ void thread_join (HANDLE thread) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void fusermount (char *path) {
|
void fusermount (char *path) {
|
||||||
|
char* dokanPath = getenv("DOKAN_INSTALL_DIR");
|
||||||
char cmdLine[MAX_PATH];
|
char cmdLine[MAX_PATH];
|
||||||
sprintf(cmdLine, "\"%s/dokanctl.exe\" /u %s", DOKAN_INSTALL_DIR, path);
|
|
||||||
|
if(dokanPath) sprintf(cmdLine, "\"%s/dokanctl.exe\" /u %s", dokanPath, path);
|
||||||
|
else sprintf(cmdLine, "dokanctl.exe /u %s", path);
|
||||||
|
|
||||||
STARTUPINFO info = {sizeof(info)};
|
STARTUPINFO info = {sizeof(info)};
|
||||||
PROCESS_INFORMATION procInfo;
|
PROCESS_INFORMATION procInfo;
|
||||||
|
@ -17,20 +17,13 @@
|
|||||||
}
|
}
|
||||||
}],
|
}],
|
||||||
['OS=="win"', {
|
['OS=="win"', {
|
||||||
"variables": {
|
|
||||||
"dokan_install_path%": "<!(echo %DOKAN_INSTALL_DIR%)"
|
|
||||||
},
|
|
||||||
"defines": [
|
|
||||||
["DOKAN_INSTALL_DIR",
|
|
||||||
"<!(node -e \"process.stdout.write(JSON.stringify(process.argv[1]))\" -- \"<(dokan_install_path)\")"]
|
|
||||||
],
|
|
||||||
"include_dirs": [
|
"include_dirs": [
|
||||||
"$(DOKAN_FUSE_INCLUDE)",
|
"$(DOKAN_FUSE_INCLUDE)",
|
||||||
"$(INCLUDE)"
|
"$(INCLUDE)"
|
||||||
],
|
],
|
||||||
"link_settings": {
|
"link_settings": {
|
||||||
"libraries": [
|
"libraries": [
|
||||||
"<(dokan_install_path)/dokanfuse.lib"
|
"<!(echo %DOKAN_INSTALL_DIR%)/dokanfuse.lib"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}]
|
}]
|
||||||
|
Loading…
Reference in New Issue
Block a user