Skip to content

Commit 64ebf9c

Browse files
committed
fix copy msi problem
1 parent 2f18e2d commit 64ebf9c

File tree

1 file changed

+14
-24
lines changed

1 file changed

+14
-24
lines changed

build/SayMore.proj

Lines changed: 14 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -137,12 +137,21 @@
137137

138138
<MSBuild Projects="$(RootDir)\src\Installer\Installer.wixproj"/>
139139

140-
<!-- remove an existing one with the same name, if necessary -->
141-
<Delete Files="$(RootDir)\output\installer\SayMoreInstaller.$(Version).msi" TreatErrorsAsWarnings="false" />
140+
<!-- Ensure destination folder exists -->
141+
<MakeDir Directories="$(RootDir)\output\installer" />
142142

143-
<Copy SourceFiles="$(RootDir)\output\installer\SayMoreInstaller.msi"
144-
DestinationFiles="$(RootDir)\output\installer\SayMoreInstaller.$(Version).msi"
145-
/>
143+
<!-- Helpful debug -->
144+
<Message Text="Looking for MSI at: $(RootDir)\src\Installer\bin\$(Configuration)\SayMoreInstaller.msi" Importance="high" />
145+
146+
<!-- Guard with an explicit error if it's missing -->
147+
<Error
148+
Text="Expected MSI not found at %(Identity)."
149+
Condition="!Exists('$(RootDir)\src\Installer\bin\$(Configuration)\SayMoreInstaller.msi')" />
150+
151+
<!-- Copy + rename with version -->
152+
<Copy
153+
SourceFiles="$(RootDir)\src\Installer\bin\$(Configuration)\SayMoreInstaller.msi"
154+
DestinationFiles="$(RootDir)\output\installer\SayMoreInstaller.$(Version).msi" />
146155

147156
<!-- appcast.xml is used as part of the update notification system -->
148157
<Copy SourceFiles ="$(RootDir)\src\Installer\appcast.xml"
@@ -157,25 +166,6 @@
157166

158167
</Target>
159168

160-
<!-- The "Installer" Target used to depend on this, but the Edolo Sample data was removed
161-
in version 3 of SayMore, so there is no need to continue to generate this WIX include
162-
file. (See SampleData\ReadMe.txt)
163-
<Target Name="MakeWixForSampleData">
164-
<MakeDir ContinueOnError ="true" Directories ="$(RootDir)\output\Installer\"/>
165-
166-
<MakeWixForDirTree
167-
DirectoryReferenceId="SampleDataDir"
168-
GiveAllPermissions="true"
169-
ComponentGroupId="SampleData"
170-
RootDirectory="$(RootDir)\SampleData"
171-
OutputFilePath="$(RootDir)\output\Installer\GeneratedSampleDataFiles.wxs"
172-
MatchRegExPattern=".*"
173-
>
174-
<Output TaskParameter="OutputFilePath" ItemName="Compile" />
175-
</MakeWixForDirTree>
176-
</Target>
177-
-->
178-
179169
<Target Name="copyLibL10ns" DependsOnTargets="RestoreLocalPackages">
180170
<Error Text="Palaso L10ns package missing. Expected at $(RootDir)/packages/SIL.libpalaso.l10ns"
181171
Condition="!Exists('$(RootDir)/packages/SIL.libpalaso.l10ns/SIL.libpalaso.l10ns.nupkg')" />

0 commit comments

Comments
 (0)