title: sed replace forward slash with backslash
body: <p>I have to convert filenames having a forward slash to filenames with a back slash in a makefile using mingw32. I used the following sed command to store the result in a variable:</p>
  
  <pre><code>ORIGINAL=./a/b/main1.c ./a/b/main2.c ./a/b/main3.c
  </code></pre>
  
  <p><strong>sed command:</strong></p>
  
  <pre><code>RESULT=$(shell echo $(ORIGINAL) | sed 's/\//\\/g')
  </code></pre>
  
  <p>And the <strong>resulting output</strong> is:</p>
  
  <pre><code>.\a\b\main1.c .abmain2.c .abmain3.c
  </code></pre>
  
  <p>It works fine if I run it directly on bash. Can anyone tell me whats wrong? </p>
  
  <p>Thanks!</p>