diff options
author | Simon Rozman <simon@rozman.si> | 2019-04-26 11:26:59 +0200 |
---|---|---|
committer | Simon Rozman <simon@rozman.si> | 2019-04-26 13:44:44 +0200 |
commit | 5094737f8cddab65bd171a5b687b211a1822fed0 (patch) | |
tree | 74ed255c447a12de4f808d6a40723ea9769ac2d1 | |
parent | Quote platform names (diff) | |
download | wintun-5094737f8cddab65bd171a5b687b211a1822fed0.tar.xz wintun-5094737f8cddab65bd171a5b687b211a1822fed0.zip |
Split driver setup to EV signed (<Win10) and WHQL signed (>=Win10)
Signed-off-by: Simon Rozman <simon@rozman.si>
-rw-r--r-- | .gitignore | 4 | ||||
-rw-r--r-- | README.md | 10 | ||||
-rw-r--r-- | wintun.proj | 4 | ||||
-rw-r--r-- | wintun.wixproj | 3 | ||||
-rw-r--r-- | wintun.wxs | 29 |
5 files changed, 46 insertions, 4 deletions
@@ -18,3 +18,7 @@ # Driver Verification Log /wintun.DVL.XML + +# WHQL Driver +/whql/x86 +/whql/amd64 @@ -53,7 +53,7 @@ msbuild wintun.proj [/t:<target>] - `DVL`: Runs the `SDV`, and creates a Driver Verification Log, only for AMD64 release configurations. - - `MSM`: Builds Microsoft Installer Merge Modules in `<output folder>\wintun-<platform>-<version>.msm`. + - `MSM`: Builds Microsoft Installer Merge Modules in `<output folder>\wintun-<platform>-<version>.msm`. Requires WHLK signed driver (See: [Building Microsoft Installer Merge Modules]). The driver output folders are: @@ -66,6 +66,14 @@ AMD64 Release | `amd64\Release\wintun` ARM64 Debug | `arm64\Debug\wintun` ARM64 Release | `arm64\Release\wintun` +### Building Microsoft Installer Merge Modules + +1. `msbuild wintun.proj /t:DVL;Build` +2. Perform Windows Hardware Lab Kit tests; Submit submission package to Microsoft; Get WHQL signed driver. +3. Copy WHQL signed driver to `whql\x86` and `whql\amd64` subfolders. +4. `msbuild wintun.proj /t:MSM` +5. MSM files are placed in `dist` subfolder. + ## Usage diff --git a/wintun.proj b/wintun.proj index 45faaa1..bd4a32c 100644 --- a/wintun.proj +++ b/wintun.proj @@ -63,10 +63,10 @@ <!-- MSM Building --> - <Target Name="MSM-x86" DependsOnTargets="Build" Outputs="$(DistributionDir)wintun-x86-$(WintunVersionStr).msm"> + <Target Name="MSM-x86" Outputs="$(DistributionDir)wintun-x86-$(WintunVersionStr).msm"> <MSBuild Projects="wintun.wixproj" Targets="Build" Properties="Configuration=Release;Platform=x86"/> </Target> - <Target Name="MSM-amd64" DependsOnTargets="Build" Outputs="$(DistributionDir)wintun-amd64-$(WintunVersionStr).msm"> + <Target Name="MSM-amd64" Outputs="$(DistributionDir)wintun-amd64-$(WintunVersionStr).msm"> <MSBuild Projects="wintun.wixproj" Targets="Build" Properties="Configuration=Release;Platform=x64"/> </Target> </Project> diff --git a/wintun.wixproj b/wintun.wixproj index 25ddfdf..8474034 100644 --- a/wintun.wixproj +++ b/wintun.wixproj @@ -27,7 +27,8 @@ <DefineConstants>WINTUN_VERSION=$(WintunVersion);$(DefineConstants)</DefineConstants> <SuppressSpecificWarnings>1006;1086;$(SuppressSpecificWarnings)</SuppressSpecificWarnings> <LinkerSuppressSpecificWarnings>1103;$(LinkerSuppressSpecificWarnings)</LinkerSuppressSpecificWarnings> - <LinkerAdditionalOptions>-b output_dir="$(IntermediateOutputPath.TrimEnd('\'))" $(LinkerAdditionalOptions)</LinkerAdditionalOptions> + <SuppressIces>ICE30;$(SuppressIces)</SuppressIces> + <LinkerAdditionalOptions>-b output_dir="$(IntermediateOutputPath.TrimEnd('\'))" -b whwl_dir="whql\$(WintunPlatform)" $(LinkerAdditionalOptions)</LinkerAdditionalOptions> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)'=='Release'"> <SuppressPdbOutput>true</SuppressPdbOutput> @@ -25,9 +25,26 @@ <Binary Id="wintun.cer" SourceFile="!(bindpath.output_dir)wintun.cer"/> + <Property Id="WINDOWS10_VER_MAJ"> + <RegistrySearch Id="Windows10VersionMaj" Root="HKLM" Key="SOFTWARE\Microsoft\Windows NT\CurrentVersion" Name="CurrentMajorVersionNumber" Type="raw"/> + </Property> + <Directory Id="TARGETDIR" Name="SourceDir"> <Directory Id="WintunFolder"> + <Component Id="wintun.cat.whql" Guid="2f17bc6d-0006-47c4-8ba3-f055d1852558"> + <Condition><![CDATA[WINDOWS10_VER_MAJ]]></Condition> + <File + Id="wintun.cat.whql" + Name="wintun.cat" + Source="!(bindpath.whwl_dir)wintun.cat" + DefaultVersion="$(var.WINTUN_VERSION)" + DefaultLanguage="0"/> + <diffx:Driver + AddRemovePrograms="no" + PlugAndPlayPrompt="no"/> + </Component> <Component Id="wintun.cat" Guid="41fbe711-a1af-4b83-8b5d-fc1b112969c1"> + <Condition><![CDATA[NOT WINDOWS10_VER_MAJ]]></Condition> <File Id="wintun.cat" Name="wintun.cat" @@ -45,6 +62,7 @@ AddRemovePrograms="no" PlugAndPlayPrompt="no"/> </Component> + <Component Id="wintun.inf" Guid="c58122b3-c7ba-4207-b68d-a236e371f9ed"> <File Id="wintun.inf" @@ -53,7 +71,18 @@ DefaultVersion="$(var.WINTUN_VERSION)" DefaultLanguage="0"/> </Component> + + <Component Id="wintun.sys.whql" Guid="039baa6d-b16b-4dc2-8b86-8bb500f78de0"> + <Condition><![CDATA[WINDOWS10_VER_MAJ]]></Condition> + <File + Id="wintun.sys.whql" + Name="wintun.sys" + Source="!(bindpath.whwl_dir)wintun.sys" + DefaultVersion="$(var.WINTUN_VERSION)" + DefaultLanguage="0"/> + </Component> <Component Id="wintun.sys" Guid="d0fde4a4-d228-4803-b57e-76bd8b16cf42"> + <Condition><![CDATA[NOT WINDOWS10_VER_MAJ]]></Condition> <File Id="wintun.sys" Name="wintun.sys" |