Commit 41594f95 authored by Mircea Bardac's avatar Mircea Bardac

replace / with \ in output directory paths

When building on Unix systems, the output directory paths must be converted to
Windows format by replacing '/' with '\'.
Signed-off-by: 's avatarMircea Bardac <dev@mircea.bardac.net>


git-svn-id: svn+ssh://svn.psi-im.org/home/psi/svn/win-installer/trunk@56 2d3a5ac0-73f9-4639-b284-2310bd1da355
parent 47d5d507
#!/bin/bash
# PrepFiles v1.0
# PrepFiles v1.1
# Copyright (c) 2005 Mircea Bardac
# E-mail: dev AT mircea.bardac.net
......@@ -35,8 +35,11 @@ echo ";" >> $out_uninst
echo >> $out_uninst
cat directories.list | while read cline; do
#echo $cline
outpath=$(echo "$cline" | sed "s|$indir|\$INSTDIR|g")
# if directory paths contain / (as it happens on a Unix system),
# replace them with \ (2 times because the output is echo-ed with -e
# and echo -e "\\" becomes "\"
outpath=$(echo "$outpath" | sed 's|\/|\\\\|g')
echo -e "\tSetOutPath \"$outpath\"" >> $out_inst
find $cline -type f | grep -v "$cline/.*/.*" | while read cfile; do
fpath=$(echo "$cfile" | sed -e "s|$indir||g")
......@@ -49,6 +52,8 @@ done
cat directories.list | sort -r | while read cdir; do
outpath=$(echo "$cdir" | sed "s|$indir|\$INSTDIR|g")
# replace / in directory paths with \\ (see above comment)
outpath=$(echo "$outpath" | sed 's|\/|\\\\|g')
echo -e "\tRMDir \"$outpath\"" >> $out_uninst
done
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment