Skip to content

Commit 34b90c7

Browse files
committed
Windows Packaging
1 parent 64a3b83 commit 34b90c7

8 files changed

Lines changed: 55 additions & 1 deletion

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,3 +112,4 @@ java/build/
112112
/core/examples/build
113113

114114
.build/
115+
/app/windows/obj

app/build.gradle.kts

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,16 +143,29 @@ tasks.register<Exec>("packageCustomDmg"){
143143
)
144144
}
145145

146+
tasks.register<Exec>("packageCustomMsi"){
147+
workingDir = file("windows")
148+
commandLine(
149+
"dotnet",
150+
"build",
151+
"/p:Platform=x64"
152+
)
153+
}
154+
146155
afterEvaluate{
147156
tasks.named("packageDmg").configure{
148157
dependsOn("packageCustomDmg")
149158
group = "compose desktop"
150159
actions = emptyList()
151160
}
161+
tasks.named("packageMsi").configure{
162+
dependsOn("packageCustomMsi")
163+
group = "compose desktop"
164+
actions = emptyList()
165+
}
152166
}
153167

154168

155-
156169
// LEGACY TASKS
157170
// Most of these are shims to be compatible with the old build system
158171
// They should be removed in the future, as we work towards making things more Gradle-native

app/windows/Processing.wixproj

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<Project Sdk="WixToolset.Sdk/5.0.1">
2+
<ItemGroup>
3+
<PackageReference Include="WixToolset.UI.wixext" Version="5.0.1" />
4+
</ItemGroup>
5+
</Project>

app/windows/Processing.wxs

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs" xmlns:ui="http://wixtoolset.org/schemas/v4/wxs/ui">
2+
<Package Name="Processing" Manufacturer="Processing Foundation" Version="0.0.1" UpgradeCode="34577f3b-7cbe-4c5e-827d-5fe5ce9d371c">
3+
<Icon Id="icon.ico" SourceFile="..\..\build\windows\processing.ico" />
4+
<Property Id="ARPPRODUCTICON" Value="icon.ico" />
5+
6+
<MediaTemplate EmbedCab="yes" />
7+
8+
<ui:WixUI Id="WixUI_Mondo" InstallDirectory="INSTALLFOLDER" />
9+
10+
<WixVariable Id="WixUILicenseRtf" Value="license.rtf" />
11+
<WixVariable Id="WixUIDialogBmp" Value="background.png" />
12+
<WixVariable Id="WixUIBannerBmp" Value="banner.png" />
13+
<Feature Id="MainApplication" Title="Main Application" Level="1">
14+
<Files Include="..\build\compose\binaries\main\app\Processing\**" />
15+
<ComponentRef Id="ApplicationShortcut" />
16+
</Feature>
17+
<Directory Id="ProgramMenuFolder">
18+
<Directory Id="ApplicationProgramsFolder" Name="Processing"/>
19+
</Directory>
20+
<Component Id="ApplicationShortcut" Guid="b15e6d69-f054-4ec2-aade-8e3756b537d6">
21+
<Shortcut Id="ApplicationStartMenuShortcut"
22+
Name="Processing"
23+
Description="My Application Description"
24+
Directory="ApplicationProgramsFolder"
25+
Target="[INSTALLFOLDER]\Processing.exe"
26+
WorkingDirectory="INSTALLFOLDER"/>
27+
<RemoveFolder Id="CleanUpShortCut" Directory="ApplicationProgramsFolder" On="uninstall"/>
28+
<RegistryValue Root="HKCU" Key="Software\Processing Foundation\Processing" Name="installed" Type="integer" Value="1" KeyPath="yes"/>
29+
</Component>
30+
</Package>
31+
</Wix>

app/windows/background.png

3.72 KB
Loading

app/windows/banner.png

824 Bytes
Loading

app/windows/license.rtf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Hi Here's Processing's license

core/build.gradle.kts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,4 +70,7 @@ tasks.test {
7070
}
7171
tasks.withType<Jar> {
7272
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
73+
}
74+
tasks.compileJava{
75+
options.encoding = "UTF-8"
7376
}

0 commit comments

Comments
 (0)