Closed geo-y closed 2 years ago
@kody-wen : Thanks for your patch. I agree to get rid of ugly gencat.bat
. However, inf2cat of VS requires too much time to be completed and seems to incur unwanted rebuild. Those unpleasant things are gone with Win11 dev?
And please check that e7b01fe04b1ea52d4e76db0dda3c4d12386e614e has an error.
@kody-wen : Thanks for your patch. I agree to get rid of ugly
gencat.bat
. However, inf2cat of VS requires too much time to be completed and seems to incur unwanted rebuild. Those unpleasant things are gone with Win11 dev? And please check that e7b01fe has an error.
Hi, do you have some logs or screenshots about that error? I would like to help with it.
@kody-wen:
Hi, do you have some logs or screenshots about that error? I would like to help with it.
My build environment is Win10(1903) SDK&WDK 10.0.18362.0, which is older than yours. You can find build error log in my temporary appveyor build. It is the same with my build log.
@kody-wen : Thanks for your new work. In my environment, I succeeded to get the package with single warning of package project. But appveyor has raised error and warnings. Please refer to the build log.
By the way, can you answer my old question?
However, inf2cat of VS requires too much time to be completed and seems to incur unwanted rebuild.
If infcat
is done by VS, build time takes longer than when used by gencat.bat
. Even worse, this delay gets larger when builds are repeated without clean.
There's another problem that VS tries to build even though it has been completed to build. This may be build dependency?
@kody-wen : Please take a look at my old 4c99013a3be15ea5fcb0511aef6929d3dad69c55 for understanding why ugly gencat.bat
. is required. Honestly, I had forgot it. 😭
Time consumption report (Configured VS Build output with Detailed level):
6> C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\Tracker.exe /d "C:\Program Files (x86)\MSBuild\15.0\FileTracker\FileTracker32.dll" /i <Project-Path>\Debug\x64\usbip_vhci_ude\usbip_vhci_ude.tlog /r <PROJECT-PATH>\DEBUG\X64\USBIP_VHCI_UDE\ /b MSBuildConsole_CancelEventb1b5393089284fe8ae09240174251703 /c "C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x86\inf2cat.exe" /os:10_x64 /USELOCALTIME /driver:<Project-Path>\Debug\x64\usbip_vhci_ude\
4> C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\Tracker.exe /d "C:\Program Files (x86)\MSBuild\15.0\FileTracker\FileTracker32.dll" /i <Project-Path>\Debug\x64\usbip_vhci\usbip_vhci.tlog /r <PROJECT-PATH>\DEBUG\X64\USBIP_VHCI\ /b MSBuildConsole_CancelEvent56612994ab3e4bb192213e6b814d1650 /c "C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x86\inf2cat.exe" /os:10_x64 /USELOCALTIME /driver:<Project-Path>\Debug\x64\usbip_vhci\
(Long time...)
6> Signability test complete.
(Long time...)
4> Signability test complete.
When build Debug mode, each Signability test toke minutes. When build Release mode, it would be very fast to finish the building process. The difference may be related to "Wpp Tracing".
@kody-wen : Thanks for your great commits.
There were a few build errors in my build environment(SDK 18362), which are due to a SDK(18362) bug. Of course, Appveyor build was OK. So, I'm downloading an up-to-date VS and SDK to check your PR.
By the way, your commits seem to be better if they are split into smaller ones. For example, removing unnecessary files such as cscope.out
would be deserved to be a single commit.
@kody-wen :
From your comment, I realized the exact cause of terrible delay when using VS infcat.
VS infcat generates a new tlog file at every build and thus there are plenty of infcat tlogs.
So it takes too long for tracker.exe
to search build dependecies.
Before introducing gencat.bat
, I used to clean a project for a workaround. :cry:
Time consumption report (Configured VS Build output with Detailed level):
6> C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\Tracker.exe /d "C:\Program Files (x86)\MSBuild\15.0\FileTracker\FileTracker32.dll" /i <Project-Path>\Debug\x64\usbip_vhci_ude\usbip_vhci_ude.tlog /r <PROJECT-PATH>\DEBUG\X64\USBIP_VHCI_UDE\ /b MSBuildConsole_CancelEventb1b5393089284fe8ae09240174251703 /c "C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x86\inf2cat.exe" /os:10_x64 /USELOCALTIME /driver:<Project-Path>\Debug\x64\usbip_vhci_ude\ 4> C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\Tracker.exe /d "C:\Program Files (x86)\MSBuild\15.0\FileTracker\FileTracker32.dll" /i <Project-Path>\Debug\x64\usbip_vhci\usbip_vhci.tlog /r <PROJECT-PATH>\DEBUG\X64\USBIP_VHCI\ /b MSBuildConsole_CancelEvent56612994ab3e4bb192213e6b814d1650 /c "C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x86\inf2cat.exe" /os:10_x64 /USELOCALTIME /driver:<Project-Path>\Debug\x64\usbip_vhci\ (Long time...) 6> Signability test complete. (Long time...) 4> Signability test complete.
When build Debug mode, each Signability test toke minutes. When build Release mode, it would be very fast to finish the building process. The difference may be related to "Wpp Tracing".
@kody-wen : From your comment, I realized the exact cause of terrible delay when using VS infcat. VS infcat generates a new tlog file at every build and thus there are plenty of infcat tlogs. So it takes too long for
tracker.exe
to search build dependecies. Before introducinggencat.bat
, I used to clean a project for a workaround. 😢Time consumption report (Configured VS Build output with Detailed level):
6> C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\Tracker.exe /d "C:\Program Files (x86)\MSBuild\15.0\FileTracker\FileTracker32.dll" /i <Project-Path>\Debug\x64\usbip_vhci_ude\usbip_vhci_ude.tlog /r <PROJECT-PATH>\DEBUG\X64\USBIP_VHCI_UDE\ /b MSBuildConsole_CancelEventb1b5393089284fe8ae09240174251703 /c "C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x86\inf2cat.exe" /os:10_x64 /USELOCALTIME /driver:<Project-Path>\Debug\x64\usbip_vhci_ude\ 4> C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\Tracker.exe /d "C:\Program Files (x86)\MSBuild\15.0\FileTracker\FileTracker32.dll" /i <Project-Path>\Debug\x64\usbip_vhci\usbip_vhci.tlog /r <PROJECT-PATH>\DEBUG\X64\USBIP_VHCI\ /b MSBuildConsole_CancelEvent56612994ab3e4bb192213e6b814d1650 /c "C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x86\inf2cat.exe" /os:10_x64 /USELOCALTIME /driver:<Project-Path>\Debug\x64\usbip_vhci\ (Long time...) 6> Signability test complete. (Long time...) 4> Signability test complete.
When build Debug mode, each Signability test toke minutes. When build Release mode, it would be very fast to finish the building process. The difference may be related to "Wpp Tracing".
"Rebuild" is easy for this🤣
@kody-wen : I have created kody-temp branch which accepted selectively this PR. Those commits on the branch had been cherry-picked into the dev
branch. I'm sorry about that all your works can't be merged.
Followings are dropped your works:
No probleam. Should we close this PR now?
@kody-f : Great thanks..
Visual Studio 2019 16.11.11, Windows 11 22000.527, SDK 22000. Building for Win32/x64/ARM64 verified. No new feature added.
Functional test:
New vcxproj files:
Common configuration had been extracted into props files.
All the userspace projects had been converted into usb-driver-application which follow the official usb-application template.
To support different targets, properties in visual studio should be edited multiple times. And common settings are hard to synchronized.
"props" files make this easy. (https://docs.microsoft.com/en-us/cpp/build/reference/vcxproj-file-structure?view=msvc-170)
Package project:
Added package project which bring all needed binary files into one folder. Distribution would be very easy.
It is from visual studio driver package template which is common in some driver projects.
(https://github.com/microsoft/Windows-driver-samples/blob/master/audio/simpleaudiosample/Package/package.VcxProj)
Build targets:
Appveyor calls the
msbuild.rsp
which would build x64-release version.Build different target can do like this:
Build offline with test certificate: