Wireshark-dev: Re: [Wireshark-dev] Windows packaging fails with master
From: Graham Bloice <[email protected]>
Date: Tue, 19 Aug 2014 17:26:03 +0100
On 19 August 2014 09:11, Anders Broman <[email protected]> wrote:

 

Thanks, packaging works now but I still get some error output:

0 File(s) copied

       powershell -executionpolicy bypass -File tools/textify.ps1 -Destination wireshark-gtk2  ./COPYING  ./NEWS  ./README  ./README.windows

Test-Path : A parameter cannot be found that matches parameter name 'OlderThan'

.

At C:\ewireshark2\trunk\tools\textify.ps1:85 char:71

+     if (-not (Test-Path $dst_file) -or (Test-Path $dst_file -OlderThan <<<< 

$src_modtime)) {

    + CategoryInfo          : InvalidArgument: (:) [Test-Path], ParameterBindi

   ngException

    + FullyQualifiedErrorId : NamedParameterNotFound,Microsoft.PowerShell.Comm

   ands.TestPathCommand

Test-Path : A parameter cannot be found that matches parameter name 'OlderThan'

.

At C:\ewireshark2\trunk\tools\textify.ps1:85 char:71

+     if (-not (Test-Path $dst_file) -or (Test-Path $dst_file -OlderThan <<<< 

$src_modtime)) {

    + CategoryInfo          : InvalidArgument: (:) [Test-Path], ParameterBindi

   ngException

    + FullyQualifiedErrorId : NamedParameterNotFound,Microsoft.PowerShell.Comm

   ands.TestPathCommand

Test-Path : A parameter cannot be found that matches parameter name 'OlderThan'

.

At C:\ewireshark2\trunk\tools\textify.ps1:85 char:71

+     if (-not (Test-Path $dst_file) -or (Test-Path $dst_file -OlderThan <<<< 

$src_modtime)) {

    + CategoryInfo          : InvalidArgument: (:) [Test-Path], ParameterBindi

   ngException

    + FullyQualifiedErrorId : NamedParameterNotFound,Microsoft.PowerShell.Comm

   ands.TestPathCommand

Test-Path : A parameter cannot be found that matches parameter name 'OlderThan'

.

At C:\ewireshark2\trunk\tools\textify.ps1:85 char:71

+     if (-not (Test-Path $dst_file) -or (Test-Path $dst_file -OlderThan <<<< 

$src_modtime)) {

    + CategoryInfo          : InvalidArgument: (:) [Test-Path], ParameterBindi

   ngException

    + FullyQualifiedErrorId : NamedParameterNotFound,Microsoft.PowerShell.Comm

   ands.TestPathCommand

 



The -OlderThan dynamic parameter was only added in Powershell 3.0.  We'll have to figure out a solution that works in PS 2.0

Probably replacing `Test-Path $dst_file -OlderThan` with `(Get-Item $dst_file).LastWriteTime -lt `

--
Graham Bloice