Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > ac64de386cb07888afa4b574050eef5b > files > 6

icecream-0.9.6-4.fc15.src.rpm

# Leaves path unchanged if icecc is already there.
# If ccache is there, adds icecc _after_ it.
# Otherwise adds icecc to the beginning.

if ( "$path" !~ *@LIBDIR@/icecc/bin* ) then
	if ( "$path" !~ *@LIBDIR@/ccache* ) then
		set path = ( @LIBDIR@/icecc/bin $path )
	else
		@ pos = 0
		foreach item ( $path )
			@ pos = $pos + 1
			if ( $item == @LIBDIR@/ccache ) break
		end
		@ next_pos = $pos + 1
		set path = ( $path[1-$pos] @LIBDIR@/icecc/bin \
			$path[$next_pos-])
		unset next_pos
		unset pos
		unset item
	endif
endif