mirror of
https://github.com/winfsp/winfsp.git
synced 2025-06-08 04:52:10 -05:00
tools: build: create driver.cab for sysdev
This commit is contained in:
parent
52acc3bc48
commit
be98326bbb
@ -196,6 +196,71 @@
|
|||||||
<PreprocessorDefinitions Condition="'$(Configuration)|$(Platform)'=='Release|x64'">_WIN64;_AMD64_=1;AMD64;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions Condition="'$(Configuration)|$(Platform)'=='Release|x64'">_WIN64;_AMD64_=1;AMD64;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<CustomBuild Include="..\..\src\sys\driver.inf.in">
|
||||||
|
<FileType>Document</FileType>
|
||||||
|
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">set DriverFile=$(TargetFileName)
|
||||||
|
set Provider="$(MyCompanyName)"
|
||||||
|
set CatalogFile=driver-$(PlatformTarget).cat
|
||||||
|
|
||||||
|
setlocal EnableDelayedExpansion
|
||||||
|
if exist $(OutDir)driver-$(PlatformTarget).inf del $(OutDir)driver-$(PlatformTarget).inf
|
||||||
|
for /f "delims=" %%l in (%(FullPath)) do (
|
||||||
|
set line=%%l
|
||||||
|
echo !line! >>$(OutDir)driver-$(PlatformTarget).inf
|
||||||
|
)
|
||||||
|
|
||||||
|
stampinf -v $(MyVersion) -f $(OutDir)driver-$(PlatformTarget).inf</Command>
|
||||||
|
<LinkObjects Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">false</LinkObjects>
|
||||||
|
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">set DriverFile=$(TargetFileName)
|
||||||
|
set Provider="$(MyCompanyName)"
|
||||||
|
set CatalogFile=driver-$(PlatformTarget).cat
|
||||||
|
|
||||||
|
setlocal EnableDelayedExpansion
|
||||||
|
if exist $(OutDir)driver-$(PlatformTarget).inf del $(OutDir)driver-$(PlatformTarget).inf
|
||||||
|
for /f "delims=" %%l in (%(FullPath)) do (
|
||||||
|
set line=%%l
|
||||||
|
echo !line! >>$(OutDir)driver-$(PlatformTarget).inf
|
||||||
|
)
|
||||||
|
|
||||||
|
stampinf -v $(MyVersion) -f $(OutDir)driver-$(PlatformTarget).inf</Command>
|
||||||
|
<LinkObjects Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</LinkObjects>
|
||||||
|
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">set DriverFile=$(TargetFileName)
|
||||||
|
set Provider="$(MyCompanyName)"
|
||||||
|
set CatalogFile=driver-$(PlatformTarget).cat
|
||||||
|
|
||||||
|
setlocal EnableDelayedExpansion
|
||||||
|
if exist $(OutDir)driver-$(PlatformTarget).inf del $(OutDir)driver-$(PlatformTarget).inf
|
||||||
|
for /f "delims=" %%l in (%(FullPath)) do (
|
||||||
|
set line=%%l
|
||||||
|
echo !line! >>$(OutDir)driver-$(PlatformTarget).inf
|
||||||
|
)
|
||||||
|
|
||||||
|
stampinf -v $(MyVersion) -f $(OutDir)driver-$(PlatformTarget).inf</Command>
|
||||||
|
<LinkObjects Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">false</LinkObjects>
|
||||||
|
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">set DriverFile=$(TargetFileName)
|
||||||
|
set Provider="$(MyCompanyName)"
|
||||||
|
set CatalogFile=driver-$(PlatformTarget).cat
|
||||||
|
|
||||||
|
setlocal EnableDelayedExpansion
|
||||||
|
if exist $(OutDir)driver-$(PlatformTarget).inf del $(OutDir)driver-$(PlatformTarget).inf
|
||||||
|
for /f "delims=" %%l in (%(FullPath)) do (
|
||||||
|
set line=%%l
|
||||||
|
echo !line! >>$(OutDir)driver-$(PlatformTarget).inf
|
||||||
|
)
|
||||||
|
|
||||||
|
stampinf -v $(MyVersion) -f $(OutDir)driver-$(PlatformTarget).inf</Command>
|
||||||
|
<LinkObjects Condition="'$(Configuration)|$(Platform)'=='Release|x64'">false</LinkObjects>
|
||||||
|
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Writing driver-$(PlatformTarget).inf</Message>
|
||||||
|
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(OutDir)driver-$(PlatformTarget).inf</Outputs>
|
||||||
|
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Writing driver-$(PlatformTarget).inf</Message>
|
||||||
|
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(OutDir)driver-$(PlatformTarget).inf</Outputs>
|
||||||
|
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Writing driver-$(PlatformTarget).inf</Message>
|
||||||
|
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(OutDir)driver-$(PlatformTarget).inf</Outputs>
|
||||||
|
<Message Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Writing driver-$(PlatformTarget).inf</Message>
|
||||||
|
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(OutDir)driver-$(PlatformTarget).inf</Outputs>
|
||||||
|
</CustomBuild>
|
||||||
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||||
<ImportGroup Label="ExtensionTargets">
|
<ImportGroup Label="ExtensionTargets">
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
|
@ -112,4 +112,9 @@
|
|||||||
<Filter>Source</Filter>
|
<Filter>Source</Filter>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<None Include="..\..\src\sys\driver.inf.in">
|
||||||
|
<Filter>Source</Filter>
|
||||||
|
</None>
|
||||||
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
21
src/sys/driver.inf.in
Normal file
21
src/sys/driver.inf.in
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
[Version]
|
||||||
|
Signature = "$WINDOWS NT$"
|
||||||
|
Class = Volume
|
||||||
|
ClassGuid = {71a27cdd-812a-11d0-bec7-08002be2092f}
|
||||||
|
CatalogFile = !CatalogFile!
|
||||||
|
Provider = !Provider!
|
||||||
|
|
||||||
|
[DestinationDirs]
|
||||||
|
DefaultDestDir = 12
|
||||||
|
|
||||||
|
[DefaultInstall]
|
||||||
|
CopyFiles = Driver.CopyFiles
|
||||||
|
|
||||||
|
[Driver.CopyFiles]
|
||||||
|
!DriverFile!
|
||||||
|
|
||||||
|
[SourceDisksFiles]
|
||||||
|
!DriverFile! = 1
|
||||||
|
|
||||||
|
[SourceDisksNames]
|
||||||
|
1 = Disk1
|
@ -28,6 +28,27 @@ for %%f in (build\%Configuration%\winfsp-x64.sys build\%Configuration%\winfsp-x8
|
|||||||
if errorlevel 1 set /a signfail=signfail+1
|
if errorlevel 1 set /a signfail=signfail+1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
pushd build\%Configuration%
|
||||||
|
for %%a in (x64 x86) do (
|
||||||
|
echo .OPTION EXPLICIT >driver-%%a.ddf
|
||||||
|
echo .Set CabinetFileCountThreshold=0 >>driver-%%a.ddf
|
||||||
|
echo .Set FolderFileCountThreshold=0 >>driver-%%a.ddf
|
||||||
|
echo .Set FolderSizeThreshold=0 >>driver-%%a.ddf
|
||||||
|
echo .Set MaxCabinetSize=0 >>driver-%%a.ddf
|
||||||
|
echo .Set MaxDiskFileCount=0 >>driver-%%a.ddf
|
||||||
|
echo .Set MaxDiskSize=0 >>driver-%%a.ddf
|
||||||
|
echo .Set CompressionType=MSZIP >>driver-%%a.ddf
|
||||||
|
echo .Set Cabinet=on >>driver-%%a.ddf
|
||||||
|
echo .Set Compress=on >>driver-%%a.ddf
|
||||||
|
echo .Set CabinetNameTemplate=driver-%%a.cab >>driver-%%a.ddf
|
||||||
|
echo .Set DiskDirectory1=. >>driver-%%a.ddf
|
||||||
|
echo .Set DestinationDir=winfsp >>driver-%%a.ddf
|
||||||
|
echo driver-%%a.inf >>driver-%%a.ddf
|
||||||
|
echo winfsp-%%a.sys >>driver-%%a.ddf
|
||||||
|
makecab /F driver-%%a.ddf
|
||||||
|
)
|
||||||
|
popd
|
||||||
|
|
||||||
devenv winfsp.sln /build "Installer.%Configuration%|x86"
|
devenv winfsp.sln /build "Installer.%Configuration%|x86"
|
||||||
if errorlevel 1 goto fail
|
if errorlevel 1 goto fail
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user