~ubuntu-branches/ubuntu/oneiric/soqt/oneiric

« back to all changes in this revision

Viewing changes to cfg/m4/path_conversion.m4

  • Committer: Bazaar Package Importer
  • Author(s): Steve M. Robbins
  • Date: 2004-05-29 02:58:50 UTC
  • Revision ID: james.westby@ubuntu.com-20040529025850-phd20eva5uyhhdrf
Tags: upstream-1.0.2
Import upstream version 1.0.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# Convenience macros SIM_AC_DEBACKSLASH and SIM_AC_DOBACKSLASH for
 
2
# converting to and from MSWin/MS-DOS style paths.
 
3
#
 
4
# Example use:
 
5
#
 
6
#     SIM_AC_DEBACKSLASH(my_ac_reversed, "C:\\mydir\\bin")
 
7
#
 
8
# will give a shell variable $my_ac_reversed with the value "C:/mydir/bin").
 
9
# Vice versa for SIM_AC_DOBACKSLASH.
 
10
#
 
11
# Author: Marius Bugge Monsen <mariusbu@sim.no>
 
12
#         Lars J�rgen Aas <larsa@sim.no>
 
13
#         Morten Eriksen <mortene@sim.no>
 
14
 
 
15
AC_DEFUN([SIM_AC_DEBACKSLASH], [
 
16
eval "$1=\"`echo $2 | sed -e 's%\\\\%\\/%g'`\""
 
17
])
 
18
 
 
19
AC_DEFUN([SIM_AC_DOBACKSLASH], [
 
20
eval "$1=\"`echo $2 | sed -e 's%\\/%\\\\%g'`\""
 
21
])
 
22
 
 
23
AC_DEFUN([SIM_AC_DODOUBLEBACKSLASH], [
 
24
eval "$1=\"`echo $2 | sed -e 's%\\/%\\\\\\\\\\\\\\\\%g'`\""
 
25
])
 
26