Skip to content

Commit 9af40d9

Browse files
authored
Merge pull request #14 from compnerd/icu
Windows: add ICU packaging rules
2 parents 45b5daf + 1564722 commit 9af40d9

File tree

2 files changed

+81
-0
lines changed

2 files changed

+81
-0
lines changed

icu.wixproj

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003" DefaultTargets="Build">
3+
<PropertyGroup>
4+
<WixTargetsPath Condition=" '$(WixTargetsPath)' == '' ">$(MSBuildExtensionsPath)\Microsoft\WiX\v3.x\Wix.targets</WixTargetsPath>
5+
</PropertyGroup>
6+
7+
<PropertyGroup>
8+
</PropertyGroup>
9+
10+
<PropertyGroup>
11+
<OutputName>icu</OutputName>
12+
<OutputType>Package</OutputType>
13+
<ProjectGuid></ProjectGuid>
14+
<SchemaVersion>2.0</SchemaVersion>
15+
<ProductVersion Condition=" '$(ProductVersion)' == '' ">0.0.0</ProductVersion>
16+
<ProductVersion>0.0.0</ProductVersion>
17+
</PropertyGroup>
18+
19+
<PropertyGroup>
20+
<OutputPath>build\</OutputPath>
21+
<IntermediateOutputPath>build\obj\</IntermediateOutputPath>
22+
<DefineSolutionProperties>false</DefineSolutionProperties>
23+
</PropertyGroup>
24+
25+
<Import Project="$(WixTargetsPath)" />
26+
27+
<PropertyGroup>
28+
<DefineConstants>ProductVersion=$(ProductVersion);ProductVersionMajor=$(ProductVersionMajor);ICU_ROOT=$(ICU_ROOT)</DefineConstants>
29+
</PropertyGroup>
30+
31+
<ItemGroup>
32+
<Compile Include="icu.wxs" />
33+
</ItemGroup>
34+
</Project>

icu.wxs

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
3+
<Product Id="*" Language="1033" Manufacturer="swift.org" Name="ICU" UpgradeCode="4b3bfcaf-46b1-4940-b3e3-692ea4e78a09" Version="$(var.ProductVersion)">
4+
<Package Comments="Copyright (c) 2021 Swift Open Source Project" Compressed="yes" Description="ICU" InstallScope="perMachine" Manufacturer="swift.org" />
5+
<Media Id="1" Cabinet="icu.cab" EmbedCab="yes" />
6+
7+
<!-- Directory Structure -->
8+
<Directory Id="TARGETDIR" Name="SourceDir">
9+
<Directory Id="WINDOWSVOLUME">
10+
<Directory Id="LIBRARY" Name="Library">
11+
<Directory Id="ICU" Name="icu-$(var.ProductVersion)">
12+
<Directory Id="ICU_USR" Name="usr">
13+
<Directory Id="ICU_USR_BIN" Name="bin">
14+
</Directory>
15+
</Directory>
16+
</Directory>
17+
</Directory>
18+
</Directory>
19+
</Directory>
20+
21+
<SetDirectory Id="WINDOWSVOLUME" Value="[WindowsVolume]" />
22+
23+
<!-- Components -->
24+
<DirectoryRef Id="ICU_USR_BIN">
25+
<Component Id="ICU_RUNTIME" Guid="77a97eb2-4a5c-4d85-9fb7-692fd37d9b68">
26+
<File Id="ICUDT" Source="$(var.ICU_ROOT)\Library\icu-$(var.ProductVersionMajor)\usr\bin\icudt$(var.ProductVersionMajor).dll" Checksum="yes" />
27+
<File Id="ICUIN" Source="$(var.ICU_ROOT)\Library\icu-$(var.ProductVersionMajor)\usr\bin\icuin$(var.ProductVersionMajor).dll" Checksum="yes" />
28+
<File Id="ICUUC" Source="$(var.ICU_ROOT)\Library\icu-$(var.ProductVersionMajor)\usr\bin\icuuc$(var.ProductVersionMajor).dll" Checksum="yes" />
29+
</Component>
30+
</DirectoryRef>
31+
32+
<DirectoryRef Id="TARGETDIR">
33+
<Component Id="ENV_VARS" Guid="97fe0a23-32e0-481d-8827-215f4c74f03c">
34+
<Environment Id="PATH" Action="set" Name="PATH" Part="last" Permanent="no" System="yes" Value="[WindowsVolume]Library\icu-$(var.ProductVersion)\usr\bin" />
35+
</Component>
36+
</DirectoryRef>
37+
38+
<!-- Features -->
39+
<Feature Id="RUNTIME" Level="1">
40+
<ComponentRef Id="ICU_RUNTIME" />
41+
<ComponentRef Id="ENV_VARS" />
42+
</Feature>
43+
44+
<!-- UI -->
45+
<UI />
46+
</Product>
47+
</Wix>

0 commit comments

Comments
 (0)