Results 1 to 4 of 4

Thread: Usage of Backlash in the Terminal

  1. #1
    Join Date
    Jun 2012
    Beans
    9

    Usage of Backlash in the Terminal

    Hello! I am new to Linux and am getting used to working in the shell. I wanted to install the Gnu Compiler Collection and had planned on using the following commands to get it running.
    $ ./configure --prefix=/usr/local/AVR \
    --target=avr --enable-languages="c,c++" \
    --disable-nls
    $ make
    # make install


    But I couldn't quite understand the function of the backslashes ('\'-marked them red here).
    This is what it typed in the terminal

    prasan@ubuntu:~/Downloads/gcc-4.7.0$ ./configure --prefix=/usr/local/AVR \
    > --target=avr --enable-languages='c,c++" \
    > --disable-nls

    >

    1. Is this right?
    2. If so, can someone please tell me how to complete this set of instructions so that I could run configure file?
    (This '>' keeps coming as I return signaling that I haven't terminated the command properly)

    Last edited by prasanmouli; June 6th, 2012 at 10:14 AM. Reason: Making the title to be more concise

  2. #2
    Join Date
    Jan 2010
    Location
    Kolkata India
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Backlash in the Terminal

    Shell treats backslash '\' as escape character ,that means whatever you type just after the '\' character will be ignored by the shell .
    In your example to make the long commandline more readable , it has been split into several lines .So the return character just typed after the '\' has been ignored and the shell awaits for further input from the user .

    http://steve-parker.org/sh/escape.shtml
    “Progress is made by lazy men looking for easier ways to do things”
    — Robert A. Heinlein

  3. #3
    Join Date
    Sep 2011
    Location
    South Africa
    Beans
    165
    Distro
    Xubuntu 12.10 Quantal Quetzal

    Re: Usage of Backlash in the Terminal

    Suppose you accidentally type it.. for instance ; you type
    Code:
    ls \
    The shell will wait for more input, how do escape from that because I normally press Cntrl-C

  4. #4
    Join Date
    Jun 2012
    Beans
    9

    Re: Usage of Backlash in the Terminal

    Thank You! Got it running now!

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •