Fix using correct locale settings in Ubuntu.

Workaround for crash of test suite in Ubuntu due to not deleting existing xls file.



git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3365 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz 2014-07-23 16:00:01 +00:00
parent 248c5d677c
commit ed409c445a
3 changed files with 17 additions and 1 deletions

View File

@ -48,6 +48,9 @@
</Win32>
</Options>
</Linking>
<Other>
<CompilerPath Value="$(CompPath)"/>
</Other>
</CompilerOptions>
</Item2>
<Item3 Name="Release">
@ -79,6 +82,9 @@
</Win32>
</Options>
</Linking>
<Other>
<CompilerPath Value="$(CompPath)"/>
</Other>
</CompilerOptions>
</Item3>
</BuildModes>
@ -138,6 +144,9 @@
</Win32>
</Options>
</Linking>
<Other>
<CompilerPath Value="$(CompPath)"/>
</Other>
</CompilerOptions>
<Debugging>
<Exceptions Count="5">

View File

@ -707,7 +707,7 @@ type
@param boBufStream When this option is set a buffered stream is used
for writing (a memory stream swapping to disk) or
reading (a file stream pre-reading chunks of data
to memory) }
to memory) }
TsWorkbookOption = (boVirtualMode, boBufStream);
{@@
@ -1094,6 +1094,9 @@ procedure InitCell(var ACell: TCell);
implementation
uses
{$IFDEF UNIX}
clocale,
{$ENDIF}
Math, StrUtils, TypInfo, fpsStreams, fpsUtils, fpsNumFormatParser, fpsFunc;
{ Translatable strings }

View File

@ -151,6 +151,10 @@ end;
procedure TSpreadManualSetup.OneTimeTearDown;
begin
if Workbook <> nil then begin
// In Ubuntu explicit deletion of the existing file is needed.
// Otherwise an error would occur and a defective file would be written }
if FileExists(TestFileManual) then DeleteFile(TestFileManual);
Workbook.WriteToFile(TestFileManual, OUTPUT_FORMAT, TRUE);
Workbook.Free;
Workbook := nil;