[114205] trunk/dports/_resources/port1.0/group/octave-1.0.tcl

Ryan Schmidt ryandesign at macports.org
Mon Dec 2 17:32:03 PST 2013


On Dec 2, 2013, at 09:29, michaelld at macports.org wrote:

> Revision
> 114205
> Author
> michaelld at macports.org
> Date
> 2013-12-02 07:29:03 -0800 (Mon, 02 Dec 2013)
> Log Message
> 
> octave 1.0 PortGroup: in post-extract when renaming the worksrcdir to be the octave module name: work-around for case-insensitive file systems when the extract directory name is the same as the octave module name except for at least one letter case; should always work no matter if the file system is case-insensitive or case-sensitive.
> Modified Paths
> 
> 	• trunk/dports/_resources/port1.0/group/octave-1.0.tcl
> Diff
> 
> Modified: trunk/dports/_resources/port1.0/group/octave-1.0.tcl (114204 => 114205)
> 
> --- trunk/dports/_resources/port1.0/group/octave-1.0.tcl	2013-12-02 13:18:52 UTC (rev 114204)
> +++ trunk/dports/_resources/port1.0/group/octave-1.0.tcl	2013-12-02 15:29:03 UTC (rev 114205)
> 
> @@ -80,9 +80,16 @@
> 
>  
> 
>      set worksrcdir_name [exec /bin/ls ${workpath} | grep -v -E "^\\."]
> 
>      if {[string equal ${worksrcdir_name} ${octave.module}] == 0} {
> 
> -	move ${workpath}/${worksrcdir_name} ${workpath}/${octave.module}
> 
> +
> +	# work-around for case-insensitive file systems when the
> +	# extract directory name is the same as the octave module name
> +	# except for letter case; should always work no matter if the
> +	# file system is case-insensitive or case-sensitive.
> +
> +	move ${workpath}/${worksrcdir_name} ${workpath}/tmp-${worksrcdir_name}
> +	move ${workpath}/tmp-${worksrcdir_name} ${workpath}/${octave.module}
> +

This really failed before? I’m surprised we don’t have a general fix for this yet. I’d love to get this kind of fix into “proc move”. The whole reason we have wrappers like “copy” and “move” is so that we can abstract away things like this.



More information about the macports-dev mailing list