-
Notifications
You must be signed in to change notification settings - Fork 8k
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
add support for Windows PowerShell #7702
Conversation
… not running in a shell
@AlexeyAB the improved build script should answer your two main points:
|
@cenit Hi, Thanks! Yes, now the installation process goes on, but at some point the window closed and I cannot find the darknet.exe file. |
can you please re-run build script from a powershell already opened? |
i also need those files from your pc C:\Users\HP\Desktop\Projects\yolo_test2\f4e21bd86985adb5da265e493eb512abe0381e7c\darknet-f4e21bd86985adb5da265e493eb512abe0381e7c\vcpkg\buildtrees\protobuf\install-x64-windows-dbg-err.log C:\Users\HP\Desktop\Projects\yolo_test2\f4e21bd86985adb5da265e493eb512abe0381e7c\darknet-f4e21bd86985adb5da265e493eb512abe0381e7c\vcpkg\buildtrees\protobuf\install-x64-windows-dbg-out.log |
@cenit install-x64-windows-dbg-out.log is empty |
error: Filename longer than 260 characters please run build.ps1 from a shorter folder, maybe just c:\darknet i will add a diagnostics at the beginning and warn users in case something like your problem happens, hinting also a solution |
@AlexeyAB please try the new version. It should alert you when path is too long. And as the previous one should work ok if the path is shorter (please try something c:\darknet as i was saying) |
Thanks, now it works well
Now it gives out warning even for a not long path, which is very often used
|
glad to hear that :)
i put a very conservative length. Better safe than sorry. We can test "how big" we can go without breaking everything
this is a windows problem. Traditionally paths on windows have a maximum length of 255 chars. Windows 10 can go beyond that but to maintain compatibility it is still hidden. No ninja problem, just a windows terrible heritage
nope. you have to live with it. It's being worked on in windows, but backwards compatibility is making it very complicated
CI is already using build.ps1 in all its tests. The fact is that interactivity is not permitted on CI, so build.ps1 is always called with the -DisableInteractive parameter
to build opencv+ffmpeg with a reasonable amount of features you need all of those dependencies |
if you meant testing older powershell in CI, that's a little bit more difficult, because github actions tends to live bleeding edge and so they have PowerShell 7 on all instances... |
@cenit Ok, thanks! Also what are the main differences/similarities/advantages of |
also, we do not decide anything about those dependencies. The opencv portfile contains all those informations about how to build it properly from sources. They might change in future but we will not have to change anything on our side |
conda and pip are not meant for c/c++. with a single command you can install any library on any os. we use vcpkg to serve our dependencies, but users can use vcpkg to get darknet too (in that case it is not always the latest version, it is updated whenever i do a new release there - pointing to a newer commit from your repo of course). by the way, why you do not use PRs yourself when pushing to your repo? i know it might sound strange to you, but please try it, you will find that it makes work smoother and easier. You can merge your own PR at the end when you feel safe about it |
Yes, I know, that the best way is to use separate branches and Merge/do PR when it is stable ) Yes, I think it can be better for public project with big community. Just they said about conda https://docs.conda.io/en/latest/
|
i do not know any real world example that uses conda to guide users to build the project from sources. only vcpkg or conan (or they just give up and list you dependencies to have to build the code) |
this does not look like latest commit, so yes updating is for sure beneficial. |
* add support for powershell v5 * revert opencv enabled on osx * improve error handling in initial stages * intercept failures also when updating darknet sources themselves * press a key before exiting script, to preserve console host window if not running in a shell * check path length
I might have found what failed on your system @AlexeyAB . I tried build.ps1 script only on PowerShell v6 and v7, on v5 it was failing.
Is it better now? Can you please test the script as before?